[Zope-CVS] CVS: Products/ZCTextIndex/tests - testZCTextIndex.py:1.31

Guido van Rossum guido@python.org
Mon, 20 May 2002 17:11:42 -0400


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

Modified Files:
	testZCTextIndex.py 
Log Message:
setUp(): assign the lexicon to self.lexicon directly rather than
creating it anonymously and then pulling it out of the zc_index
object.


=== Products/ZCTextIndex/tests/testZCTextIndex.py 1.30 => 1.31 ===
         extra.doc_attr = 'text'
         extra.lexicon_id = 'lexicon'
-        caller = LexiconHolder(Lexicon(Splitter(), CaseNormalizer(),
-                               StopWordRemover()))
+        self.lexicon = Lexicon(Splitter(), CaseNormalizer(), StopWordRemover())
+        caller = LexiconHolder(self.lexicon)
         self.zc_index = ZCTextIndex('name', extra, caller, self.IndexFactory)
         self.index = self.zc_index.index
-        self.lexicon = self.zc_index.lexicon
 
     def parserFailure(self, query):
         self.assertRaises(ParseError, self.zc_index.query, query)