nextTest = function() {
    if (testTimer != null) {
      clearTimeout(testTimer);
    }
    if (testIndex < tests.length) {
      setTimeout(function() {
        var test = tests[testIndex++];
        console.log('Testing ' + test.baseName);
        var runner = RUNNERS[test.type];
        assert(runner != null, 'Unexpected test type ' + test.type);
        testTimer = setTimeout(function() {
          assert.fail(null, null, 'Test took too long.');
        }, 120 * 1000);
        runner(test, nextTest);
      }, 0);
    }
  }
Asynchronously enqueues the next test, or stops if all tests
have finished.