runTests(tests) {
    return new Promise((resolve, reject) => {
      var index = 0
      /**
       * Schedule asynchronous list execution with promise
       */
      execTest = () => {
        /* run a test * @property {String} */
        this.runTest(tests[index]).then(() => {
          index++
          /* schedule only if elements left */
          if (index < tests.length)
            process.nextTick(execTest)
          else
            resolve()
        }).catch((err) => {
          reject(err)
        })
      }
      /* schedule only if elements left */
      if (i < tests.length)
        process.nextTick(execTest)
      else
        resolve()
    })
  }
/**
   * Run selected tests
   *
   * The function executes all tests from the argument list.
   *
   * @param {TestInfo[]} tests A list of tests to run.
   * @return {Promise} A promise which resolves when all tests have run
   */
Run selected tests
The function executes all tests from the argument list.

@param {TestInfo[]} tests A list of tests to run.
@return {Promise} A promise which resolves when all tests have run
Run selected tests The function executes all tests from the argument list . @param { TestInfo [] } tests A list of tests to run . @return { Promise } A promise which resolves when all tests have run
runTests(tests) {
    return new Promise((resolve, reject) => {
      var index = 0
      execTest = () => {
        this.runTest(tests[index]).then(() => {
          index++
          if (index < tests.length)
            process.nextTick(execTest)
          else
            resolve()
        }).catch((err) => {
          reject(err)
        })
      }
      if (i < tests.length)
        process.nextTick(execTest)
      else
        resolve()
    })
  }
runTests ( tests ) { return new Promise ( ( resolve , reject ) => { var index = 0 execTest = ( ) => { this . runTest ( tests [ index ] ) . then ( ( ) => { index ++ if ( index < tests . length ) process . nextTick ( execTest ) else resolve ( ) } ) . catch ( ( err ) => { reject ( err ) } ) } if ( i < tests . length ) process . nextTick ( execTest ) else resolve ( ) } ) }
Run selected tests
 The function executes all tests from the argument list.
Run selected tests The function executes all tests from the argument list .
/**
       * Schedule asynchronous list execution with promise
       */ /* run a test * @property {String} */ /* schedule only if elements left */ /* schedule only if elements left */