python-2.6: md5 import in test-archive helper
authorDirkjan Ochtman <dirkjan@ochtman.nl>
Tue, 08 Apr 2008 15:41:21 +0200
changeset 6496 118720f857b9
parent 6495 3130c9ded04e
child 6497 a0068c673de7
python-2.6: md5 import in test-archive helper
tests/test-archive
--- a/tests/test-archive	Tue Apr 08 15:42:43 2008 +0200
+++ b/tests/test-archive	Tue Apr 08 15:41:21 2008 +0200
@@ -40,10 +40,11 @@
 gzip -dc test-$QTIP.tar.gz | tar tf - | sed "s/$QTIP/TIP/"
 
 cat > md5comp.py <<EOF
-import md5, sys
+from mercurial.util import md5
+import sys
 f1, f2 = sys.argv[1:3]
-h1 = md5.md5(file(f1, 'rb').read()).hexdigest()
-h2 = md5.md5(file(f2, 'rb').read()).hexdigest()
+h1 = md5(file(f1, 'rb').read()).hexdigest()
+h2 = md5(file(f2, 'rb').read()).hexdigest()
 print h1 == h2 or "md5 differ: " + repr((h1, h2))
 EOF