diff options
-rw-r--r-- | tests/CMakeLists.txt | 5 | ||||
-rw-r--r-- | tests/regression/dumptest/example001-expected.txt | 22 |
2 files changed, 26 insertions, 1 deletions
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 6088ebc..0e6c852 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -323,6 +323,9 @@ file(GLOB FEATURES_FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/features/*.scad) file(GLOB BUGS_FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/bugs/*.scad) file(GLOB SCAD_DXF_FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/dxf/*.scad) +list(APPEND DUMPTEST_FILES ${MINIMAL_FILES} + ${CMAKE_SOURCE_DIR}/../examples/example001.scad) + list(APPEND ECHO_FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/minimal/echo.scad ${CMAKE_SOURCE_DIR}/../testdata/scad/features/echo-tests.scad) @@ -330,7 +333,7 @@ list(APPEND ECHO_FILES # Add echotest tests to CTest add_cmdline_test(echotest txt ${ECHO_FILES}) # Add dumptest tests to CTest -add_cmdline_test(dumptest txt ${MINIMAL_FILES}) +add_cmdline_test(dumptest txt ${DUMPTEST_FILES}) # Add csgtexttest tests to CTest add_cmdline_test(csgtexttest txt ${MINIMAL_FILES}) # Add csgtermtest tests to CTest diff --git a/tests/regression/dumptest/example001-expected.txt b/tests/regression/dumptest/example001-expected.txt new file mode 100644 index 0000000..ab7e4e9 --- /dev/null +++ b/tests/regression/dumptest/example001-expected.txt @@ -0,0 +1,22 @@ +group() { + group() { + difference() { + sphere($fn = 0, $fa = 12, $fs = 1, r = 25); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 62.5, r1 = 12.5, r2 = 12.5, center = true); + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 62.5, r1 = 12.5, r2 = 12.5, center = true); + } + } + group() { + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 62.5, r1 = 12.5, r2 = 12.5, center = true); + } + } + } + } +} |