Hi
I am evaluating Isolator++ 1.3.4.0 with VS 2012 and fighting some error with exception code C0000005 (ACCESS_VIOLATION).
I was able to get Isolator++ up and running in a simple dummy setup (one lib-project with MyTurtle class, one MS Test project). So far so good.
Now I have transfered my dummy class I want to fake (MyTurtle) into my real project and did the steps described in the Online Help "Setting up MS Test".
The result is a failing test. An exception is thrown with exception code C0000005 indicating an ACCESS_VIOLATION.
Any help is highly appreciated! I am stuck...
Cheers
Christoph
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Here is the stacktrace I get:
Result Message: Exception code: C0000005
Result StackTrace:
at FAKE<MyTurtle>() in c:program files (x86) ypemockisolator++includeortestsisolator.h:Line 357
at MyTests::MyMockTests::MyTurtleTest() in somePathmymocktest.cpp:Line 18
Here is my test class:
#include "stdafx.h"
#include "CppUnitTest.h"
#include <isolator.h>
#include "MyTurtle.h"
using namespace Microsoft::VisualStudio::CppUnitTestFramework;
namespace MyTests
{
TEST_CLASS(MyMockTests)
{
public:
TEST_METHOD(MyTurtleTest)
{
MyTurtle* t = FAKE<MyTurtle>();
WHEN_CALLED(t->GetX()).ReturnVal(42);
Assert::AreEqual(42, t->GetX());
ISOLATOR_CLEANUP();
}
};
}