mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-14 22:05:56 +08:00
Fix warnings in Travels tests.
This commit is contained in:
parent
ff30d7aad3
commit
5858cbf0f7
@ -16,8 +16,8 @@ struct ApproxEqualsPoints : public Catch::MatcherBase<Points> {
|
|||||||
const Point& point = points[i];
|
const Point& point = points[i];
|
||||||
const Point& expected_point = this->expected[i];
|
const Point& expected_point = this->expected[i];
|
||||||
if (
|
if (
|
||||||
std::abs(point.x() - expected_point.x()) > this->tolerance
|
std::abs(point.x() - expected_point.x()) > int(this->tolerance)
|
||||||
|| std::abs(point.y() - expected_point.y()) > this->tolerance
|
|| std::abs(point.y() - expected_point.y()) > int(this->tolerance)
|
||||||
) {
|
) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -117,10 +117,10 @@ TEST_CASE("Generate elevated travel", "[GCode]") {
|
|||||||
Points3 result{generate_elevated_travel(xy_path, ensure_points_at_distances, 2.0, [](double x){return 1 + x;})};
|
Points3 result{generate_elevated_travel(xy_path, ensure_points_at_distances, 2.0, [](double x){return 1 + x;})};
|
||||||
|
|
||||||
CHECK(result == Points3{
|
CHECK(result == Points3{
|
||||||
scaled(Vec3f{0, 0, 3.0}),
|
scaled(Vec3f{ 0.f, 0.f, 3.f}),
|
||||||
scaled(Vec3f{0.2, 0, 3.2}),
|
scaled(Vec3f{0.2f, 0.f, 3.2f}),
|
||||||
scaled(Vec3f{0.5, 0, 3.5}),
|
scaled(Vec3f{0.5f, 0.f, 3.5f}),
|
||||||
scaled(Vec3f{1, 0, 4.0})
|
scaled(Vec3f{ 1.f, 0.f, 4.f})
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user