Skip to content

Commit

Permalink
Yet more testing by telephone with github's CI
Browse files Browse the repository at this point in the history
  • Loading branch information
RenechCDDA committed Aug 24, 2024
1 parent d91ec5f commit f2f86d5
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions tests/water_movement_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -262,9 +262,13 @@ static int swimming_steps( avatar &swimmer )
{
map &here = get_map();
// This shouldn't work.
avatar_action::move( swimmer, here, tripoint_west );
CAPTURE( swimmer.pos() );
avatar_action::move( swimmer, here, swimmer.pos() + tripoint_west );
CAPTURE( swimmer.pos() );
const tripoint left = swimmer.pos();
const tripoint right = left + tripoint_east;
CAPTURE( left );
CAPTURE( right );
int steps = 0;
constexpr int STOP_STEPS = 9000;
int last_moves = swimmer.get_speed();
Expand All @@ -274,10 +278,10 @@ static int swimming_steps( avatar &swimmer )
while( swimmer.get_stamina() > 0 && !swimmer.has_effect( effect_winded ) && steps < STOP_STEPS ) {
if( steps % 2 == 0 ) {
REQUIRE( swimmer.pos() == left );
REQUIRE( avatar_action::move( swimmer, here, swimmer.pos() + tripoint_east ) );
REQUIRE( avatar_action::move( swimmer, here, right ) );

Check failure on line 281 in tests/water_movement_test.cpp

View workflow job for this annotation

GitHub Actions / Basic Build and Test (Clang 10, Ubuntu, Curses)

false

Check failure on line 281 in tests/water_movement_test.cpp

View workflow job for this annotation

GitHub Actions / Basic Build and Test (Clang 10, Ubuntu, Curses)

false

Check failure on line 281 in tests/water_movement_test.cpp

View workflow job for this annotation

GitHub Actions / Basic Build and Test (Clang 10, Ubuntu, Curses)

false

Check failure on line 281 in tests/water_movement_test.cpp

View workflow job for this annotation

GitHub Actions / Basic Build and Test (Clang 10, Ubuntu, Curses)

false

Check failure on line 281 in tests/water_movement_test.cpp

View workflow job for this annotation

GitHub Actions / Basic Build and Test (Clang 10, Ubuntu, Curses)

false

Check failure on line 281 in tests/water_movement_test.cpp

View workflow job for this annotation

GitHub Actions / Basic Build and Test (Clang 10, Ubuntu, Curses)

false

Check failure on line 281 in tests/water_movement_test.cpp

View workflow job for this annotation

GitHub Actions / Basic Build and Test (Clang 10, Ubuntu, Curses)

false

Check failure on line 281 in tests/water_movement_test.cpp

View workflow job for this annotation

GitHub Actions / Basic Build and Test (Clang 10, Ubuntu, Curses)

false

Check failure on line 281 in tests/water_movement_test.cpp

View workflow job for this annotation

GitHub Actions / Basic Build and Test (Clang 10, Ubuntu, Curses)

false

Check failure on line 281 in tests/water_movement_test.cpp

View workflow job for this annotation

GitHub Actions / Basic Build and Test (Clang 10, Ubuntu, Curses)

false
} else {
REQUIRE( swimmer.pos() == right );
REQUIRE( avatar_action::move( swimmer, here, swimmer.pos() + tripoint_west ) );
REQUIRE( avatar_action::move( swimmer, here, left ) );
}
++steps;
REQUIRE( swimmer.get_moves() < last_moves );
Expand Down

0 comments on commit f2f86d5

Please sign in to comment.