mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

andrug
18.35.2008 89f1e8767db3a5b6f74f9f4d14003c3e8bd67029
ldapsearch(): use runcommand()
1 files modified
46 ■■■■ changed files
opends/tests/system-tests/phases/shared/functions/ldap.xml 46 ●●●● patch | view | raw | blame | history
opends/tests/system-tests/phases/shared/functions/ldap.xml
@@ -876,46 +876,20 @@
      </script>
      
      
      <call function="'writeStartTagOperation'">
      { 'tagName' : 'ldapSearch',
        'fileFd'  : fileFd }
      </call>
      <call function="'writeMessage'">
      { 'fileFd'  : fileFd,
        'content' : '%s %s' % (STAFCmd, STAFCmdParams)
      <call function="'runCommand'">
        { 'name'      : 'LDAP Search %s on %s:%s' %
                        (dsBaseDN,dsInstanceHost,dsInstancePort),
          'location'  : location,
          'command'   : STAFCmd,
          'arguments' : STAFCmdParams,
          'path'      : dsBinPath,
          'fileFd'    : fileFd
      }
      </call>
      <process name="'LDAP Search %s on %s:%s' %
                     (dsBaseDN,dsInstanceHost,dsInstancePort)">
        <location>'%s' % location</location>
        <command>'%s' % STAFCmd</command>
        <parms>'%s' % STAFCmdParams</parms>
        <workdir>'%s' % dsBinPath</workdir>
        <envs>
          ['PATH=/bin:/usr/bin:%s' % dsBinPath]
        </envs>
        <stdout if="outputFile != None" mode="'replace'">'%s' % outputFile</stdout>
        <stderr mode="'stdout'"/>
        <returnstdout/>
      </process>
      <script>
        STAXCode=RC
        STAXReason=STAXResult
      </script>
      <if expr="expectedRC != 'noCheck'">
        <call function="'checkRC'">
          { 'returncode' : STAXCode,
            'result'     : STAXReason,
            'fileFd'     : fileFd }
        </call>
      </if>
      <call function="'writeEndTagOperation'">{'fileFd'  : fileFd}</call>
      <return>
        [STAXCode,STAXReason]
        STAXResult
      </return>
    </sequence>
  </function>