Skip to content

Conversation

@rothsandro
Copy link
Contributor

If we use custom fixtures in a separate file and import test from there instead of vitest, many rules don't work properly anymore because they expect the functions being imported from vitest. This PR adds a new vitestImports setting that allows specifying additional import patterns that will be detected as Vitest import. I added a few tests for the valid-title rule but I can add tests to other rules as well if needed.

Do you think that's a viable approach?
Thanks for reviewing 🙏

Copy link
Member

@veritem veritem left a comment

Choose a reason for hiding this comment

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

this is good work. mind running format command for me?

@rothsandro
Copy link
Contributor Author

Thanks, I fixed the formatting

@veritem veritem merged commit 8330763 into vitest-dev:main Oct 17, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants