From 5a6a88bd1e4831128c55f72923b18f5f771d45f2 Mon Sep 17 00:00:00 2001
From: Christophe Sovant <christophe.sovant@forgerock.com>
Date: Mon, 04 May 2009 16:12:57 +0000
Subject: [PATCH] New functionality to run tests (functional and stress) on a remote machine

---
 opends/tests/staf-tests/shared/functions/snmp.xml |   33 ++++++++++++++++-----------------
 1 files changed, 16 insertions(+), 17 deletions(-)

diff --git a/opends/tests/staf-tests/shared/functions/snmp.xml b/opends/tests/staf-tests/shared/functions/snmp.xml
index 38322e7..1f6da42 100755
--- a/opends/tests/staf-tests/shared/functions/snmp.xml
+++ b/opends/tests/staf-tests/shared/functions/snmp.xml
@@ -23,7 +23,7 @@
  !
  ! CDDL HEADER END
  !
- !      Copyright 2008 Sun Microsystems, Inc.
+ !      Copyright 2008-2009 Sun Microsystems, Inc.
 ! -->
 <stax>
   <!-- SNMP Get -->
@@ -177,7 +177,7 @@
           cp = 'CLASSPATH=%s%s%s%s.' \
           % (opends_jarfile,separator,jdmk_jarfile,separator)
 
-        env = ['JAVA_HOME=%s' % JAVA_HOME, '%s' % cp]
+        env = ['%s' % cp]
       </script>
 
       <message>
@@ -345,7 +345,7 @@
           cp = 'CLASSPATH=%s%s%s%s.' \
           % (opends_jarfile,separator,jdmk_jarfile,separator)
 
-        env = ['JAVA_HOME=%s' % JAVA_HOME, '%s' % cp]
+        env = ['%s' % cp]
       </script>
 
       <message>
@@ -422,21 +422,20 @@
         </function-arg-description>
         <function-arg-property name="type" value="integer"/>
       </function-arg-def>
+      <function-arg-def name="knownIssue" type="optional" default="None">
+        <function-arg-description>
+          Known issue. Corresponds to an issue number.
+        </function-arg-description>
+        <function-arg-property name="type" value="string" />
+      </function-arg-def>
     </function-map-args>
 
     <sequence>
-      <call function="'ResolveVar'" >
-        {
-        'location' : location ,
-        'type'     : 'STRING',
-        'name'     : 'STAF/Config/STAFRoot'
-        }
-      </call>
       <script>
         if is_windows_platform(location):
-          jstaf_jarfile='%s\\bin\\JSTAF.jar' % STAFResult
+          jstaf_jarfile='%s\\bin\\JSTAF.jar' % REMOTE_STAF_ROOT
         else:
-          jstaf_jarfile='%s/lib/JSTAF.jar' % STAFResult
+          jstaf_jarfile='%s/lib/JSTAF.jar' % REMOTE_STAF_ROOT
       </script>
 
       <!-- Build the command -->
@@ -465,13 +464,12 @@
         else:
           separator=':'
 
-        opends_jarfile='%s/%s' % (DIRECTORY_INSTANCE_BIN,SNMP_OPENDS_JARFILE)
         snmpPath='%s/snmp' % remote.java
         jdmk_jarfile='%s/jdmkrt.jar' % snmpPath
-        cp = 'CLASSPATH=%s%s%s%s%s%s.' \
-        % (opends_jarfile,separator,jdmk_jarfile,separator,jstaf_jarfile,separator)
+        cp = 'CLASSPATH=%s%s%s%s.' \
+        % (jdmk_jarfile,separator,jstaf_jarfile,separator)
 
-        env = ['JAVA_HOME=%s' % JAVA_HOME, '%s' % cp]
+        env = ['%s' % cp]
       </script>
 
       <message>
@@ -487,7 +485,8 @@
         'path'       : snmpPath ,
         'envCmd'     : env ,
         'outputFile' : outputFile ,
-        'expectedRC' : expectedRC
+        'expectedRC' : expectedRC ,
+        'knownIssue' : knownIssue
         }
       </call>
 

--
Gitblit v1.10.0