Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
django-openid-auth
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
django-openid-auth
Commits
5fca3015
Commit
5fca3015
authored
May 02, 2013
by
Ricardo Kirkner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
added test as requested per review
parent
06303704
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
0 deletions
+12
-0
django_openid_auth/tests/test_auth.py
+12
-0
No files found.
django_openid_auth/tests/test_auth.py
View file @
5fca3015
...
@@ -260,6 +260,18 @@ class OpenIDBackendTests(TestCase):
...
@@ -260,6 +260,18 @@ class OpenIDBackendTests(TestCase):
self
.
assertIsNotNone
(
user
)
self
.
assertIsNotNone
(
user
)
def
test_authenticate_when_member_of_at_least_one_team
(
self
):
settings
.
OPENID_LAUNCHPAD_TEAMS_MAPPING_AUTO
=
True
settings
.
OPENID_LAUNCHPAD_TEAMS_REQUIRED
=
[
'team1'
,
'team2'
]
Group
.
objects
.
create
(
name
=
'team1'
)
response
=
self
.
make_openid_response
(
sreg_args
=
dict
(
nickname
=
'someuser'
),
teams_args
=
dict
(
is_member
=
'foo,team1'
))
user
=
self
.
backend
.
authenticate
(
openid_response
=
response
)
self
.
assertIsNotNone
(
user
)
def
suite
():
def
suite
():
return
unittest
.
TestLoader
()
.
loadTestsFromName
(
__name__
)
return
unittest
.
TestLoader
()
.
loadTestsFromName
(
__name__
)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment