【发布时间】:2012-10-18 02:00:58
【问题描述】:
我想通过单元测试来测试我的源代码中的几个函数。现在,如果我运行测试,我不会得到任何测试结果。
这是我尝试做的一个简单的代码片段:
#include <iostream>
using namespace std;
namespace UnitTest
{
[TestClass]
public ref class UnitTestBlueSmart
int main(){
public:
[TestMethod()]
hello();
}
}
void hello(){
cout<<"Hello World!";
}
有谁知道为什么这不起作用?
【问题讨论】:
标签: c++ visual-studio-2010 unit-testing white-box-testing