Skip to content

Commit

Permalink
CI tests for EditBox were still using limitTextWidth
Browse files Browse the repository at this point in the history
  • Loading branch information
texus committed May 4, 2024
1 parent 1b80bee commit ff24830
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/Widgets/EditBox.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -133,14 +133,14 @@ TEST_CASE("[EditBox]")
REQUIRE(editBox->getAlignment() == tgui::HorizontalAlignment::Left);
}

SECTION("LimitTextWidth")
SECTION("TextWidthLimited")
{
editBox->setTextSize(20);
editBox->setSize(100, 25);
editBox->setText("too long text");

REQUIRE(!editBox->isTextWidthLimited());
editBox->limitTextWidth(true);
editBox->setTextWidthLimited(true);
REQUIRE(editBox->isTextWidthLimited());
REQUIRE(editBox->getText() == "too long ");

Expand All @@ -149,7 +149,7 @@ TEST_CASE("[EditBox]")
editBox->setText("yet another text");
REQUIRE(editBox->getText() == "yet anot");

editBox->limitTextWidth(false);
editBox->setTextWidthLimited(false);
REQUIRE(!editBox->isTextWidthLimited());

editBox->setText("some other text");
Expand Down Expand Up @@ -609,7 +609,7 @@ TEST_CASE("[EditBox]")
editBox->setPasswordCharacter('*');
editBox->setMaximumCharacters(5);
editBox->setAlignment(tgui::HorizontalAlignment::Right);
editBox->limitTextWidth();
editBox->setTextWidthLimited(true);
editBox->setReadOnly(true);
editBox->setInputValidator("[0-9a-zA-Z]*");

Expand Down

0 comments on commit ff24830

Please sign in to comment.