Initial release
Some checks failed
My Build All / build_windows (push) Has been cancelled
My Build All / build_linux_portable (push) Has been cancelled
My Build All / build_linux_appimage (push) Has been cancelled
My Build All / build_macos (push) Has been cancelled
My Build All / Publish release assets (push) Has been cancelled
Shellcheck / Shellcheck (push) Has been cancelled
Some checks failed
My Build All / build_windows (push) Has been cancelled
My Build All / build_linux_portable (push) Has been cancelled
My Build All / build_linux_appimage (push) Has been cancelled
My Build All / build_macos (push) Has been cancelled
My Build All / Publish release assets (push) Has been cancelled
Shellcheck / Shellcheck (push) Has been cancelled
This commit is contained in:
commit
c661ddc2eb
16967 changed files with 4075897 additions and 0 deletions
22
tests/fff_print/test_gcode.cpp
Normal file
22
tests/fff_print/test_gcode.cpp
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
#include <catch2/catch_all.hpp>
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include "libslic3r/GCode.hpp"
|
||||
|
||||
using namespace Slic3r;
|
||||
|
||||
SCENARIO("Origin manipulation", "[GCode]") {
|
||||
Slic3r::GCode gcodegen;
|
||||
WHEN("set_origin to (10,0)") {
|
||||
gcodegen.set_origin(Vec2d(10,0));
|
||||
REQUIRE(gcodegen.origin() == Vec2d(10, 0));
|
||||
}
|
||||
WHEN("set_origin to (10,0) and translate by (5, 5)") {
|
||||
gcodegen.set_origin(Vec2d(10,0));
|
||||
gcodegen.set_origin(gcodegen.origin() + Vec2d(5, 5));
|
||||
THEN("origin returns reference to point") {
|
||||
REQUIRE(gcodegen.origin() == Vec2d(15,5));
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue