From: Paul Brossier Date: Sun, 14 Apr 2013 19:26:04 +0000 (-0500) Subject: tests/test_aubio_pitch.py: rename and use unit_timeside X-Git-Tag: 0.5.0~115^2~44 X-Git-Url: https://git.parisson.com/?a=commitdiff_plain;h=07b43a3a679a4ee4317fe770427cce06b65bdca0;p=timeside.git tests/test_aubio_pitch.py: rename and use unit_timeside --- diff --git a/tests/test_aubio_pitch.py b/tests/test_aubio_pitch.py new file mode 100755 index 0000000..31ffb58 --- /dev/null +++ b/tests/test_aubio_pitch.py @@ -0,0 +1,26 @@ +#! /usr/bin/env python + +from unit_timeside import * +from timeside.decoder import * +from timeside.analyzer.aubio_pitch import AubioPitch + +class TestAubioPitch(TestCase): + + def setUp(self): + self.analyzer = AubioPitch() + + def testOnSweep(self): + "runs on sweep" + self.source = os.path.join (os.path.dirname(__file__), "samples", "sweep.wav") + + def testOnGuitar(self): + "runs on guitar" + self.source = os.path.join (os.path.dirname(__file__), "samples", "guitar.wav") + + def tearDown(self): + decoder = FileDecoder(self.source) + (decoder | self.analyzer).run() + #print "result:", self.analyzer.result() + +if __name__ == '__main__': + unittest.main(testRunner=TestRunner()) diff --git a/tests/testaubio_pitch.py b/tests/testaubio_pitch.py deleted file mode 100755 index 02990d0..0000000 --- a/tests/testaubio_pitch.py +++ /dev/null @@ -1,27 +0,0 @@ -#! /usr/bin/env python - -from unittest import TestCase -from timeside.decoder import * -from timeside.analyzer.aubio_pitch import AubioPitch - -class TestAubioPitch(TestCase): - - def setUp(self): - self.analyzer = AubioPitch() - - def testOnSweep(self): - "runs on sweep" - self.source = os.path.join (os.path.dirname(__file__), "samples", "sweep.wav") - - def testOnGuitar(self): - "runs on guitar" - self.source = os.path.join (os.path.dirname(__file__), "samples", "guitar.wav") - - def tearDown(self): - decoder = FileDecoder(self.source) - (decoder | self.analyzer).run() - #print "result:", self.analyzer.result() - -if __name__ == '__main__': - from unittest import main - main()