-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathruntests.cpp
More file actions
44 lines (35 loc) · 930 Bytes
/
Copy pathruntests.cpp
File metadata and controls
44 lines (35 loc) · 930 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
#include <sstream>
#include "core/global.h"
#include "core/rand.h"
#include "core/fancymath.h"
#include "game/board.h"
#include "game/rules.h"
#include "game/boardhistory.h"
#include "tests/tests.h"
#include "main.h"
int MainCmds::runTests(int argc, const char* const* argv) {
(void)argc;
(void)argv;
testAssert(sizeof(size_t) == 8);
Board::initHash();
Rand::runTests();
FancyMath::runTests();
Tests::runBoardIOTests();
Tests::runBoardBasicTests();
Tests::runBoardAreaTests();
Tests::runRulesTests();
Tests::runBoardUndoTest();
Tests::runNNInputsTests();
Tests::runBoardStressTest();
cout << "All tests passed" << endl;
return 0;
}
int MainCmds::runSearchTests(int argc, const char* const* argv) {
Board::initHash();
if(argc != 2) {
cerr << "Must supply exactly one argument - the model file to use" << endl;
return 1;
}
Tests::runSearchTests(string(argv[1]));
return 0;
}