]> git.sesse.net Git - movit/commitdiff
Make it easier to turn on debug for the EffectChain test without having it be turned...
authorSteinar H. Gunderson <sgunderson@bigfoot.com>
Sat, 25 Nov 2017 11:31:02 +0000 (12:31 +0100)
committerSteinar H. Gunderson <sgunderson@bigfoot.com>
Sat, 25 Nov 2017 11:37:12 +0000 (12:37 +0100)
effect_chain_test.cpp

index f37738d57208345c4afe1ab9f88d7756ec7c6bfd..73f13c7957d7c8c4c0b66ea4cd50f4e464b6462b 100644 (file)
@@ -1228,6 +1228,7 @@ TEST(EffectChainTest, IdentityWithOwnPool) {
        float out_data[6], temp[6 * 4];
 
        EffectChain chain(width, height);
+       MovitDebugLevel old_movit_debug_level = movit_debug_level;
        movit_debug_level = MOVIT_DEBUG_ON;
 
        ImageFormat format;
@@ -1276,7 +1277,7 @@ TEST(EffectChainTest, IdentityWithOwnPool) {
        expect_equal(expected_data, out_data, width, height);
 
        // Reset the debug status again.
-       movit_debug_level = MOVIT_DEBUG_OFF;
+       movit_debug_level = old_movit_debug_level;
 }
 
 // A dummy effect whose only purpose is to test sprintf decimal behavior.