zaela-Server/tests/main.cpp

58 lines
1.9 KiB
C++
Raw Permalink Normal View History

2013-05-09 10:44:08 -04:00
/* EQEMu: Everquest Server Emulator
Copyright (C) 2001-2013 EQEMu Development Team (http://eqemulator.net)
2013-02-17 13:36:39 -08:00
2013-05-09 10:44:08 -04:00
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; version 2 of the License.
2013-05-06 13:07:41 -04:00
2013-05-09 10:44:08 -04:00
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY except by those people which sell it, which
2013-02-17 13:36:39 -08:00
are required to give you total support for your newly bought product;
without even the implied warranty of MERCHANTABILITY or FITNESS FOR
2013-05-09 10:44:08 -04:00
A PARTICULAR PURPOSE. See the GNU General Public License for more details.
2013-05-06 13:07:41 -04:00
2013-05-09 10:44:08 -04:00
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
2013-02-17 13:36:39 -08:00
*/
#include <iostream>
#include <fstream>
#include <memory>
#include "memory_mapped_file_test.h"
#include "ipc_mutex_test.h"
#include "fixed_memory_test.h"
#include "fixed_memory_variable_test.h"
#include "atobool_test.h"
#include "hextoi_32_64_test.h"
#include "string_util_test.h"
#include "data_verification_test.h"
2014-09-25 21:35:17 -04:00
#include "skills_util_test.h"
#include "../common/eqemu_config.h"
const EQEmuConfig *Config;
2013-02-17 13:36:39 -08:00
int main() {
2016-05-24 22:17:50 -05:00
auto ConfigLoadResult = EQEmuConfig::LoadConfig();
Config = EQEmuConfig::get();
2013-05-09 10:44:08 -04:00
try {
std::ofstream outfile("test_output.txt");
std::unique_ptr<Test::Output> output(new Test::TextOutput(Test::TextOutput::Verbose, outfile));
Test::Suite tests;
tests.add(new MemoryMappedFileTest());
tests.add(new IPCMutexTest());
tests.add(new FixedMemoryHashTest());
tests.add(new FixedMemoryVariableHashTest());
tests.add(new atoboolTest());
tests.add(new hextoi_32_64_Test());
tests.add(new StringUtilTest());
tests.add(new DataVerificationTest());
2014-09-25 21:35:17 -04:00
tests.add(new SkillsUtilsTest());
2013-05-09 10:44:08 -04:00
tests.run(*output, true);
} catch(...) {
return -1;
}
return 0;
}