{"record":{"id":"b508e8518ec8fa34","repo":"oxc-project/oxc","slug":"disabled-test-suite","errorCode":null,"errorMessage":"Disabled test suite","messagePattern":"Disabled test suite","errorType":"validation","errorClass":"OxcDiagnostic","httpStatus":null,"severity":"warning","filePath":"crates/oxc_linter/src/rules/shared/jest_vitest/no_disabled_tests.rs","lineNumber":51,"sourceCode":"describe['skip']('bar', () => {});\nit['skip']('bar', () => {});\ntest['skip']('bar', () => {});\n\nxdescribe('foo', () => {});\nxit('foo', () => {});\nxtest('foo', () => {});\n\nit('bar');\ntest('bar');\n\nit('foo', () => {\n  pending();\n});\n```\n\";\n\nfn no_disabled_tests_diagnostic(x1: &'static str, x2: &'static str, span3: Span) -> OxcDiagnostic {\n    OxcDiagnostic::warn(x1).with_help(x2).with_label(span3)\n}\n\nenum Message {\n    MissingFunction,\n    Pending,\n    DisabledSuiteWithSkip,\n    DisabledSuiteWithX,\n    DisabledTestWithSkip,\n    DisabledTestWithX,\n}\n\nimpl Message {\n    pub fn details(&self) -> (&'static str, &'static str) {\n        match self {\n            Self::MissingFunction => (\"Test is missing function argument\", \"Add function argument\"),\n            Self::Pending => (\"Call to pending()\", \"Remove pending() call\"),\n            Self::DisabledSuiteWithSkip => (\"Disabled test suite\", \"Remove the appending `.skip`\"),\n            Self::DisabledSuiteWithX => (\"Disabled test suite\", \"Remove x prefix\"),","sourceCodeStart":33,"sourceCodeEnd":69,"githubUrl":"https://github.com/oxc-project/oxc/blob/a3d33dda7cb69da23db4fcaa2c0c05de61e760a1/crates/oxc_linter/src/rules/shared/jest_vitest/no_disabled_tests.rs#L33-L69","documentation":"The `Disabled test suite` diagnostic of oxlint rule `jest/no-disabled-tests` (shared with vitest), produced by both Message::DisabledSuiteWithSkip and Message::DisabledSuiteWithX variants. It fires when a describe block is disabled, either via `describe.skip(...)` (help: remove the appending `.skip`) or via the `xdescribe(...)` prefix form (help: remove x prefix).","triggerScenarios":"From no_disabled_tests.rs:114-133: any parsed general jest call whose name starts with `x` (xdescribe) or whose member chain contains `skip` (describe.skip), where the parsed kind is JestGeneralFnKind::Describe. The diagnostic labels the callee span.","commonSituations":"Commenting out a broken suite by skipping it instead; merging branches where describe.skip was never removed; batch-disabling slow suites before a demo; stale skips left after the underlying bug was fixed.","solutions":["Remove `.skip` / the `x` prefix so the suite runs again (verify it passes)","If the suite genuinely cannot run, gate it properly: use conditional describe guarded by environment, or move it behind a tag/annotation your runner supports","Sweep for leftovers in CI: rg -n 'describe\\.skip\\(|xdescribe\\(' in the repo, and treat new ones as review blockers"],"exampleFix":"// before\ndescribe.skip('payment flow', () => { /* ... */ });\nxdescribe('legacy api', () => { /* ... */ });\n\n// after\ndescribe('payment flow', () => { /* ... */ });\ndescribe('legacy api', () => { /* ... */ });","handlingStrategy":"validation","validationCode":"rg -n \"\\bxdescribe\\(|\\bdescribe\\.skip\\(\" tests/ && exit 1 || exit 0 # fail on disabled suites","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Wire the grep above (or oxlint with --deny-warnings) into CI so describe.skip blocks the merge","Fix broken suites instead of skipping them; skip only with a linked issue comment","Review `.skip` occurrences in every PR diff as a mandatory checklist item"],"tags":["jest","vitest","oxlint","testing","skipped-test","describe"],"backgroundTag":"skipped-test","analyzedSha":"a3d33dda7cb69da23db4fcaa2c0c05de61e760a1","analyzedAt":"2026-08-20T07:01:07.079Z","contentChangedAt":"2026-08-20T07:01:07.079Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}