Does any one know if I can test native code in VS Test 2010?
Asked
Active
Viewed 373 times
3

Chris Schmich
- 29,128
- 5
- 77
- 94

There is nothing we can do
- 23,727
- 30
- 106
- 194
-
You should ask at http://stackoverflow.com/ – Ian C. Oct 06 '10 at 19:46
-
@Ian C. I did and so far no one answered – There is nothing we can do Oct 06 '10 at 19:50
-
1Can you define native code more explicitly? Are you talking about C++ code where you have the headers and the libraries, the source code, or ... – wheaties Oct 06 '10 at 21:14
2 Answers
2
As of VS2010, native C++ unit testing is not directly supported by Visual Studio. See MSDN, specifically:
You cannot have test projects with unit tests that use unmanaged C++.
You can still do native C++ unit testing with Visual Studio, but it won't be as integrated as other VS features. See this SO answer for a number of native unit testing frameworks and libraries. I have not used any of those, so I cannot give any guidance there.

Community
- 1
- 1

Chris Schmich
- 29,128
- 5
- 77
- 94
1
I would bite the bullet, download Boost and get the test suite compiled. Once you get into it, it's as easy as VS tests.

DanDan
- 10,462
- 8
- 53
- 69
-
Or if you don't want to pull in boost (which is great BTW) go for UnitTest++. – oz10 Oct 06 '10 at 21:50