summaryrefslogtreecommitdiffhomepage
path: root/test/main.cpp
blob: 936521028b3cb445713342e4e6a04f3dc7813b28 (plain)
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
#include "app.hpp"
#include "compat/assert.hpp"
#include "loader/loader.hpp"
#include <stdlib.h>
#include <cstdlib>

namespace floormat {

test_app::test_app(const Arguments& arguments):
      Application {
          arguments,
          Configuration{}
      }
{
}

test_app::~test_app()
{
    loader_::destroy();
}

int test_app::exec()
{
    test_coords();
    test_json();
    test_tile_iter();
    test_magnum_math();
    test_entity();
    test_loader();
    test_bitmask();
    test_wall_atlas();
    test_wall_atlas2();
    test_serializer_1();
    test_serializer_2();
    test_math();
    test_hash();
    test_scenery();
    test_path_search_node_pool();
    test_path_search();
    test_dijkstra();

    zzz_test_misc();

    return 0;
}

} // namespace floormat

int main(int argc, char** argv)
{
#ifdef _WIN32
    // NOLINTNEXTLINE(concurrency-mt-unsafe)
    if (const auto* s = std::getenv("MAGNUM_LOG"); !s || !*s)
        _putenv("MAGNUM_LOG=quiet");
#else
        setenv("MAGNUM_LOG", "quiet", 0);
#endif
    floormat::test_app application{{argc, argv}};
    return application.exec();
}