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

andrug
16.57.2008 248ed47eb46b93bfbd3d0ddfd583d3374cac02db
allow grep() to return the return code value
1 files modified
10 ■■■■■ changed files
opends/tests/system-tests/phases/shared/functions/utils.xml 10 ●●●●● patch | view | raw | blame | history
opends/tests/system-tests/phases/shared/functions/utils.xml
@@ -489,6 +489,7 @@
      </if>
      <!-- ========== -->
      <script>
        _errNum = 0
        result = 'NOTHING'
        
        if (caseSensitive == TRUE):
@@ -513,6 +514,7 @@
      </script>
      
      <if expr="expect2Find == TRUE">
        <sequence>
        <if expr="(result != 'NOTHING') and (grepRC == 0)">
          <call function="'checkRC'">
            { 'returncode' : 0,
@@ -527,9 +529,12 @@
          </call>
        </else>
        </if>
          <script> _errNum += STAXResult </script>
        </sequence>
      
      <!-- == expect2Find == FALSE == -->
      <else>
        <sequence>
        <if expr="(result == '') and (grepRC != 0)">
          <call function="'checkRC'">
            { 'returncode' : 0,
@@ -545,12 +550,15 @@
          </call>
        </else>
        </if>
        <script> _errNum += STAXResult </script>
        </sequence>
      </else>
      </if>
      
      <!-- ========== -->
      <call function="'writeEndTagOperation'">{'fileFd'  : fileFd}</call>
      <return> _errNum </return>
    </sequence>
  </function>