mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-13 00:25:19 +02:00
Move hard coded minimap to builtin (#14071)
This commit is contained in:
@@ -30,7 +30,6 @@ public:
|
||||
void runTests(IGameDef *gamedef);
|
||||
|
||||
void testInit();
|
||||
void testFlagSetters();
|
||||
void testInfoText();
|
||||
void testStatusText();
|
||||
};
|
||||
@@ -40,7 +39,6 @@ static TestGameUI g_test_instance;
|
||||
void TestGameUI::runTests(IGameDef *gamedef)
|
||||
{
|
||||
TEST(testInit);
|
||||
TEST(testFlagSetters);
|
||||
TEST(testInfoText);
|
||||
TEST(testStatusText);
|
||||
}
|
||||
@@ -51,30 +49,18 @@ void TestGameUI::testInit()
|
||||
// Ensure flags on GameUI init
|
||||
UASSERT(gui.getFlags().show_chat)
|
||||
UASSERT(gui.getFlags().show_hud)
|
||||
UASSERT(!gui.getFlags().show_minimap)
|
||||
UASSERT(!gui.getFlags().show_profiler_graph)
|
||||
|
||||
// And after the initFlags init stage
|
||||
gui.initFlags();
|
||||
UASSERT(gui.getFlags().show_chat)
|
||||
UASSERT(gui.getFlags().show_hud)
|
||||
UASSERT(!gui.getFlags().show_minimap)
|
||||
UASSERT(!gui.getFlags().show_profiler_graph)
|
||||
|
||||
// @TODO verify if we can create non UI nulldevice to test this function
|
||||
// gui.init();
|
||||
}
|
||||
|
||||
void TestGameUI::testFlagSetters()
|
||||
{
|
||||
GameUI gui{};
|
||||
gui.showMinimap(true);
|
||||
UASSERT(gui.getFlags().show_minimap);
|
||||
|
||||
gui.showMinimap(false);
|
||||
UASSERT(!gui.getFlags().show_minimap);
|
||||
}
|
||||
|
||||
void TestGameUI::testStatusText()
|
||||
{
|
||||
GameUI gui{};
|
||||
|
Reference in New Issue
Block a user