From 1c78274c41f447aa9f06f0f8ec29887def2f4b11 Mon Sep 17 00:00:00 2001
From: mkeyes <mkeyes@localhost>
Date: Wed, 30 May 2007 21:22:41 +0000
Subject: [PATCH] Added tests for some additional options for the get effective rights support.
---
opendj-sdk/opends/tests/functional-tests/testcases/aci/aci_effective_rights.xml | 67 +++++++++++++++++++++++++++++++++
1 files changed, 67 insertions(+), 0 deletions(-)
diff --git a/opendj-sdk/opends/tests/functional-tests/testcases/aci/aci_effective_rights.xml b/opendj-sdk/opends/tests/functional-tests/testcases/aci/aci_effective_rights.xml
index eea1469..b76b17a 100755
--- a/opendj-sdk/opends/tests/functional-tests/testcases/aci/aci_effective_rights.xml
+++ b/opendj-sdk/opends/tests/functional-tests/testcases/aci/aci_effective_rights.xml
@@ -453,6 +453,8 @@
#@TestPurpose Test effective rights with search-read permission
#@TestPreamble Admin adds an aci.
#@TestStep Client searches for effective rights in an entry in the targeted branch dn.
+ #@TestStep Client searches for effective rights in an entry in the targeted branch dn as shown in doc example.
+ #@TestStep Client searches for effective rights in an entry in the targeted branch dn with -J option.
#@TestStep Client searches for effective rights in an entry in the non-targeted branch dn.
#@TestStep Remove aci.
#@TestStep Client searches for effective rights in an entry with the previously targeted branch dn.
@@ -535,6 +537,71 @@
</if>
<message>
+ 'ACI: Effective Rights: Basic - search-read as doc example, user searching targeted entry'
+ </message>
+
+ <call function="'SearchObject'">
+ { 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
+ 'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
+ 'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
+ 'dsInstancePswd' : 'ACIRules' ,
+ 'dsBaseDN' : 'uid=scarter,ou=People,ou=aci branch,o=ACI Tests,dc=example,dc=com' ,
+ 'dsFilter' : 'objectclass=*' ,
+ 'attributes' : 'aclRights "*"' ,
+ 'extraParams' : '-T -g "dn: uid=auser,ou=people,o=ACI Tests,dc=example,dc=com"' }
+ </call>
+
+ <script>
+ returnString = STAXResult[0][1]
+ </script>
+
+ <call function="'searchStringForSubstring'">
+ { 'returnString' : returnString ,
+ 'testString' : 'entryLevel: add:0,delete:0,read:1,write:0,proxy:0' }
+ </call>
+
+ <if expr="returnCode != '1'">
+ <tcstatus result="'fail'"/>
+ </if>
+
+ <call function="'searchStringForSubstring'">
+ { 'returnString' : returnString ,
+ 'testString' : 'attributeLevel;uid: search:1,read:1,compare:0,write:0,selfwrite_add:0,selfwrite_delete:0,proxy:0' }
+ </call>
+
+ <if expr="returnCode != '1'">
+ <tcstatus result="'fail'"/>
+ </if>
+
+ <message>
+ 'ACI: Effective Rights: Basic - search-read with -J option, user searching targeted entry'
+ </message>
+
+ <call function="'SearchObject'">
+ { 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
+ 'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
+ 'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
+ 'dsInstancePswd' : 'ACIRules' ,
+ 'dsBaseDN' : 'uid=scarter,ou=People,ou=aci branch,o=ACI Tests,dc=example,dc=com' ,
+ 'dsFilter' : 'objectclass=*' ,
+ 'attributes' : 'aclRights' ,
+ 'extraParams' : '-T -J effectiveRights' }
+ </call>
+
+ <script>
+ returnString = STAXResult[0][1]
+ </script>
+
+ <call function="'searchStringForSubstring'">
+ { 'returnString' : returnString ,
+ 'testString' : 'entryLevel: add:0,delete:0,read:1,write:0,proxy:0' }
+ </call>
+
+ <if expr="returnCode != '1'">
+ <tcstatus result="'fail'"/>
+ </if>
+
+ <message>
'ACI: Effective Rights: Basic - search-read, user searching non-targeted entry'
</message>
--
Gitblit v1.10.0