Skip to content

feat(linter/eslint-plugin-vitest): Implement valid-title eslint rule#17224

Closed
Afsoon wants to merge 4 commits intooxc-project:mainfrom
Afsoon:vitest-valid-title
Closed

feat(linter/eslint-plugin-vitest): Implement valid-title eslint rule#17224
Afsoon wants to merge 4 commits intooxc-project:mainfrom
Afsoon:vitest-valid-title

Conversation

@Afsoon
Copy link
Copy Markdown
Contributor

@Afsoon Afsoon commented Dec 21, 2025

Related to #4656

Set valid-title as a compatible vitest rule

oxc-project/oxlint-migrate#301

@Afsoon Afsoon requested a review from camc314 as a code owner December 21, 2025 17:53
@github-actions github-actions bot added A-linter Area - Linter C-enhancement Category - New feature or request labels Dec 21, 2025
@codspeed-hq
Copy link
Copy Markdown

codspeed-hq bot commented Dec 21, 2025

CodSpeed Performance Report

Merging #17224 will not alter performance

Comparing Afsoon:vitest-valid-title (8213101) with main (7e5fc90)

Summary

✅ 4 untouched
⏩ 41 skipped1

Footnotes

  1. 41 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

Copy link
Copy Markdown
Member

@connorshea connorshea left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Started a review and then realized that... technically valid-title is already implemented for vitest partially via the jest/valid-title rule? It just wasn't done properly: bd74603

Do we need to do anything specific for that?

@camc314 camc314 self-assigned this Dec 22, 2025
@Afsoon
Copy link
Copy Markdown
Contributor Author

Afsoon commented Dec 22, 2025

@connorshea Looks that not, we have to extend the current valid-title, apart of adding as a compatible vitest rule. Vitest have some test that depends on the vitestImports pattern. I'm going to set this PR as draft and update it when I have time for it.

Thanks!

@Afsoon Afsoon marked this pull request as draft December 22, 2025 12:05
@Afsoon Afsoon force-pushed the vitest-valid-title branch from af86eb8 to a7287be Compare December 22, 2025 14:20
@Afsoon Afsoon marked this pull request as ready for review December 22, 2025 14:24
@Afsoon
Copy link
Copy Markdown
Contributor Author

Afsoon commented Dec 22, 2025

Doing from zero valid-title and warn-todo I have found some issues that are probably better talked before to do anything. The current PR doesn't handle the vitestImports test. The other issue is how vitest and jest are detected.

@Afsoon Afsoon force-pushed the vitest-valid-title branch 4 times, most recently from 5f8359f to 6a318d7 Compare December 24, 2025 08:05
@Afsoon
Copy link
Copy Markdown
Contributor Author

Afsoon commented Dec 24, 2025

@camc314 I have recovered the changes I made to handle the test with vitestImports settings, and added thoses test in the rule

@Afsoon Afsoon force-pushed the vitest-valid-title branch from 6a318d7 to b1ff2de Compare December 26, 2025 07:13
@github-actions github-actions bot added the A-cli Area - CLI label Dec 26, 2025
@Afsoon Afsoon force-pushed the vitest-valid-title branch from b1ff2de to 8213101 Compare December 31, 2025 06:00
@connorshea connorshea self-requested a review January 24, 2026 20:56
@Afsoon
Copy link
Copy Markdown
Contributor Author

Afsoon commented Feb 20, 2026

Closing, as it makes more sense re do it once #18603 and #18467 are merged

@Afsoon Afsoon closed this Feb 20, 2026
@Afsoon Afsoon deleted the vitest-valid-title branch February 20, 2026 06:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-cli Area - CLI A-linter Area - Linter C-enhancement Category - New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants