Add support for vite.config.js and vite.config.ts configuration files
Motivation
Currently, neotest-vitest only supports vitest.config.js and vitest.config.ts. However, the Vitest docs call out that vite.config.js and vite.config.ts are valid configuration files: https://vitest.dev/config/#configuration
This change ensures that projects leveraging vite.config.js and vite.config.ts can use neotest-vitest without having to restructure or rename their Vitest config files.
Testing
Unit tests based on the new ./spec/config directory should cover the support and precedence rules for Vite and Vitest config files. I also went through and tested it manually to make sure it was actually working 🙂
Changes
vite.config.js
andvite.config.ts
configuration filesMotivation
Currently, neotest-vitest only supports
vitest.config.js
andvitest.config.ts
. However, the Vitest docs call out thatvite.config.js
andvite.config.ts
are valid configuration files: https://vitest.dev/config/#configurationThis change ensures that projects leveraging
vite.config.js
andvite.config.ts
can use neotest-vitest without having to restructure or rename their Vitest config files.Testing
Unit tests based on the new
./spec/config
directory should cover the support and precedence rules for Vite and Vitest config files. I also went through and tested it manually to make sure it was actually working 🙂