~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/services/features/tests/test_webapp.py

  • Committer: Michael-Doyle Hudson
  • Date: 2011-09-21 21:12:02 UTC
  • mto: This revision was merged to the branch mainline in revision 14068.
  • Revision ID: michael.hudson@linaro.org-20110921211202-xk3mjmjqrufx10f5
revert the reversion of the xmlrpc feature flag endpoint

Show diffs side-by-side

added added

removed removed

Lines of Context:
86
86
 
87
87
    def test_team_scope_outside_team(self):
88
88
        request = LaunchpadTestRequest()
 
89
        self.factory.loginAsAnyone(request)
89
90
        scopes = webapp.ScopesFromRequest(request)
90
 
        self.factory.loginAsAnyone()
91
91
        self.assertFalse(scopes.lookup('team:nonexistent'))
92
92
 
93
93
    def test_team_scope_in_team(self):
94
94
        request = LaunchpadTestRequest()
95
 
        scopes = webapp.ScopesFromRequest(request)
96
95
        member = self.factory.makePerson()
97
96
        team = self.factory.makeTeam(members=[member])
98
 
        login_as(member)
 
97
        login_as(member, request)
 
98
        scopes = webapp.ScopesFromRequest(request)
99
99
        self.assertTrue(scopes.lookup('team:%s' % team.name))