• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1'use strict';
2
3const common = require('../common');
4
5const assert = require('assert');
6const timers = require('timers');
7
8const enrollObj = {
9  _onTimeout: common.mustCall(),
10};
11
12timers.enroll(enrollObj, 1);
13assert.strictEqual(enrollObj._idleTimeout, 1);
14timers.enroll(enrollObj, 10);
15assert.strictEqual(enrollObj._idleTimeout, 10);
16timers.active(enrollObj);
17