diff --git a/test/algorithms/path_finding/distance.cpp b/test/algorithms/path_finding/distance.cpp index 8568e3099..975a223cd 100644 --- a/test/algorithms/path_finding/distance.cpp +++ b/test/algorithms/path_finding/distance.cpp @@ -227,9 +227,9 @@ TEST_CASE("2DDWave distance", "[distance]") CHECK(twoddwave_distance(layout, {0, 0}, {1, 1}) == 2); CHECK(twoddwave_distance(layout, {1, 2}, {3, 3}) == 3); CHECK(twoddwave_distance(layout, {0, 0}, {4, 4}) == 8); - CHECK(twoddwave_distance(layout, {4, 4}, {0, 0}) == std::numeric_limits::max()); - CHECK(twoddwave_distance(layout, {2, 1}, {0, 2}) == std::numeric_limits::max()); - CHECK(twoddwave_distance(layout, {1, 0}, {0, 1}) == std::numeric_limits::max()); + CHECK(twoddwave_distance(layout, {4, 4}, {0, 0}) == std::numeric_limits::max()); + CHECK(twoddwave_distance(layout, {2, 1}, {0, 2}) == std::numeric_limits::max()); + CHECK(twoddwave_distance(layout, {1, 0}, {0, 1}) == std::numeric_limits::max()); // ignore z-axis CHECK(twoddwave_distance(layout, {0, 0, 1}, {8, 9, 0}) == 17); @@ -247,18 +247,18 @@ TEST_CASE("2DDWave distance", "[distance]") CHECK(twoddwave_distance(layout, {0, 0}, {1, 1}) == 2); CHECK(twoddwave_distance(layout, {1, 2}, {3, 3}) == 3); CHECK(twoddwave_distance(layout, {0, 0}, {4, 4}) == 8); - CHECK(twoddwave_distance(layout, {4, 4}, {0, 0}) == std::numeric_limits::max()); - CHECK(twoddwave_distance(layout, {2, 1}, {0, 2}) == std::numeric_limits::max()); - CHECK(twoddwave_distance(layout, {1, 0}, {0, 1}) == std::numeric_limits::max()); + CHECK(twoddwave_distance(layout, {4, 4}, {0, 0}) == std::numeric_limits::max()); + CHECK(twoddwave_distance(layout, {2, 1}, {0, 2}) == std::numeric_limits::max()); + CHECK(twoddwave_distance(layout, {1, 0}, {0, 1}) == std::numeric_limits::max()); // ignore z-axis CHECK(twoddwave_distance(layout, {0, 0, 1}, {8, 9, 0}) == 17); CHECK(twoddwave_distance(layout, {0, 0, 1}, {8, 9, 1}) == 17); // negative coordinates - CHECK(twoddwave_distance(layout, {0, 0}, {-1, -1}) == std::numeric_limits::max()); - CHECK(twoddwave_distance(layout, {-2, -8}, {-6, -4}) == std::numeric_limits::max()); - CHECK(twoddwave_distance(layout, {-6, -4}, {-2, -8}) == std::numeric_limits::max()); + CHECK(twoddwave_distance(layout, {0, 0}, {-1, -1}) == std::numeric_limits::max()); + CHECK(twoddwave_distance(layout, {-2, -8}, {-6, -4}) == std::numeric_limits::max()); + CHECK(twoddwave_distance(layout, {-6, -4}, {-2, -8}) == std::numeric_limits::max()); CHECK(twoddwave_distance(layout, {-4, -3}, {1, -1}) == 7); } } @@ -279,7 +279,7 @@ TEST_CASE("2DDWave distance functor", "[distance]") CHECK(distance(layout, {0, 0}, {1, 1}) == 2); CHECK(distance(layout, {1, 2}, {3, 3}) == 3); CHECK(distance(layout, {0, 0}, {4, 4}) == 8); - CHECK(distance(layout, {4, 4}, {0, 0}) == std::numeric_limits::max()); + CHECK(distance(layout, {4, 4}, {0, 0}) == std::numeric_limits::max()); // ignore z-axis CHECK(distance(layout, {0, 0, 1}, {8, 9, 0}) == 17); @@ -299,16 +299,16 @@ TEST_CASE("2DDWave distance functor", "[distance]") CHECK(distance(layout, {0, 0}, {1, 1}) == 2); CHECK(distance(layout, {1, 2}, {3, 3}) == 3); CHECK(distance(layout, {0, 0}, {4, 4}) == 8); - CHECK(distance(layout, {4, 4}, {0, 0}) == std::numeric_limits::max()); + CHECK(distance(layout, {4, 4}, {0, 0}) == std::numeric_limits::max()); // ignore z-axis CHECK(distance(layout, {0, 0, 1}, {8, 9, 0}) == 17); CHECK(distance(layout, {0, 0, 1}, {8, 9, 1}) == 17); // negative coordinates - CHECK(distance(layout, {0, 0}, {-1, -1}) == std::numeric_limits::max()); - CHECK(distance(layout, {-2, -8}, {-6, -4}) == std::numeric_limits::max()); - CHECK(distance(layout, {-6, -4}, {-2, -8}) == std::numeric_limits::max()); + CHECK(distance(layout, {0, 0}, {-1, -1}) == std::numeric_limits::max()); + CHECK(distance(layout, {-2, -8}, {-6, -4}) == std::numeric_limits::max()); + CHECK(distance(layout, {-6, -4}, {-2, -8}) == std::numeric_limits::max()); CHECK(distance(layout, {-4, -3}, {1, -1}) == 7); } }