From 3ab26b9d7527f73d9a258ce4b6d15e915a4aebc1 Mon Sep 17 00:00:00 2001 From: Barry Warsaw Date: Mon, 9 Dec 1996 22:34:15 +0000 Subject: (testall.py): Slightly improved test harness to make it easier to add simple tests. (testall.py, testall.out): Added MD5 testsuite --- Lib/test/testall.out | 9 +++++++++ Lib/test/testall.py | 44 ++++++++------------------------------------ 2 files changed, 17 insertions(+), 36 deletions(-) diff --git a/Lib/test/testall.out b/Lib/test/testall.out index 4678122..2128435 100644 --- a/Lib/test/testall.out +++ b/Lib/test/testall.out @@ -167,4 +167,13 @@ tanh test_time test_array test_strop +test_md5 +MD5 test suite: +MD5 ("") = d41d8cd98f00b204e9800998ecf8427e +MD5 ("a") = 0cc175b9c0f1b6a831c399e269772661 +MD5 ("abc") = 900150983cd24fb0d6963f7d28e17f72 +MD5 ("message digest") = f96b697d7cb7938d525a2f31aaf161d0 +MD5 ("abcdefghijklmnopqrstuvwxyz") = c3fcd3d76192e4007dfb496cca67e13b +MD5 ("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789") = d174ab98d277d9f5a5611c2c9f419d9f +MD5 ("12345678901234567890123456789012345678901234567890123456789012345678901234567890") = 57edf4a22be3c955ac49da2e2107b67a Passed all tests. diff --git a/Lib/test/testall.py b/Lib/test/testall.py index f8ce346..b31dd98 100644 --- a/Lib/test/testall.py +++ b/Lib/test/testall.py @@ -4,45 +4,17 @@ # Remember to add new tests when new features are added! from test_support import * - + print 'test_grammar' forget('test_grammar') import test_grammar -print 'test_opcodes' -unload('test_opcodes') -import test_opcodes - -print 'test_operations' -unload('test_operations') -import test_operations - -print 'test_builtin' -unload('test_builtin') -import test_builtin - -print 'test_exceptions' -unload('test_exceptions') -import test_exceptions - -print 'test_types' -unload('test_types') -import test_types - -print 'test_math' -unload('test_math') -import test_math - -print 'test_time' -unload('test_time') -import test_time - -print 'test_array' -unload('test_array') -import test_array - -print 'test_strop' -unload('test_strop') -import test_strop +for t in ['test_opcodes', 'test_operations', 'test_builtin', + 'test_exceptions', 'test_types', 'test_math', 'test_time', + 'test_array', 'test_strop', 'test_md5', + ]: + print t + unload(t) + __import__(t, globals(), locals()) print 'Passed all tests.' -- cgit v0.12