From f73b655466092169abac34833fb628fce1fcdebe Mon Sep 17 00:00:00 2001
From: jcduff <jcduff@localhost>
Date: Thu, 23 Oct 2008 14:04:24 +0000
Subject: [PATCH] The commit will bring the following features :     - An updated version of the underlying database. BDB JE 3.3 is now used.     - Attribute API refactoring providing a better abstraction and offering improved performances.     - A new GUI called the Control-Panel to replace the Status-Panel: the specifications for this       GUI are available on OpenDS Wiki and contains a link to a mockup.        See <https://www.opends.org/wiki/page/ControlPanelUISpecification>.     - Some changes in the replication protocol to implement "Assured Replication Mode". The        specifications are on OpenDS Wiki at <https://www.opends.org/wiki/page/AssuredMode> and section 7       described some of the replication changes required to support this. Assured Replication is not finished,       but the main replication protocol changes to support it are done. As explained by Gilles on an email on       the Dev mailing list (http://markmail.org/message/46rgo3meq3vriy4a), with these changes the newer versions       of OpenDS may not be able to replicate with OpenDS 1.0 instances.     - Support for Service Tags on the platforms where the functionality is available and enabled. Specifications       are published at <https://www.opends.org/wiki/page/OpenDSServiceTagEnabled>. For more information on       Service Tags see <http://wikis.sun.com/display/ServiceTag/Sun+Service+Tag+FAQ>.     - The Admin Connector service. In order to provide agentry of the OpenDS server at any time, a new service       has been added, dedicated to the administration, configuration and monitoring of the server.       An overview of the Admin Connector service and it's use is available on the       OpenDS wiki <https://www.opends.org/wiki/page/ManagingAdministrationTrafficToTheServer>     - Updates to the various command line tools to support the Admin Connector service.     - Some internal re-architecting of the server to put the foundation of future developments such as virtual       directory services. The new NetworkGroups and WorkFlow internal services which have been specified in       <https://www.opends.org/wiki/page/BasicOperationRoutingThroughNetworkGroup> are now implemented.     - Many bug fixes...

---
 opends/tests/staf-tests/functional-tests/testcases/indexes/indexes.xml |  225 ++++++++++++++++++++++++++++++++++++-------------------
 1 files changed, 146 insertions(+), 79 deletions(-)

diff --git a/opends/tests/staf-tests/functional-tests/testcases/indexes/indexes.xml b/opends/tests/staf-tests/functional-tests/testcases/indexes/indexes.xml
index 9fa54c0..9463d8c 100644
--- a/opends/tests/staf-tests/functional-tests/testcases/indexes/indexes.xml
+++ b/opends/tests/staf-tests/functional-tests/testcases/indexes/indexes.xml
@@ -40,14 +40,11 @@
              { 'parent' : STAXParentID }
         </call>
         <script>
-          CurrentTestPath={'group':'indexes','suite':'indexes'}
+          CurrentTestPath['group'] = 'indexes'
           envAlreadyLoaded='true'
-          _setupSteps=['testGroup_Preamble','testSuite_Preamble',
-                       'indexes_setup']
-          _testSteps=['indexes_search', 'indexes_dynamic_modify',
-                      'indexes_dynamic_add', 'indexes_remove', 'indexes_add']
-          _cleanupSteps=['indexes_cleanup','testSuite_Postamble',
-                         'testGroup_Postamble']
+          _testSteps=['indexes_setup','indexes_search','indexes_dynamic_modify',
+                      'indexes_dynamic_add','indexes_remove', 'indexes_add',
+                      'indexes_cleanup']
         </script>
         <!---
           #@TestSuiteName      Indexes
@@ -59,11 +56,9 @@
         <try>
           <!-- the pre-requisites are in a separate iteration -->
           <sequence>
-            <iterate in="_setupSteps" var="_setupStep">
-              <call function="_setupStep" />
-            </iterate>
+            <call function="'testGroup_Preamble'"/>
             <iterate in="_testSteps" var="_testStep" indexvar="_testStepNumber">
-              <call function="_testStep" />
+              <call function="_testStep"/>
             </iterate>
           </sequence>
           <catch exception="'STAXException.Topology.CreationException'">
@@ -77,9 +72,7 @@
             </message>
           </catch>
           <finally>
-            <iterate in="_cleanupSteps" var="_cleanupStep">
-              <call function="_cleanupStep" />
-            </iterate>
+            <call function="'testGroup_Postamble'"/>
           </finally>
         </try>
       </sequence>
@@ -99,14 +92,21 @@
       #@TestPostamble             none
       #@TestResult                Success if entry are indexed correctly
     -->
-    <block name="'Search'">
+    <block name="'indexes_search'">
       <sequence>
+        <script>
+          CurrentTestPath['suite'] = STAXCurrentBlock
+        </script>
+        <call function="'testSuite_Preamble'"/>
+
         <message log="1" level="'info'">
           'starting the search tests'
         </message>
         <call function="'loopThroughFilters'">
           { 'filters' : 'search' }
         </call>
+
+        <call function="'testSuite_Postamble'"/>
       </sequence>
     </block>
   </function>
@@ -125,8 +125,13 @@
       #@TestPostamble             none
       #@TestResult                Success if entry are indexed correctly
     -->
-    <block name="'Modify'">
+    <block name="'indexes_modify'">
       <sequence>
+        <script>
+          CurrentTestPath['suite'] = STAXCurrentBlock
+        </script>
+        <call function="'testSuite_Preamble'"/>
+
         <try>
           <sequence>
             <call function="'loopThroughFilters'">
@@ -150,11 +155,11 @@
               { 'functionName'      : 'StopDsWithScript',
                 'functionException' : 'CLI.stop-ds',
                 'functionFailureTC' : 'Indexes - Modify' ,
-                'functionArguments' : { 'location'  : STAF_REMOTE_HOSTNAME,
-                                        'dsHost'    : DIRECTORY_INSTANCE_HOST,
-                                        'dsPort'    : DIRECTORY_INSTANCE_PORT,
-                                        'dsBindDN'  : DIRECTORY_INSTANCE_DN  ,
-                                        'dsBindPwd' : DIRECTORY_INSTANCE_PSWD }
+                'functionArguments' : { 'location'    : STAF_REMOTE_HOSTNAME,
+                                        'dsHost'      : DIRECTORY_INSTANCE_HOST,
+                                        'dsAdminPort' : DIRECTORY_INSTANCE_ADMIN_PORT,
+                                        'dsBindDN'    : DIRECTORY_INSTANCE_DN  ,
+                                        'dsBindPwd'   : DIRECTORY_INSTANCE_PSWD }
               }
             </call>
             <call function="'runFunction'">
@@ -188,6 +193,8 @@
             </message>
           </catch>
         </try>
+
+        <call function="'testSuite_Postamble'"/>
       </sequence>
     </block>
   </function>
@@ -207,8 +214,13 @@
       #@TestPostamble             none
       #@TestResult                Success if entry are indexed correctly
     -->
-    <block name="'Modify'">
+    <block name="'indexes_dynamic_modify'">
       <sequence>
+        <script>
+          CurrentTestPath['suite'] = STAXCurrentBlock
+        </script>
+        <call function="'testSuite_Preamble'"/>
+
         <try>
           <sequence>
             <call function="'loopThroughFilters'">
@@ -259,6 +271,8 @@
             </message>
           </catch>
         </try>
+
+        <call function="'testSuite_Postamble'"/>
       </sequence>
     </block>
   </function>
@@ -280,8 +294,13 @@
       #@TestPostamble           none
       #@TestResult              Success if entry are indexed correctly
     -->
-    <block name="'Add'">
+    <block name="'indexes_add'">
       <sequence>
+        <script>
+          CurrentTestPath['suite'] = STAXCurrentBlock
+        </script>
+        <call function="'testSuite_Preamble'"/>
+
         <try>
           <sequence>
             <call function="'loopThroughFilters'">
@@ -306,11 +325,11 @@
                 'functionFailureTC' : '%s: %s: %s' % (CurrentTestPath['group'], 
                                                       CurrentTestPath['suite'], 
                                                       STAXCurrentBlock ) ,
-                'functionArguments' : { 'location'  : STAF_REMOTE_HOSTNAME,
-                                        'dsHost'    : DIRECTORY_INSTANCE_HOST,
-                                        'dsPort'    : DIRECTORY_INSTANCE_PORT,
-                                        'dsBindDN'  : DIRECTORY_INSTANCE_DN  ,
-                                        'dsBindPwd' : DIRECTORY_INSTANCE_PSWD 
+                'functionArguments' : { 'location'    : STAF_REMOTE_HOSTNAME,
+                                        'dsHost'      : DIRECTORY_INSTANCE_HOST,
+                                        'dsAdminPort' : DIRECTORY_INSTANCE_ADMIN_PORT,
+                                        'dsBindDN'    : DIRECTORY_INSTANCE_DN,
+                                        'dsBindPwd'   : DIRECTORY_INSTANCE_PSWD 
                                       }
               }
             </call>
@@ -345,6 +364,8 @@
             </message>
           </catch>
         </try>
+
+        <call function="'testSuite_Postamble'"/>
       </sequence>
     </block>
   </function>
@@ -367,8 +388,13 @@
       #@TestPostamble           none
       #@TestResult              Success if entry are indexed correctly
     -->
-    <block name="'Add'">
+    <block name="'indexes_dynamic_add'">
       <sequence>
+        <script>
+          CurrentTestPath['suite'] = STAXCurrentBlock
+        </script>
+        <call function="'testSuite_Preamble'"/>
+
         <try>
           <sequence>
             <call function="'loopThroughFilters'">
@@ -417,6 +443,8 @@
             </message>
           </catch>            
         </try>
+
+        <call function="'testSuite_Postamble'"/>
       </sequence>
     </block>
   </function>
@@ -437,8 +465,13 @@
       #@TestPostamble           none
       #@TestResult              Success if entry are indexed as expected
     -->
-    <block name="'Remove'">
+    <block name="'indexes_remove'">
       <sequence>
+        <script>
+          CurrentTestPath['suite'] = STAXCurrentBlock
+        </script>
+        <call function="'testSuite_Preamble'"/>
+
         <try>
           <sequence>
             <call function="'loopThroughFilters'">
@@ -464,6 +497,8 @@
             </message>
           </catch>
         </try>
+
+        <call function="'testSuite_Postamble'"/>
       </sequence>
     </block>
   </function>
@@ -483,8 +518,13 @@
       #@TestPostamble           none
       #@TestResult              Success if entry are indexed as expected
     -->
-    <block name="'Entry_Limit'">
+    <block name="'indexes_entry_limit'">
       <sequence>
+        <script>
+          CurrentTestPath['suite'] = STAXCurrentBlock
+        </script>
+        <call function="'testSuite_Preamble'"/>
+        
         <try>
           <sequence>
             <call function="'loopThroughFilters'">
@@ -515,6 +555,8 @@
             </message>
           </catch>
         </try>
+
+        <call function="'testSuite_Postamble'"/>
       </sequence>
     </block>
   </function>
@@ -534,8 +576,13 @@
       #@TestPostamble           none
       #@TestResult              Success if entry are indexed as expected
     -->
-    <block name="'Entry_Limit'">
+    <block name="'indexes_vlv_add'">
       <sequence>
+        <script>
+          CurrentTestPath['suite'] = STAXCurrentBlock
+        </script>
+        <call function="'testSuite_Preamble'"/>
+        
         <try>
           <sequence>
             <call function="'loopThroughFilters'">
@@ -566,6 +613,8 @@
             </message>
           </catch>
         </try>
+
+        <call function="'testSuite_Postamble'"/>
       </sequence>
     </block>
   </function>
@@ -645,10 +694,10 @@
             testNumber=0
             
           </script>
-          <testcase name="'%s: %d.%s: %03d-%03d.%s: %s%02d' 
-            % ( CurrentTestPath['group'], len(_testSteps)-_testStepNumber, 
-                filters, len(indexTests)-indexTestNumber, indexTestNumber, 
-                test.getAttribute(), test.getName(), testNumber)" >
+          <testcase name="getTestCaseName('%s: %03d-%03d.%s: %s%02d')
+            % (filters, len(indexTests)-indexTestNumber, indexTestNumber, 
+               test.getAttribute(), test.getName(), testNumber)">
+
             <sequence>
               <call function="'testCase_Preamble'" />
               <message log="1" level="'trace'">
@@ -700,52 +749,70 @@
   
   <!-- Setup the instance for indexes tests -->
   <function name="indexes_setup">
-    <sequence>
-      <call function="'runFunction'">
-        { 'functionName'      : 'createTopology',
-          'functionMessage'   : 'Create DS topology as described in config.py',
-          'functionException' : 'Topology.CreationException',
-          'functionArguments' : { 'initialiseInstance' : True }
-        }
-      </call>
-      <call function="'runFunction'">
-        { 'functionName'      : 'StartDsWithScript'                                      ,
-          'functionMessage'   : 'Start DS to run on port %s' \
-                                 % (DIRECTORY_INSTANCE_PORT) ,
-          'functionArguments' : { 'location' : STAF_REMOTE_HOSTNAME }
-        }
-      </call>
-      <call function="'runFunction'">
-        { 'functionName'      : 'isAlive',
-          'functionMessage'   : 'Checking if the server is available',
-          'functionException' : 'Topology.StartException',
-          'functionArguments' : { 'noOfLoops'        : 5,
-                                  'noOfMilliSeconds' : 2000 
-                                }
-        }
-      </call>
-    </sequence>
+    <block name="'indexes_setup'">
+      <sequence>
+        <script>
+          CurrentTestPath['suite'] = STAXCurrentBlock
+        </script>
+        <call function="'testSuite_Preamble'"/>     
+
+        <call function="'runFunction'">
+          { 'functionName'      : 'createTopology',
+            'functionMessage'   : 'Create DS topology as described in config.py',
+            'functionException' : 'Topology.CreationException',
+            'functionArguments' : { 'initialiseInstance' : True }
+          }
+        </call>
+        <call function="'runFunction'">
+          { 'functionName'      : 'StartDsWithScript'                                      ,
+            'functionMessage'   : 'Start DS to run on port %s' \
+                                  % (DIRECTORY_INSTANCE_PORT) ,
+            'functionArguments' : { 'location' : STAF_REMOTE_HOSTNAME }
+          }
+        </call>
+        <call function="'runFunction'">
+          { 'functionName'      : 'isAlive',
+            'functionMessage'   : 'Checking if the server is available',
+            'functionException' : 'Topology.StartException',
+            'functionArguments' : { 'noOfLoops'        : 5,
+                                    'noOfMilliSeconds' : 2000 
+                                  }
+          }
+        </call>
+
+        <call function="'testSuite_Postamble'"/>
+      </sequence>
+    </block>
   </function>
   
   <!-- cleanup after the tests -->
   <function name="indexes_cleanup">
-    <sequence>
-      <call function="'runFunction'">
-        { 'functionName'      : 'StopDsWithScript' ,
-          'functionMessage'   : 'Stop DS running on port %s' \
-                                 % (DIRECTORY_INSTANCE_PORT),
-          'functionArguments' : { 'location'  : STAF_REMOTE_HOSTNAME,
-                                  'dsHost'    : DIRECTORY_INSTANCE_HOST,
-                                  'dsPort'    : DIRECTORY_INSTANCE_PORT,
-                                  'dsBindDN'  : DIRECTORY_INSTANCE_DN,
-                                  'dsBindPwd' : DIRECTORY_INSTANCE_PSWD }
-        }
-      </call>
-      <call function="'runFunction'">
-        { 'functionName'    : 'removeTopology',
-          'functionMessage' : 'Remove DS topology created for the Test Suite'
-        }
-      </call>
-    </sequence>
+    <block name="'indexes_cleanup'">
+      <sequence>
+        <script>
+          CurrentTestPath['suite'] = STAXCurrentBlock
+        </script>
+        <call function="'testSuite_Preamble'"/>
+
+        <call function="'runFunction'">
+          { 'functionName'      : 'StopDsWithScript' ,
+            'functionMessage'   : 'Stop DS running on port %s' \
+                                  % (DIRECTORY_INSTANCE_PORT),
+            'functionArguments' : { 'location'    : STAF_REMOTE_HOSTNAME,
+                                    'dsHost'      : DIRECTORY_INSTANCE_HOST,
+                                    'dsAdminPort' : DIRECTORY_INSTANCE_ADMIN_PORT,
+                                    'dsBindDN'    : DIRECTORY_INSTANCE_DN,
+                                    'dsBindPwd'   : DIRECTORY_INSTANCE_PSWD }
+          }
+        </call>
+        <call function="'runFunction'">
+          { 'functionName'    : 'removeTopology',
+            'functionMessage' : 'Remove DS topology created for the Test Suite'
+          }
+        </call>
+
+        <call function="'testSuite_Postamble'"/>
+      </sequence>
+    </block>
   </function>
 </stax>

--
Gitblit v1.10.0