[Zope-Checkins] CVS: Zope/lib/python/ZConfig/tests - test_schema.py:1.16

Fred L. Drake, Jr. fred@zope.com
Mon, 24 Mar 2003 09:53:55 -0500


Update of /cvs-repository/Zope/lib/python/ZConfig/tests
In directory cvs.zope.org:/tmp/cvs-serv19674

Modified Files:
	test_schema.py 
Log Message:
Remove tests for an undocumented mis-feature that isn't used.  The
implementation of the feature will also be removed.


=== Zope/lib/python/ZConfig/tests/test_schema.py 1.15 => 1.16 ===
--- Zope/lib/python/ZConfig/tests/test_schema.py:1.15	Mon Feb 24 12:21:55 2003
+++ Zope/lib/python/ZConfig/tests/test_schema.py	Mon Mar 24 09:53:55 2003
@@ -30,7 +30,6 @@
 class MySection:
     def __init__(self, value):
         self.conf = value
-        self.length = len(value)
 
 
 class SchemaTestCase(TestBase):
@@ -105,13 +104,9 @@
                                      </foo>
                                      """)
         self.assert_(isinstance(conf, MySection))
-        self.assertEqual(conf.length, 1)
-        o1 = conf.conf[0]
+        o1 = conf.conf.sect
         self.assert_(isinstance(o1, MySection))
-        self.assertEqual(o1.length, 1)
         self.assertEqual(o1.conf.sample, 42)
-        o2 = conf.conf.sect
-        self.assert_(o1 is o2)
 
     def test_empty_sections(self):
         schema = self.load_schema_text("""\
@@ -157,11 +152,8 @@
                                      """)
         eq = self.assertEqual
         eq(conf.sect.sect.sect.key, "type1-value")
-        eq(len(conf.sect.sect.sect), 1)
         eq(conf.sect.sect.key, "sect2-value")
-        eq(len(conf.sect.sect), 2)
         eq(conf.sect.key, "sect3-value")
-        eq(len(conf.sect), 2)
 
     def test_multivalued_keys(self):
         schema = self.load_schema_text("""\
@@ -492,7 +484,7 @@
         orig = conf.empty
         new = []
         conf.empty = new
-        self.assert_(conf[0] is new)
+        self.assert_(conf.empty is new)
 
     def test_simple_anonymous_section(self):
         schema = self.load_schema_text("""\