📄 testcore.cpp
字号:
// TestCore.cpp : Defines the entry point for the console application.
//
#include "stdafx.h"
#include <cppunit/extensions/HelperMacros.h>
#include <cppunit/CompilerOutputter.h>
#include <cppunit/extensions/TestFactoryRegistry.h>
#include <cppunit/ui/text/TestRunner.h>
#include "Helper.h"
#include "Register_Test.h"
#include "Instruction_Test.h"
CPPUNIT_TEST_SUITE_REGISTRATION( Register_Test );
int _tmain(int argc, _TCHAR* argv[])
{
Core::Stop_Watch w;
w.start();
// Get the top level suite from the registry
CppUnit::Test *suite = CppUnit::TestFactoryRegistry::getRegistry().makeTest();
// Adds the test to the list of test to run
CppUnit::TextUi::TestRunner runner;
runner.addTest( suite );
// Change the default outputter to a compiler error format outputter
runner.setOutputter( new CppUnit::CompilerOutputter( &runner.result(),
std::cerr ) );
// Run the tests.
bool wasSucessful = runner.run();
std::cout<<"Time elapsed: "<<w.stop()<<std::endl;
// Return error code 1 if the one of test failed.
return wasSucessful ? 0 : 1;
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -