[Zope3-checkins] CVS: Zope3/src/zope/app/rdb/tests - test_sqlcommand.py:1.1.2.3

Fred L. Drake, Jr. fred@zope.com
Tue, 24 Dec 2002 12:40:14 -0500


Update of /cvs-repository/Zope3/src/zope/app/rdb/tests
In directory cvs.zope.org:/tmp/cvs-serv15014

Modified Files:
      Tag: NameGeddon-branch
	test_sqlcommand.py 
Log Message:
- fix typo
- conform to Zope 3 test style
- whitespace normalization


=== Zope3/src/zope/app/rdb/tests/test_sqlcommand.py 1.1.2.2 => 1.1.2.3 ===
--- Zope3/src/zope/app/rdb/tests/test_sqlcommand.py:1.1.2.2	Tue Dec 24 07:51:14 2002
+++ Zope3/src/zope/app/rdb/tests/test_sqlcommand.py	Tue Dec 24 12:40:14 2002
@@ -15,19 +15,18 @@
 $Id$
 """
 
-from unittest import TestCase, TestSuite, main, makeSuite
+import unittest
 
-from zope.app.rdb import SQLCommand
+from zope.app.component import nextservice
 from zope.app.interfaces.rdb import IConnectionService
 from zope.app.interfaces.rdb import IZopeConnection
 from zope.app.interfaces.rdb import IZopeCursor
-from zope.app.component import nextservice
+from zope.app.rdb import SQLCommand
 from zope.app.tests.placelesssetup import PlacelessSetup
-from zope.component.service import \
-     serviceManager as sm
+from zope.component.service import serviceManager as sm
 
 
-# Make spme fixes, so that we overcome some of the natural ZODB properties
+# Make some fixes, so that we overcome some of the natural ZODB properties
 def getNextServiceManager(context):
     return sm
 
@@ -60,8 +59,7 @@
         return ConnectionStub()
 
 
-class Test(TestCase, PlacelessSetup):
-
+class SQLCommandTest(unittest.TestCase, PlacelessSetup):
 
     def setUp(self):
         PlacelessSetup.setUp(self)
@@ -71,8 +69,7 @@
         nextservice.getNextServiceManager = getNextServiceManager
 
     def tearDown(self):
-        nextservice.getNextServiceManager = self._old_getNextServicemanager
-
+        nextservice.getNextServiceManager = self._old_getNextServiceManager
 
     def testsimp(self):
         command = SQLCommand("my_connection", "SELECT id FROM Table")
@@ -82,10 +79,7 @@
 
 
 def test_suite():
-    return makeSuite(Test)
+    return unittest.makeSuite(SQLCommandTest)
 
 if __name__=='__main__':
-    main(defaultTest='test_suite')
-
-
-
+    unittest.main(defaultTest='test_suite')