Fix a broken test

You need to render the block to see the voice in release state now,
which is normal
This commit is contained in:
Paul Ferrand 2020-02-18 14:45:24 +01:00
parent 87c3cfaced
commit 4af3ac4e55

View file

@ -400,6 +400,7 @@ TEST_CASE("[Files] Off by with different delays")
{ {
sfz::Synth synth; sfz::Synth synth;
synth.setSamplesPerBlock(256); synth.setSamplesPerBlock(256);
sfz::AudioBuffer<float> buffer(2, 256);
synth.loadSfzFile(fs::current_path() / "tests/TestFiles/off_by.sfz"); synth.loadSfzFile(fs::current_path() / "tests/TestFiles/off_by.sfz");
REQUIRE( synth.getNumRegions() == 4 ); REQUIRE( synth.getNumRegions() == 4 );
synth.noteOn(0, 63, 63); synth.noteOn(0, 63, 63);
@ -408,6 +409,7 @@ TEST_CASE("[Files] Off by with different delays")
REQUIRE( group1Voice->getRegion()->group == 1ul ); REQUIRE( group1Voice->getRegion()->group == 1ul );
REQUIRE( group1Voice->getRegion()->offBy == 2ul ); REQUIRE( group1Voice->getRegion()->offBy == 2ul );
synth.noteOn(100, 64, 63); synth.noteOn(100, 64, 63);
synth.renderBlock(buffer);
REQUIRE( group1Voice->canBeStolen() ); REQUIRE( group1Voice->canBeStolen() );
} }