refactor: migrate from Jest to Vitest
It does so by:
- Installing vitest dependencies and removing the jest dependencies.
- Changing the test target in the Makefile to use Vitest.
- Changing the CI pipelines to use Vitest instead of Jest.
- Removing jest configuration from eslint.config.js and adding the
vitest eslint plugin.
This commit also fixes some issues in the FetchProxy test suite.
Fixed: twpowertools:236
Change-Id: I6a6a636cd5e943194ff6b06c17a150537659d586
diff --git a/roles/test/tasks/main.yaml b/roles/test/tasks/main.yaml
index 80d0848..ee9e231 100644
--- a/roles/test/tasks/main.yaml
+++ b/roles/test/tasks/main.yaml
@@ -2,7 +2,7 @@
shell:
cmd: |
set -euxo pipefail
- node ./node_modules/jest/bin/jest.js --ci |& tee out/jest-log.txt
+ CI=true make test |& tee out/vitest-log.txt
chdir: "{{ zuul.project.src_dir }}"
executable: /bin/bash
changed_when: false