It was a dramatic final day of the season for Manchester City.