def test_letter_storage_get_id_by_letter_none(self): """ get_id_by_letter none """ letter_storage = LetterStorage() letter_storage.storage = {'w': 1} expected = -1 actual = letter_storage.get_id_by_letter(None) self.assertEqual(expected, actual)
def test_letter_storage_get_id_by_letter_not_str(self): """ id is not str get_id_by_letter """ letter_storage = LetterStorage() letter_storage.storage = {'w': 1} expected = -1 actual = letter_storage.get_id_by_letter(123) self.assertEqual(expected, actual)
def test_letter_storage_get_id_by_letter_ideal(self): """ ideal case for get_id_by_letter """ letter_storage = LetterStorage() letter_storage.storage = {'w': 1} expected = 1 actual = letter_storage.get_id_by_letter('w') self.assertEqual(expected, actual)