Skip to content

Commit

Permalink
fix: Coherency of the GUI tests for the teams
Browse files Browse the repository at this point in the history
  • Loading branch information
Thomaltarix committed Jun 23, 2024
1 parent 323e0b1 commit 25862d9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions tests/gui/tests/GUIUpdater/TestGUIUpdater.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -227,8 +227,8 @@ Test(GUIUpdater, updatePlayerPosition, .timeout = 5)
gameData->addTeam(team);
gameData->addPlayerToTeam("TEAM1", player);

gameData->addTeam("TEAM1", (Color){0, 0, 0, 0});
gameData->addPlayerToTeam("TEAM1", Gui::Player(1, "TEAM1", std::make_pair(1, 1), 1, 1));
gameData->addTeam("TEAM2", (Color){0, 0, 0, 0});
gameData->addPlayerToTeam("TEAM2", Gui::Player(1, "TEAM2", std::make_pair(1, 1), 1, 1));

guiUpdater.update("ppo", {"1", "1", "1", "1"});
cr_assert_eq(gameData->getTeam("TEAM1").getPlayer(1).get()->getPosition().first, 1);
Expand Down
2 changes: 1 addition & 1 deletion tests/gui/tests/GameDatas/TestTeam.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@ Test(Team, getPlayerColor, .timeout = 5)
{
Model model;
ModelAnimation *modelAnimation = nullptr;
Gui::Team team("TEAM1", model, model, modelAnimation, (Color){0, 0, 0, 0});
Gui::Team team("TEAM1", model, model, modelAnimation, (Color){255, 255, 255, 255});

Color color = team.getPlayerColor();
cr_assert_eq(color.r, 255);
Expand Down

0 comments on commit 25862d9

Please sign in to comment.