Skip to content
This repository has been archived by the owner on May 13, 2020. It is now read-only.

Commit

Permalink
setUp(): assign the lexicon to self.lexicon directly rather than
Browse files Browse the repository at this point in the history
creating it anonymously and then pulling it out of the zc_index
object.
  • Loading branch information
gvanrossum committed May 20, 2002
1 parent 1a725ee commit 05bc9db
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions tests/testZCTextIndex.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,11 +93,10 @@ def setUp(self):
extra = Extra()
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)
Expand Down

0 comments on commit 05bc9db

Please sign in to comment.