Now have more test for the base functionality but need to push render tests and find a way to test the GUI. I've also brought in sol2 for lua integration but not sure what to do with it.
This commit is contained in:
parent
d0d62836e3
commit
e86d474c7c
14 changed files with 188 additions and 8 deletions
|
@ -66,6 +66,7 @@ TEST_CASE("basic save a world", "[save]") {
|
|||
world.set<Motion>(player.entity, {0, 0});
|
||||
world.set<Combat>(player.entity, {100, 10});
|
||||
world.set<Tile>(player.entity, {"@"});
|
||||
world.set<Inventory>(player.entity, {102});
|
||||
|
||||
save::to_file("./savetest.world", world, map);
|
||||
|
||||
|
@ -95,4 +96,7 @@ TEST_CASE("basic save a world", "[save]") {
|
|||
REQUIRE(map.height() == in_map.height());
|
||||
REQUIRE(map.$walls == in_map.$walls);
|
||||
REQUIRE(map.$input_map == in_map.$input_map);
|
||||
|
||||
Inventory &inv = world.get<Inventory>(player.entity);
|
||||
REQUIRE(inv.gold == 102);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue