[Zope-CVS] CVS: Products/ZCTextIndex/tests - testIndex.py:1.7 testZCTextIndex.py:1.14

Tim Peters tim.one@comcast.net
Thu, 16 May 2002 23:07:50 -0400


Update of /cvs-repository/Products/ZCTextIndex/tests
In directory cvs.zope.org:/tmp/cvs-serv14021/tests

Modified Files:
	testIndex.py testZCTextIndex.py 
Log Message:
_get_undoinfo:  Got rid of this everywhere.  It was just a synonym for
get_words, and in calling contexts nothing but a list of wids could
possibly make sense.


=== Products/ZCTextIndex/tests/testIndex.py 1.6 => 1.7 ===
         self.assertEqual(len(self.index._wordinfo), 5)
         self.assertEqual(len(self.index._docwords), 1)
-        self.assertEqual(len(self.index._get_undoinfo(DOCID)), 5)
+        self.assertEqual(len(self.index.get_words(DOCID)), 5)
         for map in self.index._wordinfo.values():
             self.assertEqual(len(map), 1)
             self.assert_(map.has_key(DOCID))
@@ -70,7 +70,7 @@
         self.assertEqual(self.num_docs_known(), 2)
         self.assertEqual(len(self.index._wordinfo), 8)
         self.assertEqual(len(self.index._docwords), 2)
-        self.assertEqual(len(self.index._get_undoinfo(DOCID)), 4)
+        self.assertEqual(len(self.index.get_words(DOCID)), 4)
         wids = self.lexicon.termToWordIds("document")
         self.assertEqual(len(wids), 1)
         document_wid = wids[0]
@@ -91,7 +91,7 @@
         self.check_docid_known(DOCID)
         self.assertEqual(len(self.index._wordinfo), 4)
         self.assertEqual(len(self.index._docwords), 1)
-        self.assertEqual(len(self.index._get_undoinfo(DOCID)), 4)
+        self.assertEqual(len(self.index.get_words(DOCID)), 4)
         for map in self.index._wordinfo.values():
             self.assertEqual(len(map), 1)
             self.assert_(map.has_key(DOCID))
@@ -102,7 +102,7 @@
         self.check_docid_known(DOCID)
         self.assertEqual(len(self.index._wordinfo), 5)
         self.assertEqual(len(self.index._docwords), 1)
-        self.assertEqual(len(self.index._get_undoinfo(DOCID)), 7)
+        self.assertEqual(len(self.index.get_words(DOCID)), 7)
         wids = self.lexicon.termToWordIds("repeat")
         self.assertEqual(len(wids), 1)
         repititive_wid = wids[0]


=== Products/ZCTextIndex/tests/testZCTextIndex.py 1.13 => 1.14 ===
                 wids = self.lexicon.termToWordIds(word)
                 self.assertEqual(wids, [])
-        self.assertEqual(len(self.index._get_undoinfo(1)), 1)
+        self.assertEqual(len(self.index.get_words(1)), 1)
 
     def testDocUpdate(self):
         docid = 1