diff --git a/test/test_indexer.py b/test/test_indexer.py
index 1b4d9098bf5d46d295183a209d1fd3289808d40d..5d8a395efa2d774e0ad710c2397c50afda1972b6 100644 (file)
--- a/test/test_indexer.py
+++ b/test/test_indexer.py
[('test', '1', 'a'),
('test', '2', 'a')])
+ def test_wordsplitting(self):
+ """Test if word splitting works."""
+ self.dex.add_text(('test', '1', 'a'), 'aaaa-aaa bbbb*bbb')
+ self.dex.add_text(('test', '2', 'a'), 'aaaA-aaa BBBB*BBB')
+ for k in 'aaaa', 'aaa', 'bbbb', 'bbb':
+ self.assertSeqEqual(self.dex.find([k]),
+ [('test', '1', 'a'), ('test', '2', 'a')])
+
def tearDown(self):
shutil.rmtree('test-index')