Added a test with bad/removed regions
This commit is contained in:
parent
67fdd6766f
commit
7fbcf05486
2 changed files with 13 additions and 0 deletions
|
|
@ -61,6 +61,15 @@ TEST_CASE("[Files] Underscore opcodes (underscore_opcodes.sfz)")
|
||||||
REQUIRE(synth.getRegionView(0)->loopMode == SfzLoopMode::loop_sustain);
|
REQUIRE(synth.getRegionView(0)->loopMode == SfzLoopMode::loop_sustain);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
TEST_CASE("[Files] (regions_bad.sfz)")
|
||||||
|
{
|
||||||
|
sfz::Synth synth;
|
||||||
|
synth.loadSfzFile(fs::current_path() / "tests/TestFiles/Regions/regions_bad.sfz");
|
||||||
|
REQUIRE(synth.getNumRegions() == 2);
|
||||||
|
REQUIRE(synth.getRegionView(0)->sample == "dummy.wav");
|
||||||
|
REQUIRE(synth.getRegionView(1)->sample == "dummy.wav");
|
||||||
|
}
|
||||||
|
|
||||||
TEST_CASE("[Files] Local include")
|
TEST_CASE("[Files] Local include")
|
||||||
{
|
{
|
||||||
sfz::Synth synth;
|
sfz::Synth synth;
|
||||||
|
|
|
||||||
4
tests/TestFiles/Regions/regions_bad.sfz
Normal file
4
tests/TestFiles/Regions/regions_bad.sfz
Normal file
|
|
@ -0,0 +1,4 @@
|
||||||
|
<region> sample=dummy.wav
|
||||||
|
<region> sample=nonexistent.wav
|
||||||
|
<region> sample=nonexistent.wav
|
||||||
|
<region> sample=dummy.wav
|
||||||
Loading…
Add table
Reference in a new issue