diff --git a/tests/FilesT.cpp b/tests/FilesT.cpp index 20e5ab4b..3697f445 100644 --- a/tests/FilesT.cpp +++ b/tests/FilesT.cpp @@ -316,3 +316,11 @@ TEST_CASE("[Files] wrong (overlapping) replacement for defines") REQUIRE( synth.getRegionView(2)->amplitudeCC->first == 10 ); REQUIRE( synth.getRegionView(2)->amplitudeCC->second == 34.0f ); } + +TEST_CASE("[Files] Specific bug: relative path with backslashes") +{ + sfz::Synth synth; + synth.loadSfzFile(fs::current_path() / "tests/TestFiles/SpecificBugs/win_backslashes.sfz"); + REQUIRE(synth.getNumRegions() == 1); + REQUIRE(synth.getRegionView(0)->sample == R"(closedhat.wav)"); +} diff --git a/tests/TestFiles/SpecificBugs/Xylo/Subfolder/closedhat.wav b/tests/TestFiles/SpecificBugs/Xylo/Subfolder/closedhat.wav new file mode 100755 index 00000000..d31835e5 Binary files /dev/null and b/tests/TestFiles/SpecificBugs/Xylo/Subfolder/closedhat.wav differ diff --git a/tests/TestFiles/SpecificBugs/win_backslashes.sfz b/tests/TestFiles/SpecificBugs/win_backslashes.sfz new file mode 100644 index 00000000..33b577b0 --- /dev/null +++ b/tests/TestFiles/SpecificBugs/win_backslashes.sfz @@ -0,0 +1,4 @@ + +default_path=Xylo\Subfolder\ + + sample=closedhat.wav