I dont have much experience with Visual Studio testing framework. I am trying to create a Unit test library for a C++ WinRT library. I created a Unit Test Library and added a reference to the WinRT library. My WinRT library contains ref classes as well as "ordinary" classes that are not exposed. My problem is how do I test the ordinary C++ classes from the Unit test library as they are not accessible from the test library.
- Moved by Mike WongMicrosoft employee, Owner Tuesday, March 13, 2012 1:30 AM (From:Building Metro style apps with C++ )
I would suggest you to create a native unit test project to test ordinary C++ class. You can find this project in Visual C++\Test\Native Unit Test Project.
We can separate test the native part and WinRT part, and then include the native part as the reference into your WinRT project.
Jesse Jiang [MSFT]
MSDN Community Support | Feedback to us
I followed the instructions here to create a unit test in the same project for a WinRT dll.
Basically modified the include and the library paths and create a C++ unit test class in the same project. When i run the unit test, it says
------ Run test started ------
An internal error occurred while launching test executor for Windows Metro style app.
- Edited by amshinde Thursday, March 15, 2012 9:51 PM
Possible solutions discussed at
Developer, VSTLM, Microsoft Corporation
- Edited by Vikram Agrawal Friday, April 27, 2012 2:30 AM