Skip to content

Latest commit

 

History

History
25 lines (16 loc) · 619 Bytes

prefer-todo.md

File metadata and controls

25 lines (16 loc) · 619 Bytes

Enforce using test.todo (vitest/prefer-todo)

⚠️ This rule warns in the 🌐 all config.

🔧 This rule is automatically fixable by the --fix CLI option.

When tests are empty it's better to mark them as test.todo as it will be highlighted in tests summary output.

Rule details

The following pattern is considered a warning:

test('foo');
test('foo', () => {})
test.skip('foo', () => {})

The following pattern is not considered a warning:

test.todo('foo');