I have been experiencing this problem on and off for about a week. I'm
using v2.41.232.0. The problem does not occur if I test via the GUI.
The problem occurs with this code
using System;
using MbUnit.Core;
namespace ReportingFramework.Tests
{
internal class Program
{
private static void Main()
{
using (AutoRunner runner = new AutoRunner())
{
runner.Run();
if (!runner.IsSuccess) runner.ReportToText();
}
Console.ReadKey();
}
}
}
here is the console output:
-------------------------------------------------------------------------------------------------------------
[error] Unexpected exception occured in MbUnit
Internal error while running tests in ReportingFramework.Tests
MbUnit.Core.Exceptions.FixtureExecutionException
Message: ConfigureReportTaskTest
Source: MbUnit.Framework
StackTrace:
at MbUnit.Core.Remoting.FixtureRunnerBase.RunFixture(Fixture
fixture)
at MbUnit.Core.Remoting.DependencyFixtureRunner.RunFixtures()
at MbUnit.Core.Remoting.FixtureRunnerBase.Run(FixtureExplorer
explorer, Repor
tListener reportListener)
Inner Exception
System.TypeLoadException
Message: GenericArguments[0], 'TypeOfItem', on
'SD.LLBLGen.Pro.ORMSupportClasses
.CollectionCore`1[T]' violates the constraint of type parameter 'T'.
Source: mscorlib
StackTrace:
at System.Signature._GetSignature(SignatureStruct& signature, Void*
pCorSig,
Int32 cCorSig, IntPtr fieldHandle, IntPtr methodHandle, IntPtr
declaringTypeHand
le)
at System.Signature.GetSignature(SignatureStruct& signature, Void*
pCorSig, I
nt32 cCorSig, RuntimeFieldHandle fieldHandle, RuntimeMethodHandle
methodHandle,
RuntimeTypeHandle declaringTypeHandle)
at System.Signature..ctor(RuntimeMethodHandle methodHandle,
RuntimeTypeHandle
declaringTypeHandle)
at System.Reflection.RuntimeMethodInfo.get_Signature()
at System.Reflection.RuntimeMethodInfo.GetParameters()
at System.Diagnostics.StackTrace.ToString(TraceFormat traceFormat)
at System.Environment.GetStackTrace(Exception e, Boolean
needFileInfo)
at System.Exception.get_StackTrace()
at
MbUnit.Core.Reports.Serialization.ReportException.FromException(Exception
ex)
at MbUnit.Core.Reports.Serialization.ReportRun.Failure(RunPipe
pipe, ReportMo
nitor monitor, Exception ex)
at MbUnit.Core.RunPipeStarter.Run(Object fixture, Boolean
IsExplicit)
at
MbUnit.Core.Remoting.FixtureRunnerBase.InternalRunFixture(Fixture
fixture)
at
MbUnit.Core.Remoting.FixtureRunnerBase.FixtureRunnerStarter.Start()
[cleaning] unloading domain
[cleaning] domain unloaded
After reviewing the stack trace above it appears mbunit is mixing up
generic calls. 'TypeOfItem' is never referenced in the ORMSupportClass
(LLBL 3rd party). I do have a generic object using 'TypeOfItem' but
that doesn't have anything to do with ORMSupportClass.
It also doesn't make sense that the error only occurs with autorunner
and not the GUI. I'm new to unit testing and rhino mocks so I could be
missing something, but this is very confusing. Any help is very
appreciated.
Thank you, Jason
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"MbUnit.User" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/MbUnitUser?hl=en
-~----------~----~----~----~------~----~------~--~---