class WikiIndexerSilenceOnExceptionTestCase(BaseBloodhoundSearchTest): def setUp(self): super(WikiIndexerSilenceOnExceptionTestCase, self).setUp() self.env.config.set('bhsearch', 'silence_on_error', "True") self.wiki_indexer = WikiIndexer(self.env) def tearDown(self): pass def test_does_not_raise_exception_on_add(self): self.wiki_indexer.wiki_page_added(None) def test_raise_exception_if_configured(self): self.env.config.set('bhsearch', 'silence_on_error', "False") self.assertRaises(Exception, self.wiki_indexer.wiki_page_added, None)
class WikiIndexerSilenceOnExceptionTestCase(BaseBloodhoundSearchTest): def setUp(self): super(WikiIndexerSilenceOnExceptionTestCase, self).setUp() self.env.config.set('bhsearch', 'silence_on_error', "True") self.wiki_indexer = WikiIndexer(self.env) def tearDown(self): pass def test_does_not_raise_exception_on_add(self): self.wiki_indexer.wiki_page_added(None) def test_raise_exception_if_configured(self): self.env.config.set('bhsearch', 'silence_on_error', "False") self.assertRaises( Exception, self.wiki_indexer.wiki_page_added, None)
def setUp(self): super(WikiIndexerSilenceOnExceptionTestCase, self).setUp() self.env.config.set('bhsearch', 'silence_on_error', "True") self.wiki_indexer = WikiIndexer(self.env)