[Zope3-checkins] CVS: Packages/SFTPGateway/src/ZConfig/tests - test_schema.py:1.21

Fred L. Drake, Jr. fred at zope.com
Sun Dec 28 21:54:45 EST 2003


Update of /cvs-repository/Packages/SFTPGateway/src/ZConfig/tests
In directory cvs.zope.org:/tmp/cvs-serv25842

Modified Files:
	test_schema.py 
Log Message:
- remove some unused local assignments
- avoid ugliness with Emacs font-lock


=== Packages/SFTPGateway/src/ZConfig/tests/test_schema.py 1.20 => 1.21 ===
--- Packages/SFTPGateway/src/ZConfig/tests/test_schema.py:1.20	Sun Dec 28 21:43:03 2003
+++ Packages/SFTPGateway/src/ZConfig/tests/test_schema.py	Sun Dec 28 21:54:44 2003
@@ -734,57 +734,54 @@
 
     def test_simple_extends(self):
         schema = self.load_schema_text("""\
-           <schema extends="%s/simple.xml %s/library.xml">
-             <section name="A" type="type-a" />
+           <schema extends='%s/simple.xml %s/library.xml'>
+             <section name='A' type='type-a' />
            </schema>
-           """ % (CONFIG_BASE,CONFIG_BASE))
+           """ % (CONFIG_BASE, CONFIG_BASE))
         self._verifySimpleConf(self.load_config(schema, "simple.conf"))
 
     def test_extends_fragment_failure(self):
        self.assertRaises(ZConfig.SchemaError,
-                          self.load_schema_text, """\
-           <schema extends="%s/library.xml#foo" />
-           """ % CONFIG_BASE)
+                         self.load_schema_text,
+           "<schema extends='%s/library.xml#foo'/>" % CONFIG_BASE)
 
     def test_multi_extends_implicit_OK(self):
-        schema = self.load_schema_text("""\
-           <schema extends="%s/base.xml %s/library.xml">
-             <section name="A" type="type-a" />
-             <section name="X" type="type-X" />
+        self.load_schema_text("""\
+           <schema extends='%s/base.xml %s/library.xml'>
+             <section name='A' type='type-a' />
+             <section name='X' type='type-X' />
            </schema>
-           """ % (CONFIG_BASE,CONFIG_BASE))
+           """ % (CONFIG_BASE, CONFIG_BASE))
 
     def test_multi_extends_explicit_datatype_OK(self):
-        schema = self.load_schema_text("""\
-           <schema extends="%s/base-datatype1.xml %s/base-datatype2.xml"
-                   datatype="null">
-             <section name="One" type="type-1" />
-             <section name="Two" type="type-2" />
+        self.load_schema_text("""\
+           <schema extends='%s/base-datatype1.xml %s/base-datatype2.xml'
+                   datatype='null'>
+             <section name='One' type='type-1' />
+             <section name='Two' type='type-2' />
            </schema>
-           """ % (CONFIG_BASE,CONFIG_BASE))
-
+           """ % (CONFIG_BASE, CONFIG_BASE))
 
     def test_multi_extends_explicit_keytype_OK(self):
-        schema = self.load_schema_text("""\
-           <schema extends="%s/base-keytype1.xml %s/base-keytype2.xml"
-                   keytype="%s.uppercase">
-             <section name="One" type="type-1" />
-             <section name="Two" type="type-2" />
+        self.load_schema_text("""\
+           <schema extends='%s/base-keytype1.xml %s/base-keytype2.xml'
+                   keytype='%s.uppercase'>
+             <section name='One' type='type-1' />
+             <section name='Two' type='type-2' />
            </schema>
-           """ % (CONFIG_BASE,CONFIG_BASE,__name__))
-
+           """ % (CONFIG_BASE, CONFIG_BASE, __name__))
 
     def test_multi_extends_datatype_conflict(self):
        self.assertRaises(ZConfig.SchemaError,
-                          self.load_schema_text, """\
-           <schema extends="%s/base-datatype1.xml %s/base-datatype2.xml"/>
-           """ % (CONFIG_BASE,CONFIG_BASE))
+                         self.load_schema_text, """\
+           <schema extends='%s/base-datatype1.xml %s/base-datatype2.xml'/>
+           """ % (CONFIG_BASE, CONFIG_BASE))
 
     def test_multi_extends_keytype_conflict(self):
        self.assertRaises(ZConfig.SchemaError,
-                          self.load_schema_text, """\
-           <schema extends="%s/base-keytype1.xml %s/base-keytype2.xml"/>
-           """ % (CONFIG_BASE,CONFIG_BASE))
+                         self.load_schema_text, """\
+           <schema extends='%s/base-keytype1.xml %s/base-keytype2.xml'/>
+           """ % (CONFIG_BASE, CONFIG_BASE))
 
 def test_suite():
     return unittest.makeSuite(SchemaTestCase)




More information about the Zope3-Checkins mailing list