BUG 8382: domain create should reject domainid 60/56560/5
authorJamo Luhrsen <jluhrsen@redhat.com>
Thu, 4 May 2017 21:32:32 +0000 (14:32 -0700)
committerJamo Luhrsen <jluhrsen@redhat.com>
Sat, 13 May 2017 16:39:15 +0000 (16:39 +0000)
Change-Id: Ib004d8c1a6a193392d358d456fd25d242abb0e62
Signed-off-by: Jamo Luhrsen <jluhrsen@redhat.com>
csit/suites/aaa/idmlite/010_CRUD_Rest_CommandsTests.robot

index 48a76ba061989c45f70459bd0025ed80917ee2e2..37958c5b2b8a62731fcb77574f50c4aad95b08a4 100644 (file)
@@ -30,6 +30,13 @@ ${URI}            http://${ODL_SYSTEM_IP}:${RESTCONFPORT}
 @{cleanup_grant_list}
 
 *** Test Cases ***
+Domain Create Rejects Request With Domain ID
+    [Documentation]    Bug https://bugs.opendaylight.org/show_bug.cgi?id=8382 will make this test case fail if it
+    ...    is seen. The domain create API should not accept the domainid in the request
+    ${data}=    Set Variable    {"domainid":"foo","description":"do not accept","name":\"reject-domain-id\","enabled":"true"}
+    ${resp}    RequestsLibrary.Post Request    httpbin    auth/v1/domains    headers=${HEADERS}    data=${data}
+    Should Be Equal As Strings    ${resp.status_code}    400
+
 Test Post New Domain
     [Documentation]    Create a domain using REST POST command.
     # create a temp name, set it to domainName