Example #1
0
 def test_remove_non_word_characters(self):
   header = EMBLHeader()
   test_cases = [
     ('foo', 'foo'),
     ('#foo', 'foo'),
     ('#fo!o', 'foo'),
     ('fo#o', 'foo'),
     ('foo##', 'foo'),
     ("*!#foo", 'foo')
   ]
   for test_string, expected_result in test_cases:
     self.assertEqual(header.remove_non_word_characters(test_string), expected_result)