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

Commit

Permalink
Merge pull request #3441 from ngokevin/rmperms
Browse files Browse the repository at this point in the history
remove old content tool perms (bug 1220623)
  • Loading branch information
ngokevin committed Nov 12, 2015
2 parents 0cd2f55 + 6fc7cb7 commit 8272978
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 19 deletions.
2 changes: 0 additions & 2 deletions mkt/account/serializers.py
Expand Up @@ -129,8 +129,6 @@ def get_permissions(self, obj):
'website_submitter': allowed('Websites', 'Submit'),
'stats': allowed('Stats', 'View'),
'revenue_stats': allowed('RevenueStats', 'View'),
'content_tools_login': True,
'content_tools_addon_submit': True,
'content_tools_addon_review': allowed('ContentTools',
'AddonReview'),
}
Expand Down
18 changes: 1 addition & 17 deletions mkt/account/tests/test_views.py
Expand Up @@ -89,8 +89,7 @@ def test_no_permissions(self):
self.assertSetEqual(
['admin', 'developer', 'localizer', 'lookup', 'curator',
'reviewer', 'webpay', 'website_submitter', 'stats',
'revenue_stats', 'content_tools_login',
'content_tools_addon_submit', 'content_tools_addon_review'],
'revenue_stats', 'content_tools_addon_review'],
res.json['permissions'].keys()
)
ok_(not all(res.json['permissions'].values()))
Expand Down Expand Up @@ -434,12 +433,6 @@ def _test_login(self, http_request):

def test_login_new_user_success(self):
data = self._test_login()

# TODO: we want to remove these permissions entirely, but for now we
# just grant them to everybody.
del data['permissions']['content_tools_login']
del data['permissions']['content_tools_addon_submit']

ok_(not any(data['permissions'].values()))

def test_login_existing_user_success(self):
Expand All @@ -462,8 +455,6 @@ def test_login_existing_user_success(self):
'website_submitter': False,
'stats': False,
'revenue_stats': False,
'content_tools_login': True,
'content_tools_addon_submit': True,
'content_tools_addon_review': False})
eq_(data['apps']['installed'], [])
eq_(data['apps']['purchased'], [])
Expand Down Expand Up @@ -549,11 +540,6 @@ def test_login_new_user_success(self):
eq_(UserProfile.objects.count(), 0)
data = self._test_login()

# TODO: we want to remove these permissions entirely, but for now we
# just grant them to everybody.
del data['permissions']['content_tools_login']
del data['permissions']['content_tools_addon_submit']

ok_(not any(data['permissions'].values()))
profile = UserProfile.objects.get()
eq_(profile.email, 'cvan@mozilla.com')
Expand Down Expand Up @@ -582,8 +568,6 @@ def test_login_existing_user_uid_success(self):
'website_submitter': False,
'stats': False,
'revenue_stats': False,
'content_tools_login': True,
'content_tools_addon_submit': True,
'content_tools_addon_review': False})
eq_(data['apps']['installed'], [])
eq_(data['apps']['purchased'], [])
Expand Down

0 comments on commit 8272978

Please sign in to comment.