summaryrefslogtreecommitdiff
path: root/tests/test_62_vo.py
diff options
context:
space:
mode:
authorRoland Hedberg <roland.hedberg@adm.umu.se>2012-12-19 13:08:02 +0100
committerRoland Hedberg <roland.hedberg@adm.umu.se>2012-12-19 13:08:02 +0100
commit50459d616f4f5ec52f94d7a0181e4445ca867d1e (patch)
treeaf605edbfb88dfcbd017782f7032968bae6fa95f /tests/test_62_vo.py
parentf265c3b421b87c951b27306284b1b1725c39c7ab (diff)
downloadpysaml2-50459d616f4f5ec52f94d7a0181e4445ca867d1e.tar.gz
Complete rewrite of the metadata handling package.
Switched from using httplib2 to requests.
Diffstat (limited to 'tests/test_62_vo.py')
-rw-r--r--tests/test_62_vo.py13
1 files changed, 5 insertions, 8 deletions
diff --git a/tests/test_62_vo.py b/tests/test_62_vo.py
index 6c8c3986..0839241f 100644
--- a/tests/test_62_vo.py
+++ b/tests/test_62_vo.py
@@ -1,6 +1,5 @@
__author__ = 'rolandh'
-from saml2.virtual_org import VirtualOrg
from saml2 import config
from saml2.client import Saml2Client
from saml2.time_util import str_to_time, in_a_while
@@ -12,7 +11,7 @@ def add_derek_info(sp):
not_on_or_after = str_to_time(in_a_while(days=1))
session_info = SESSION_INFO_PATTERN.copy()
session_info["ava"] = {"givenName":["Derek"], "umuselin":["deje0001"]}
- session_info["issuer"] = "https://toylan3.umdc.umu.se/shibboleth"
+ session_info["issuer"] = "urn:mace:example.com:saml:idp"
session_info["name_id"] = "abcdefgh"
session_info["not_on_or_after"] = not_on_or_after
# subject_id, entity_id, info, timestamp
@@ -31,14 +30,13 @@ class TestVirtualOrg():
def test_mta(self):
aas = self.vo.members_to_ask("abcdefgh")
print aas
- assert len(aas) == 2
+ assert len(aas) == 1
assert 'urn:mace:example.com:saml:aa' in aas
- assert 'urn:mace:example.com:saml:idp' in aas
def test_unknown_subject(self):
aas = self.vo.members_to_ask("01234567")
print aas
- assert len(aas) == 0
+ assert len(aas) == 2
def test_id(self):
id = self.vo.get_common_identifier("abcdefgh")
@@ -60,14 +58,13 @@ class TestVirtualOrg_2():
def test_mta(self):
aas = self.sp.vorg.members_to_ask("abcdefgh")
print aas
- assert len(aas) == 2
+ assert len(aas) == 1
assert 'urn:mace:example.com:saml:aa' in aas
- assert 'urn:mace:example.com:saml:idp' in aas
def test_unknown_subject(self):
aas = self.sp.vorg.members_to_ask("01234567")
print aas
- assert len(aas) == 0
+ assert len(aas) == 2
def test_id(self):
id = self.sp.vorg.get_common_identifier("abcdefgh")