|
From: Vaughn, C. <Va...@va...> - 2003-07-25 16:36:09
|
I tried the following test case and i get a wierd error:
public interface ITestStruct
{
System.Drawing.Point getPoint();
void setPoint( System.Drawing.Point pt );
}
public void TestStruct()
{
DynamicMock foo = new DynamicMock( typeof(
ITestStruct ));
ITestStruct ifoo = (ITestStruct)foo.MockInstance;
System.Drawing.Point p1 = new
System.Drawing.Point(1,2);
foo.ExpectAndReturn( "getPoint", p1 );
foo.Expect( "setPoint", p1 );
ifoo.setPoint( ifoo.getPoint() );
foo.Verify();
}
c:\documents and settings\vaughnc.vci\my
documents\dev\media\tests\tnfwmarketscontroller.cs(52):
TargetNavigator.Tests.TNfwMarketsController.TestStruct: setPoint() called
with incorrect parameter (1)
expected:<{X=1,Y=2}>
but was:<{X=322283128,Y=0}>
This also happens with DateTime. Any ideas?
cliff
|