2 from engines
import Engine
, StringLoader
3 from plaintypes
import *
5 class TestEngines(unittest
.TestCase
):
7 def test_loading_non_existing_fixture(self
):
9 engine
.loader
= StringLoader('import doesntexist\n')
11 engine
.load_fixture('SomeQuery')
12 except ImportError, inst
:
15 self
.assertEqual(str(inst
), 'No module named doesntexist')
17 def test_action_fixture(self
):
19 engine
.load_fixture('RowFixture')
20 engine
.load_fixture('ColumnFixture')
21 engine
.load_fixture('fit.ActionFixture')
23 def test_input_table(self
):
26 engine
.loader
= StringLoader('import doesntexist\n')
35 table
= Table(wiki_table_to_plain(wiki
))
36 engine
.process(table
, throw
=False)