In the none_test.py
file the “test_arrange_reservations_1” test is skipping “Walter”, who should get assigned to seat 1.
def test_arrange_reservations_1(self):
guests = ['Walter', 'Frank', 'Jenny', 'Carol', 'Alice', 'George']
expected_results = {1: 'Frank', 2: 'Jenny', 3: 'Carol', 4: 'Alice', 5: 'George',
6: None, 7: None, 8: None, 9: None, 10: None,
11: None, 12: None, 13: None, 14: None, 15: None,
16: None, 17: None, 18: None, 19: None, 20: None, 21: None, 22: None}
failure_msg = 'The reservation dict is incorrect'
self.assertDictEqual(arrange_reservations(guests), expected_results, msg=failure_msg)
The examplar implementation passes the test because it chooses to skip the first name, but this doesn’t match with the copy on the website description, which implies that all names should be assigned:
>>> arrange_reservations(guests=["Walter", "Frank", "Jenny", "Carol", "Alice", "George"])
...
{1: 'Walter', 2: 'Frank', 3: 'Jenny', 4: 'Carol', 5: 'Alice', 6: 'George', 7: None, 8: None, 9: None, 10: None, 11: None, 12: None, 13: None, 14: None, 15: None, 16: None, 17: None, 18: None, 19: None, 20: None, 21: None, 22: None}