From 785c53182be40a237949baf7a97e35672513330f Mon Sep 17 00:00:00 2001 From: Jan-Paul Kleemans Date: Mon, 20 Nov 2023 17:07:05 +0100 Subject: [PATCH] Add tests for non-ts versions --- .github/workflows/e2e.yml | 62 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index 3fa782d..99e70f2 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -2,6 +2,37 @@ name: End-to-end tests on: [push] jobs: vite-latest: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Install vue-ts + run: npm create vite@latest test-app -- --template vue + + - name: Add example code + run: | + mv ./example/src/App.vue ./test-app/src/App.vue + mv ./example/vite.config.ts ./test-app/vite.config.ts + mv ./example/src/vite-env.d.ts ./test-app/src/vite-env.d.ts + mv ./example/src/assets/test.svg ./test-app/src/assets/test.svg + mv ./example/src/assets/style.svg ./test-app/src/assets/style.svg + mv ./example/src/assets/circle.svg ./test-app/src/assets/circle.svg + mv ./example/public/root.svg ./test-app/public/root.svg + + - name: Build + run: | + cd test-app + npm install + npm install vite-svg-loader --save-dev + npm run build + + - name: Test + uses: cypress-io/github-action@v6 + with: + start: npm run test:preview + + vite-latest-ts: runs-on: ubuntu-latest steps: - name: Checkout @@ -33,6 +64,37 @@ jobs: start: npm run test:preview vite-4: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Install vue-ts + run: npm create vite@4 test-app -- --template vue + + - name: Add example code + run: | + mv ./example/src/App.vue ./test-app/src/App.vue + mv ./example/vite.config.ts ./test-app/vite.config.ts + mv ./example/src/vite-env.d.ts ./test-app/src/vite-env.d.ts + mv ./example/src/assets/test.svg ./test-app/src/assets/test.svg + mv ./example/src/assets/style.svg ./test-app/src/assets/style.svg + mv ./example/src/assets/circle.svg ./test-app/src/assets/circle.svg + mv ./example/public/root.svg ./test-app/public/root.svg + + - name: Build + run: | + cd test-app + npm install + npm install vite-svg-loader --save-dev + npm run build + + - name: Test + uses: cypress-io/github-action@v6 + with: + start: npm run test:preview + + vite-4-ts: runs-on: ubuntu-latest steps: - name: Checkout