I have created a dead simple C++ metro class library in the VS2011 beta, with a Vector3 class. I want to unit test some of the methods.
I added a C++ metro unit test project to the solution and, for the life of me, I can't figure out how to correctly reference the other project without compile errors in the tests.
I know that whatever the answer is it will be downright obvious in hindsight. I've tried following various tutorials (example), but none have had the intended result.
I've tried all the things I can think of. Every variation of include/using/linker-paths/library-paths against the project/.lib/.dll/.winmd/.h/.cpp files. Generally the errors come down to:
error LNK2019
unresolved external symbol
"class Vector3 __cdecl operator-(class Vector3 const &,class Vector3 const &)" (??G@YA?AVVector3@@ABV0@0@Z)
referenced in function "void __cdecl AssertApproximatelyEqual(class Vector3,class Vector3)" (?AssertApproximatelyEqual@@YAXVVector3@@0@Z)
That is to say, I think I've managed to properly import the headers, but the object code they reference is not found.