[Mono-dev] Mono and NMock2 - failing to run NMock2 with mono svn

Mads Bondo Dydensborg mbd at dbc.dk
Wed Jul 4 02:41:20 EDT 2007


fredag 29 juni 2007 16:22 skrev Mads Bondo Dydensborg:
> Hi there

Hi there - just a repost to raise this issue again. 

Any feedback will be most appreciated.

Regards,

Mads

> 
> I have observed that my nmock2 tests have started to fail with the version 
of 
> mono I compile from svn. Running this command:
> 
> $ echo $MONO_PATH
> /home/madsdyd/xintegra/trunk/Components/Bin/:/home/madsdyd/xintegra/trunk/Lib/NUnit:/home/madsdyd/xintegra/trunk/Lib/NMock:/home/madsdyd/xintegra/trunk/Lib/NLog/Mono
> $ which mono
> /usr/local/mono-svn/bin/mono
>  $ mono --version
> Mono JIT compiler version 1.2.4 (/trunk/ r81006)
> Copyright (C) 2002-2007 Novell, Inc and Contributors. www.mono-project.com
>         TLS:           __thread
>         GC:            Included Boehm (with typed GC)
>         SIGSEGV:       normal
>         Architecture:  x86
>         Disabled:      none
> $ 
> 
mono --debug /home/madsdyd/xintegra/trunk/Lib/NUnit/nunit-console.exe ../Bin/Debug/DBC.ORM.dll
> 
> fails with:
> 
> Failures:
> 1) SQLBuilderTest.SelectOrAndSQL : System.InvalidCastException : Cannot cast 
> from source type to destination type.
>   at SQLBuilderTest.SetUp () [0x00035] 
> 
in /home/madsdyd/xintegra/trunk/Components/DBC.ORM/UnitTest/SQLBuilderTest.cs:90
>   at <0x00000> <unknown method>
>   at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke 
> (object,object[])
>   at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags 
> invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, 
> System.Globalization.CultureInfo culture) [0x00056] 
> 
in /home/compile/Compile/Mono/mcs/class/corlib/System.Reflection/MonoMethod.cs:146
> 
> The offending statement is:
> 
>       mockProvider = mocks.NewMock<IProvider>();
> 
> AFAICT the assignment does not matter, the failure is somewhere in 
NewMock(?)
> 
> However, running with stable mono:
> 
> $ mono --version
> Mono JIT compiler version 1.2.3.1, (C) 2002-2006 Novell, Inc and 
Contributors. 
> www.mono-project.com
>         TLS:           __thread
>         GC:            Included Boehm (with typed GC)
>         SIGSEGV:       normal
>         Architecture:  x86
>         Disabled:      none
> 
> The test passes as expected - with no fails (neither from NUnit or Mono). In 
> both cases, the compilation of my source tree has been using the svn version 
> of mono/gmcs.
> 
> So, two questions:
> 
> a) Is anyone else experiencing this issue?
> b) Any advise on resolving it?
> 
> Thanks in advance, and regards,
> 
> Mads
> 
> -- 
> Med venlig hilsen/Regards
> 
> Systemudvikler/Systemsdeveloper cand.scient.dat, Ph.d., Mads Bondo 
Dydensborg
> Dansk BiblioteksCenter A/S, Tempovej 7-11, 2750 Ballerup, Tlf. +45 44 86 77 
34
> 
> _______________________________________________
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list
> 
> 

-- 
Med venlig hilsen/Regards

Systemudvikler/Systemsdeveloper cand.scient.dat, Ph.d., Mads Bondo Dydensborg
Dansk BiblioteksCenter A/S, Tempovej 7-11, 2750 Ballerup, Tlf. +45 44 86 77 34




More information about the Mono-devel-list mailing list