[Zope-Checkins] CVS: Zope3/lib/python/Zope/Testing - CleanUp.py:1.3

Jeremy Hylton jeremy@zope.com
Thu, 5 Sep 2002 16:31:27 -0400


Update of /cvs-repository/Zope3/lib/python/Zope/Testing
In directory cvs.zope.org:/tmp/cvs-serv31565

Modified Files:
	CleanUp.py 
Log Message:
Make cleanUp a normal method instead of a module-level function.

XXX Perhaps cleanUp() was intended as a module-level function, but the
only use of it is as a method called from test suites that mix in
CleanUp.


=== Zope3/lib/python/Zope/Testing/CleanUp.py 1.2 => 1.3 ===
--- Zope3/lib/python/Zope/Testing/CleanUp.py:1.2	Mon Jun 10 19:29:45 2002
+++ Zope3/lib/python/Zope/Testing/CleanUp.py	Thu Sep  5 16:31:26 2002
@@ -49,13 +49,12 @@
     """
     _cleanups.append((func, args, kw))
 
-def cleanUp(ignored=None):
-    """Clean up global data
-    """
-    for func, args, kw in _cleanups:
-        func(*args, **kw)
-
 class CleanUp:
-    """Mix-in class providing clean-up setUp and tearDown routines
-    """
-    tearDown = setUp = cleanUp
+    """Mix-in class providing clean-up setUp and tearDown routines."""
+    
+    def cleanUp(self):
+        """Clean up global data."""
+        for func, args, kw in _cleanups:
+            func(*args, **kw)
+
+    setUp = tearDown = cleanUp