|
#include "shortcut.h"
#include "unittest.h"
int main(int argc, char* argv[])
{
#if 1
// Creating tests manually
TestRunner runner;
MySuite1 mysuite1;
MySuite1Test1 mysuite1case1;
MySuite1Test2 mysuite1case2;
MySuite1Test3 mysuite1case3;
mysuite1.AddTest(&mysuite1case3);
mysuite1.AddTest(&mysuite1case2);
mysuite1.AddTest(&mysuite1case1);
runner.AddSuite(&mysuite1);
runner.RunTests();
#else
// Creating tests the macro way
TestRunner runner2;
T_ADDSUITE(runner2, suite10, MySuite1);
T_ADDTEST(suite10, 100, MySuite1Test1);
T_ADDTEST(suite10, 101, MySuite1Test2);
runner2.RunTests();
#endif
return 0;
}
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
I work as a developer in the Seattle area. I am currently residing in France.