testwarerror.cpp
来自「ftpserver very good sample」· C++ 代码 · 共 37 行
CPP
37 行
#include "stdafx.h"#include <assert.h>#include <iostream>#include "WarError.h"using namespace std;void TestWarError(){ WarError Err; assert(false == Err); assert(true == !Err); if (!Err) cout << "Testing WarErr class. Seems ok" << endl; else cout << "Testing WarErr class. Totally fucked up!" << endl; Err = WAR_ERR_SYSTEM_ERROR; Err = 5; assert(Err.LocalError() == WAR_ERR_SYSTEM_ERROR); assert(Err.SystemError() == 5); cout << "Explaining test error> " << Err.Explain() << endl; Err.Capture();}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?