aboutsummaryrefslogtreecommitdiff
path: root/src/test.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/test.cpp')
-rw-r--r--src/test.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/test.cpp b/src/test.cpp
index fe5a4f232..f81f2910c 100644
--- a/src/test.cpp
+++ b/src/test.cpp
@@ -698,6 +698,7 @@ struct TestInventory: public TestBase
{
std::string serialized_inventory =
"List 0 32\n"
+ "Width 3\n"
"Empty\n"
"Empty\n"
"Empty\n"
@@ -735,6 +736,7 @@ struct TestInventory: public TestBase
std::string serialized_inventory_2 =
"List main 32\n"
+ "Width 5\n"
"Empty\n"
"Empty\n"
"Empty\n"
@@ -778,6 +780,8 @@ struct TestInventory: public TestBase
inv.getList("0")->setName("main");
UASSERT(!inv.getList("0"));
UASSERT(inv.getList("main"));
+ UASSERT(inv.getList("main")->getWidth() == 3);
+ inv.getList("main")->setWidth(5);
std::ostringstream inv_os(std::ios::binary);
inv.serialize(inv_os);
UASSERT(inv_os.str() == serialized_inventory_2);