no-skip-without-reason
July 2, 2026 ยท View on GitHub
๐ Require a reason when skipping or marking a test as todo.
๐ซ This rule is disabled in the following configs: โ
recommended, โ๏ธ unopinionated.
A skipped or todo test with no explanation leaves the next reader guessing why it is disabled and whether it is safe to re-enable. node:test lets you attach a reason: the skip/todo options accept a string, and the test context methods t.skip() / t.todo() accept a message that is shown in the test results.
This rule reports {skip: true} / {todo: true} options (where a reason string should be used instead) and t.skip() / t.todo() calls with no message. It is off by default.
Chained modifiers (test.skip(โฆ)) have no way to attach a reason, so they are not reported; use the options form with a reason instead.
Examples
import test from 'node:test';
// โ
test('flaky thing', {skip: true}, () => {});
test('wip', t => {
t.todo();
});
// โ
test('flaky thing', {skip: 'fails intermittently, see #123'}, () => {});
test('wip', t => {
t.todo('blocked on the parser rewrite');
});