Repositorio del curso CCOM4030 el semestre B91 del proyecto kilometro0

timeout.js 273B

123456789101112131415
  1. var test = require('../');
  2. var ran = 0;
  3. test('timeout', function (t) {
  4. t.pass('this should run');
  5. ran++;
  6. setTimeout(function () {
  7. t.end();
  8. }, 100);
  9. });
  10. test('should still run', { timeout: 50 }, function (t) {
  11. t.equal(ran, 1);
  12. t.end();
  13. });