diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2022-12-05 07:08:13 +0100 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2022-12-05 07:09:10 +0100 |
commit | 900d775c8f4f078dc7cba8557e3991e52d2d5f89 (patch) | |
tree | e7a275ddc4093933e417cde8bc8b935c6ad90199 /test/loader.cpp | |
parent | 2e72c24867e74b057915d2fbc203a72d44e2a7e3 (diff) |
test: add loader test
Diffstat (limited to 'test/loader.cpp')
-rw-r--r-- | test/loader.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/test/loader.cpp b/test/loader.cpp new file mode 100644 index 00000000..a066c973 --- /dev/null +++ b/test/loader.cpp @@ -0,0 +1,16 @@ +#include "app.hpp" +#include "compat/assert.hpp" +#include "loader/loader.hpp" +#include "src/tile-atlas.hpp" + +namespace floormat { + +void test_app::test_loader() +{ + (void)loader.tile_atlases("wall.json", pass_mode::blocked); + (void)loader.tile_atlases("floor.json", pass_mode::pass); + fm_assert(loader.tile_atlas("texel")->pass_mode() == pass_mode::blocked); + fm_assert(loader.tile_atlas("metal1")->pass_mode() == pass_mode::pass); +} + +} // namespace floormat |