[Zope3-checkins] SVN: Zope3/trunk/src/zope/app/ Fixed zope.app.server.tests.test_mkzopeinstance broken by my previous commit

Dmitry Vasiliev dima at hlabs.spb.ru
Tue Apr 24 12:15:35 EDT 2007


Log message for revision 74706:
  Fixed zope.app.server.tests.test_mkzopeinstance broken by my previous commit

Changed:
  U   Zope3/trunk/src/zope/app/authentication/password.py
  U   Zope3/trunk/src/zope/app/server/tests/test_mkzopeinstance.py

-=-
Modified: Zope3/trunk/src/zope/app/authentication/password.py
===================================================================
--- Zope3/trunk/src/zope/app/authentication/password.py	2007-04-24 15:38:00 UTC (rev 74705)
+++ Zope3/trunk/src/zope/app/authentication/password.py	2007-04-24 16:15:34 UTC (rev 74706)
@@ -79,7 +79,7 @@
     False
 
     >>> encoded = manager.encodePassword(password)
-    >>> encoded[8:]
+    >>> encoded[-32:]
     '86dddccec45db4599f1ac00018e54139'
     >>> manager.checkPassword(encoded, password)
     True
@@ -121,7 +121,7 @@
     False
 
     >>> encoded = manager.encodePassword(password)
-    >>> encoded[8:]
+    >>> encoded[-40:]
     '04b4eec7154c5f3a2ec6d2956fb80b80dc737402'
     >>> manager.checkPassword(encoded, password)
     True

Modified: Zope3/trunk/src/zope/app/server/tests/test_mkzopeinstance.py
===================================================================
--- Zope3/trunk/src/zope/app/server/tests/test_mkzopeinstance.py	2007-04-24 15:38:00 UTC (rev 74705)
+++ Zope3/trunk/src/zope/app/server/tests/test_mkzopeinstance.py	2007-04-24 16:15:34 UTC (rev 74706)
@@ -266,7 +266,7 @@
         app = ControlledInputApplication(options, ["3"])
         name, pwm = app.get_password_manager()
         self.assertEqual(name, "SHA1")
-        self.assertEqual(pwm.encodePassword("foo"),
+        self.assertEqual(pwm.encodePassword("foo")[-40:],
             "0beec7b5ea3f0fdbc95d0dd47f3c5bc275da8a33")
         self.failIf(self.stderr.getvalue())
         self.failUnless(self.stdout.getvalue())



More information about the Zope3-Checkins mailing list