From 1ef11e61d31e5b2dd61f916005aa91013be9cc65 Mon Sep 17 00:00:00 2001 From: Paul Brossier Date: Wed, 1 Aug 2012 12:54:48 -0600 Subject: [PATCH] tests/testdecoding.py: use release() --- tests/testdecoding.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/tests/testdecoding.py b/tests/testdecoding.py index 45c787c..042c964 100644 --- a/tests/testdecoding.py +++ b/tests/testdecoding.py @@ -3,8 +3,6 @@ from unit_timeside import * import os.path -__all__ = ['TestDecoding'] - class TestDecoding(TestCase): "Test the low level streaming features" @@ -36,7 +34,9 @@ class TestDecoding(TestCase): while True: frames, eod = decoder.process() totalframes += frames.shape[0] - if eod: break + if eod or decoder.eod: break + + decoder.release() # FIXME compute actual number of frames from file if os.path.splitext(self.source)[-1].lower() == '.mp3': @@ -48,5 +48,3 @@ class TestDecoding(TestCase): if __name__ == '__main__': unittest.main(testRunner=TestRunner()) - - -- 2.39.5