diff options
Diffstat (limited to 'lib/tests/turns-turn-order.cpp')
| -rw-r--r-- | lib/tests/turns-turn-order.cpp | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/lib/tests/turns-turn-order.cpp b/lib/tests/turns-turn-order.cpp index f204847..e0ee431 100644 --- a/lib/tests/turns-turn-order.cpp +++ b/lib/tests/turns-turn-order.cpp @@ -1,7 +1,10 @@ #include "turns-turn-order.h" +#include "turns-participant.h" + #include <catch2/catch_test_macros.hpp> +#include <gio/gio.h> #include <glib-object.h> SCENARIO("Creating a turn order", "[lib][object][lifetime]") @@ -29,5 +32,21 @@ SCENARIO("Creating a turn order", "[lib][object][lifetime]") REQUIRE_FALSE(property_value); } + + THEN("it's item count is 0") + { + REQUIRE(g_list_model_get_n_items(G_LIST_MODEL(instance)) == 0); + } + + THEN("it's item type is Turns.Participant") + { + REQUIRE(g_list_model_get_item_type(G_LIST_MODEL(instance)) == turns_participant_get_type()); + } + + THEN("it's first item is NULL") + { + REQUIRE(g_list_model_get_item(G_LIST_MODEL(instance), 0) == nullptr); + REQUIRE(g_list_model_get_object(G_LIST_MODEL(instance), 0) == nullptr); + } } }
\ No newline at end of file |
