opends/tests/staf-tests/functional-tests/testcases/schema/rfc/schema_rfc.xml
@@ -74,22 +74,6 @@ <!-- Specific to rfc tests --> <script> __baseDN='o=rfc tests, dc=example,%s' % server.suffix def parse_stax_result(result): if result.__class__ is org.python.core.PyList: _unwrapResult=result[1][0] try: _functionString=_unwrapResult[1] except AttributeError: _functionString='Unable to parse result.' elif result.__class__ is org.python.core.PyString: _functionString=STAXResult else: _functionString='Unable to parse result.' return _functionString </script> <!-- List of Test Cases --> opends/tests/staf-tests/functional-tests/testcases/schema/schema.xml
@@ -77,6 +77,22 @@ server.dn = DIRECTORY_INSTANCE_DN server.password = DIRECTORY_INSTANCE_PSWD server.suffix = DIRECTORY_INSTANCE_SFX def parse_stax_result(result): if result.__class__ is org.python.core.PyList: _unwrapResult=result[1][0] try: _functionString=_unwrapResult[1] except AttributeError: _functionString='Unable to parse result.' elif result.__class__ is org.python.core.PyString: _functionString=STAXResult else: _functionString='Unable to parse result.' return _functionString </script> <!-- Run the test suites --> opends/tests/staf-tests/functional-tests/testcases/schema/solaris/schema_solaris.xml
@@ -71,6 +71,11 @@ <!-- Test Suite Setup --> <call function="'%s_setup' % __group"/> <!-- Specific to solaris schema tests --> <script> __baseDN='o=Solaris schema tests, dc=example,%s' % server.suffix </script> <!-- List of Test Cases --> <script> testsList=[] @@ -106,7 +111,7 @@ <finally> <sequence> <!-- Test Suite Cleanup --> <message>'Finally: Example Cleanup.'</message> <message>'Finally: Solaris Schema Cleanup.'</message> <call function="'%s_cleanup' % __group"/> <call function="'testSuite_Postamble'"/> </sequence> opends/tests/staf-tests/functional-tests/testcases/schema/solaris/schema_solaris_tests.xml
@@ -67,12 +67,47 @@ } </call> <!-- TODO: Need to verify that the added entry is working as specified --> <call function="'runFunction'"> { 'functionName' : 'ldapSearchWithScript' , 'functionMessage' : 'Search for the entry just added and return rfc822mailMember.' , 'functionException' : 'LDAP.SearchException' , 'functionArguments' : { 'dsInstanceHost' : server.host , 'dsInstancePort' : server.port , 'dsInstanceDn' : server.dn , 'dsInstancePswd' : server.password , 'dsBaseDN' : __baseDN , 'dsFilter' : 'objectclass=*' , 'dsAttributes' : 'rfc822mailMember' } } </call> <script> _functionString=parse_stax_result(STAXResult) </script> <call function="'runFunction'"> { 'functionName' : 'checktestString' , 'functionMessage' : 'Check that the rfc822mailMember attribute is returned.' , 'functionException' : 'Utils.CheckStringException' , 'functionArguments' : { 'expectedString' : 'rfc822mailMember: nisMailAlias@sun.com' , 'returnString' : _functionString } } </call> </sequence> <catch exception="'STAXException.LDAP.ModifyException'" typevar="eType" var="eInfo"> <catch exception="'STAXException.LDAP.AddException'" typevar="eType" var="eInfo"> <message log="1" level="'fatal'"> '%s: LDAPModify failed. eInfo(%s)' % (eType,eInfo) '%s: LDAPAdd failed. eInfo(%s)' % (eType,eInfo) </message> </catch> <catch exception="'STAXException.LDAP.SearchException'" typevar="eType" var="eInfo"> <message log="1" level="'fatal'"> '%s: LDAPSearch failed. eInfo(%s)' % (eType,eInfo) </message> </catch> <catch exception="'STAXException.Utils.CheckStringException'" typevar="eType" var="eInfo"> <message log="1" level="'fatal'"> '%s: UtilsCheck failed. eInfo(%s)' % (eType,eInfo) </message> </catch> <finally> @@ -121,12 +156,47 @@ } </call> <!-- TODO: Need to verify that the added entry is working as specified --> <call function="'runFunction'"> { 'functionName' : 'ldapSearchWithScript' , 'functionMessage' : 'Search for the entry just added and return nisDomain.' , 'functionException' : 'LDAP.SearchException' , 'functionArguments' : { 'dsInstanceHost' : server.host , 'dsInstancePort' : server.port , 'dsInstanceDn' : server.dn , 'dsInstancePswd' : server.password , 'dsBaseDN' : __baseDN , 'dsFilter' : 'objectclass=*' , 'dsAttributes' : 'nisDomain' } } </call> <script> _functionString=parse_stax_result(STAXResult) </script> <call function="'runFunction'"> { 'functionName' : 'checktestString' , 'functionMessage' : 'Check that the nisDomain attribute is returned.' , 'functionException' : 'Utils.CheckStringException' , 'functionArguments' : { 'expectedString' : 'nisDomain: rfc4876' , 'returnString' : _functionString } } </call> </sequence> <catch exception="'STAXException.LDAP.ModifyException'" typevar="eType" var="eInfo"> <catch exception="'STAXException.LDAP.AddException'" typevar="eType" var="eInfo"> <message log="1" level="'fatal'"> '%s: LDAPModify failed. eInfo(%s)' % (eType,eInfo) '%s: LDAPAdd failed. eInfo(%s)' % (eType,eInfo) </message> </catch> <catch exception="'STAXException.LDAP.SearchException'" typevar="eType" var="eInfo"> <message log="1" level="'fatal'"> '%s: LDAPSearch failed. eInfo(%s)' % (eType,eInfo) </message> </catch> <catch exception="'STAXException.Utils.CheckStringException'" typevar="eType" var="eInfo"> <message log="1" level="'fatal'"> '%s: UtilsCheck failed. eInfo(%s)' % (eType,eInfo) </message> </catch> <finally> opends/tests/staf-tests/functional-tests/testcases/tasks/cleanup.xml
@@ -32,6 +32,17 @@ <sequence> <block name="'cleanup'"> <sequence> <script> CurrentTestPath['suite']='cleanup_tasks' </script> <call function="'testSuite_Preamble'" /> <testcase name="getTestCaseName('Cleanup tasks')"> <sequence> <call function="'testCase_Preamble'"/> <block name="'Block DS Process Stop'"> <!--- Stop DS --> <sequence> @@ -67,6 +78,10 @@ </sequence> <!-- End Block Remove DS Topology--> </block> <call function="'testCase_Postamble'"/> </sequence> </testcase> <call function="'testSuite_Postamble'"/> </sequence> </block> </sequence> opends/tests/staf-tests/functional-tests/testcases/tasks/export-ldif.xml
@@ -74,6 +74,27 @@ 'startTask' : '0', 'backEnd' : DIRECTORY_INSTANCE_BE} </call> <!-- manage-tasks --> <call function="'manage-tasks'"> { 'location' : STAF_REMOTE_HOSTNAME , 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST, 'dsInstanceDn' : DIRECTORY_INSTANCE_DN, 'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD, 'dsQuiet' : ' ' } </call> <script> returnString = STAXResult[0][1] </script> <call function="'searchStringForSubstring'"> { 'returnString' : returnString, 'testString' : 'Completed successfully', 'expectedResult' : '1' } </call> <message>'--- Check log files export_asynchronous ---'</message> <call function="'listFolder'"> { 'location' : '%s' % (STAF_REMOTE_HOSTNAME), @@ -138,7 +159,7 @@ <call function="'searchStringForSubstring'"> { 'returnString' : returnString, 'testString' : 'Export', 'testString' : 'Completed successfully', 'expectedResult' : '1' } </call> @@ -190,6 +211,26 @@ 'backEnd' : DIRECTORY_INSTANCE_BE} </call> <!-- manage-tasks --> <call function="'manage-tasks'"> { 'location' : STAF_REMOTE_HOSTNAME , 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST, 'dsInstanceDn' : DIRECTORY_INSTANCE_DN, 'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD, 'dsQuiet' : ' ' } </call> <script> returnString = STAXResult[0][1] </script> <call function="'searchStringForSubstring'"> { 'returnString' : returnString, 'testString' : 'Completed successfully', 'expectedResult' : '1' } </call> <message>'--- Check log files export_asynchronous ---'</message> <call function="'listFolder'"> { 'location' : '%s' % (STAF_REMOTE_HOSTNAME), opends/tests/staf-tests/functional-tests/testcases/tasks/setup.xml
@@ -32,6 +32,17 @@ <sequence> <block name="'setup'"> <sequence> <script> CurrentTestPath['suite']='setup_tasks' </script> <call function="'testSuite_Preamble'" /> <testcase name="getTestCaseName('Setup tasks')"> <sequence> <call function="'testCase_Preamble'"/> <block name="'Block Create DS Topology'"> <!-- Create the topology necessary to the test group/suite --> <sequence> @@ -81,7 +92,12 @@ </sequence> <!--- End Block DS Process Active --> </block> <call function="'testSuite_Postamble'"/> </sequence> </testcase> </sequence> </block> </sequence>