Skip to content
This repository has been archived by the owner on Mar 10, 2020. It is now read-only.

Commit

Permalink
Flake8 fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Rudi Giesler committed May 19, 2016
1 parent 7fea667 commit 7d529a5
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions authapi/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,8 @@ def test_user_summary_serializer(self):

class TeamTests(AuthAPITestCase):
def test_get_team_list(self):
'''A GET request on the teams endpoint should return a list of teams.'''
'''A GET request on the teams endpoint should return a list of
teams.'''
organization = SeedOrganization.objects.create()
team1 = SeedTeam.objects.create(organization=organization)
team2 = SeedTeam.objects.create(organization=organization)
Expand Down Expand Up @@ -190,13 +191,15 @@ def test_create_team_no_required_fields(self):
response.data, {'organization': ['This field is required.']})

def test_update_team(self):
'''A PUT request to a team's endpoint should update an existing team.'''
'''A PUT request to a team's endpoint should update an existing
team.'''
organization1 = SeedOrganization.objects.create()
organization2 = SeedOrganization.objects.create()
team = SeedTeam.objects.create(organization=organization1)
url = reverse('seedteam-detail', args=[team.id])

response = self.client.put(url, data={'organization': organization2.id})
response = self.client.put(
url, data={'organization': organization2.id})
self.assertEqual(response.status_code, status.HTTP_200_OK)
team.refresh_from_db()
self.assertEqual(team.organization, organization2)
Expand Down Expand Up @@ -293,7 +296,8 @@ def test_get_organization(self):
self.assertEqual(response.data, expected.data)

def test_serializer(self):
'''The organization serializer should return the correct information.'''
'''The organization serializer should return the correct
information.'''
organization = SeedOrganization.objects.create()
user = User.objects.create_user('foo@bar.org')
organization.users.add(user)
Expand Down

0 comments on commit 7d529a5

Please sign in to comment.