From 0b4f424f414380b7a46270e1389e8aa0524d8fba Mon Sep 17 00:00:00 2001 From: SmallJoker Date: Sat, 24 Aug 2019 19:07:38 +0200 Subject: Inventory: Send dirty lists where appropriate (#8742) This change reduces the amount of sent data towards clients. Inventory lists that are already known to the player are skipped, saving quite some data over time. Raises protocol version to 38 to ensure correct backwards-compatible code. --- src/unittest/test_servermodmanager.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/unittest/test_servermodmanager.cpp') diff --git a/src/unittest/test_servermodmanager.cpp b/src/unittest/test_servermodmanager.cpp index 72ac7c6bf..0757323f4 100644 --- a/src/unittest/test_servermodmanager.cpp +++ b/src/unittest/test_servermodmanager.cpp @@ -20,6 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include "test.h" #include #include "server/mods.h" +#include "settings.h" #include "test_config.h" class TestServerModManager : public TestBase @@ -85,6 +86,10 @@ void TestServerModManager::runTests(IGameDef *gamedef) void TestServerModManager::testCreation() { + std::string path = std::string(TEST_WORLDDIR) + DIR_DELIM + "world.mt"; + Settings world_config; + world_config.set("gameid", "minimal"); + UASSERTEQ(bool, world_config.updateConfigFile(path.c_str()), true); ServerModManager sm(TEST_WORLDDIR); } -- cgit v1.2.3