def test_final_status_many(self, status1, status2): """ Final status of a list is the latest. """ target = status1 if status2['updated_at'] > status1['updated_at']: target = status2 self.assertEqual(target, merge_pr.final_status([status2, status1]))
def test_final_status_one(self, status): """ Final status of one status is itself. """ self.assertEqual(status, merge_pr.final_status([status]))