Skip to content
Permalink
Newer
Older
100644 37 lines (31 sloc) 1.89 KB
1
# https://tools.ietf.org/html/draft-young-md-query-saml-09
2
3
*** Settings ***
4
Library Collections
5
Library Process
6
Library XML
7
Resource MDQ.robot
8
Variables variables.py
9
10
*** Test Cases ***
11
2.2.1 Unique Identifier
Oct 27, 2018
12
${resp}= Get Entity baseUrl=${BASE_URL} identifier=${ENTITY_ID_ENCODED}
13
Should Be Equal As Strings ${resp.status_code} 200 msg=MUST respond to a unique identifier
14
15
2.2.2 Transformed Identifier
Oct 27, 2018
16
${resp}= Get Entity baseUrl=${BASE_URL} identifier={sha1}${ENTITY_ID_SHA1}
17
Should Be Equal As Strings ${resp.status_code} 200 msg=MUST respond to SHA-1 transformed identifier
18
19
3.1.1 No Entity Descriptors Returned
Oct 27, 2018
20
${resp}= Get Entity baseUrl=${BASE_URL} identifier=foo
21
Should Be Equal As Strings ${resp.status_code} 404 msg=MUST return HTTP status code 404
22
23
3.1.2 One Entity Descriptor Returned
Oct 27, 2018
24
${resp}= Get Entity baseUrl=${BASE_URL} identifier=${ENTITY_ID_ENCODED}
25
${root}= Parse XML ${resp.text}
26
Should Be Equal ${root.tag} EntityDescriptor msg=MUST use EntityDescriptor document element
27
Should Not Contain ${resp.text} EntitiesDescriptor msg=MUST NOT use EntitiesDescriptor element
28
Dictionary Should Contain Item ${resp.headers} content-type application/samlmetadata+xml msg=MUST return Content-Type=application/samlmetadata+xml header
29
30
3.1.3 More Than One Entity Descriptor Returned
31
[Tags] aggregate
Oct 27, 2018
32
${resp}= Get All Entities baseUrl=${BASE_URL}
33
${root}= Parse XML ${resp.text}
34
Should Be Equal ${root.tag} EntitiesDescriptor msg=MUST use EntitiesDescriptor document element
35
${count}= Get Element Count ${root} .//EntitiesDescriptor
36
Should Be Equal As Integers ${count} 0 msg=MUST NOT contain nested EntitiesDescriptor elements
37
Dictionary Should Contain Item ${resp.headers} content-type application/samlmetadata+xml msg=MUST return Content-Type=application/samlmetadata+xml header
You can’t perform that action at this time.