[Python-checkins] CVS: python/dist/src/Lib/test test_zlib.py,1.6,1.7

Fred L. Drake fdrake@weyr.cnri.reston.va.us
2000年2月10日 10:31:10 -0500 (EST)


Update of /projects/cvsroot/python/dist/src/Lib/test
In directory weyr:/home/fdrake/projects/python/Lib/test
Modified Files:
	test_zlib.py 
Log Message:
Make this pass the -tt test.
Index: test_zlib.py
===================================================================
RCS file: /projects/cvsroot/python/dist/src/Lib/test/test_zlib.py,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -r1.6 -r1.7
*** test_zlib.py	1999年03月22日 19:23:17	1.6
--- test_zlib.py	2000年02月10日 15:31:07	1.7
***************
*** 81,92 ****
 for sync in [zlib.Z_NO_FLUSH, zlib.Z_SYNC_FLUSH, zlib.Z_FULL_FLUSH]:
 for level in range(10):
! 	obj = zlib.compressobj( level )
! 	d = obj.compress( buf[:3000] )
! 	d = d + obj.flush( sync )
! 	d = d + obj.compress( buf[3000:] )
! 	d = d + obj.flush()
! 	if zlib.decompress(d) != buf:
! 	 print "Decompress failed: flush mode=%i, level=%i" % (sync,level)
! 	del obj
 
 def ignore():
--- 81,92 ----
 for sync in [zlib.Z_NO_FLUSH, zlib.Z_SYNC_FLUSH, zlib.Z_FULL_FLUSH]:
 for level in range(10):
! obj = zlib.compressobj( level )
! d = obj.compress( buf[:3000] )
! d = d + obj.flush( sync )
! d = d + obj.compress( buf[3000:] )
! d = d + obj.flush()
! if zlib.decompress(d) != buf:
! print "Decompress failed: flush mode=%i, level=%i" % (sync,level)
! del obj
 
 def ignore():

AltStyle によって変換されたページ (->オリジナル) /