def test_duplicates(self): word = "abc" x = model.word_with_endings(word, {"x", "x", "y"}) self.failUnlessEqual(x, {"abcx", "abcy"})
def test_empty_both(self): x = model.word_with_endings(set(), set()) self.failUnlessEqual(x, set())
def test_empty_wordlist(self): x = model.word_with_endings(set(), {"a", "b"}) self.failUnlessEqual(x, set())
def test_empty_endings(self): x = model.word_with_endings("x", set()) self.failUnlessEqual(x, {"x"})
def test_connecting(self): x = model.word_with_endings("abc", {'', 'b', 'aBc'}) self.failUnlessEqual(x, {'abc', 'abcb', 'abcaBc'})