2 #include <msp/core/maputils.h>
3 #include <msp/test/test.h>
8 class MapUtilTests: public Test::RegisteredTest<MapUtilTests>
13 static const char *get_name() { return "maputils"; }
21 MapUtilTests::MapUtilTests()
23 add(&MapUtilTests::success, "success");
24 add(&MapUtilTests::error, "error").expect_throw<key_error>();
27 void MapUtilTests::success()
32 EXPECT_EQUAL(get_item(m, 1), "foo");
33 EXPECT_EQUAL(get_item(m, 3), "bar");
36 void MapUtilTests::error()