Skip to content

Commit

Permalink
Testing 3mf reading file with umlauts in it's path
Browse files Browse the repository at this point in the history
  • Loading branch information
3bhady authored and lordofhyphens committed Apr 3, 2019
1 parent e6c7590 commit 8dc4e64
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,7 @@ set(SLIC3R_INCLUDES
)
set(LIBSLIC3R_INCLUDES
${LIBDIR}/libslic3r
${LIBDIR}/libslic3r/IO
)


Expand Down Expand Up @@ -313,6 +314,7 @@ set(SLIC3R_TEST_SOURCES
${TESTDIR}/libslic3r/test_skirt_brim.cpp
${TESTDIR}/libslic3r/test_test_data.cpp
${TESTDIR}/libslic3r/test_trianglemesh.cpp
${TESTDIR}/libslic3r/test_3mf.cpp
)


Expand Down
Binary file added src/test/inputs/test_3mf/Geräte/box.3mf
Binary file not shown.
20 changes: 20 additions & 0 deletions src/test/libslic3r/test_3mf.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
#include <catch.hpp>
#include <test_options.hpp>
#include <string>
#include "Model.hpp"
#include "TMF.hpp"


using namespace Slic3r;

SCENARIO("Reading 3mf file") {
GIVEN("umlauts in the path of the file") {
auto model {new Slic3r::Model()};
WHEN("3mf model is read") {
auto ret = Slic3r::IO::TMF::read(std::string(testfile_dir) +"test_3mf/Geräte/box.3mf",model);
THEN("read should not return 0") {
REQUIRE(ret == 1);
}
}
}
}
Binary file added xs/t/models/Geräte/box.3mf
Binary file not shown.

0 comments on commit 8dc4e64

Please sign in to comment.