From: Guido van Rossum Date: Wed, 21 May 1997 14:27:20 +0000 (+0000) Subject: Fix ratecv test (Sjoerd). X-Git-Tag: v1.5a3~507 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=05ba2ab720dff2a2966a481329a4f90bea5eea85;p=thirdparty%2FPython%2Fcpython.git Fix ratecv test (Sjoerd). --- diff --git a/Lib/test/test_audioop.py b/Lib/test/test_audioop.py index e9668338536f..a03fe60ac5c4 100644 --- a/Lib/test/test_audioop.py +++ b/Lib/test/test_audioop.py @@ -171,11 +171,12 @@ def testmul(data): def testratecv(data): if verbose: - print 'ratecv' - state = (-8000, ((256, 512),)) - if audioop.ratecv(data[0], 1, 1, 8000, 16000, state) != \ - ('\001\000\000\001\001\002', state): - return 0 + print 'ratecv' + state = None + d1, state = audioop.ratecv(data[0], 1, 1, 8000, 16000, state) + d2, state = audioop.ratecv(data[0], 1, 1, 8000, 16000, state) + if d1 + d2 != '\000\000\001\001\002\001\000\000\001\001\002': + return 0 return 1 def testreverse(data):