diff options
author | Justin Worthe <justin.worthe@gmail.com> | 2015-06-12 16:30:29 +0200 |
---|---|---|
committer | Justin Worthe <justin.worthe@gmail.com> | 2015-06-12 16:30:29 +0200 |
commit | 63ab384440a6e6813196b914813914bc43674fa8 (patch) | |
tree | 7b62e33239b477b058991160d48edbaf2c10ac9b /test/move_string_mapper.cpp | |
parent | 72eaaeb60916e736de6c1aaa3d1047663bce19d9 (diff) |
Added new tests
Diffstat (limited to 'test/move_string_mapper.cpp')
-rw-r--r-- | test/move_string_mapper.cpp | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/test/move_string_mapper.cpp b/test/move_string_mapper.cpp new file mode 100644 index 0000000..ab167e3 --- /dev/null +++ b/test/move_string_mapper.cpp @@ -0,0 +1,23 @@ +#include "catch.hpp" +#include "move.h" +#include <string> +#include "move_string_mapper.h" + +SCENARIO("Writing a move") +{ + GIVEN("A Move") + { + Move move = Move::MOVE_LEFT; + + WHEN("It is mapped to a string") + { + std::string moveString = MoveStringMapper().toString(move); + + THEN("The string is correct") + { + REQUIRE(moveString == "MoveLeft"); + } + } + + } +} |