mirror of
https://github.com/luanti-org/luanti.git
synced 2025-07-22 17:18:39 +00:00
Move hard coded minimap to builtin (#14071)
This commit is contained in:
parent
f2b99332d9
commit
adaa4cc2f3
20 changed files with 51 additions and 87 deletions
|
@ -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{};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue