From 995370bf7296de0caf1e0a2612bcf8101b6654df Mon Sep 17 00:00:00 2001 From: Jon Eugster Date: Sat, 24 Aug 2024 04:28:18 +0200 Subject: [PATCH] another option for testing on Windows --- .github/workflows/test.yml | 21 +++++++++++---------- README.md | 2 +- 2 files changed, 12 insertions(+), 11 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 51f615e..48b9792 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -33,16 +33,14 @@ jobs: name: Linux - os: macos-latest name: macOS - # currently only one Windows test - os: windows-latest name: Windows - browser: electron - # - os: windows-latest - # name: Windows - # browser: edge - # exclude: - # - os: windows-latest - # browser: webkit + - os: windows-latest + name: Windows + browser: edge + exclude: + - os: windows-latest + browser: webkit name: ${{ matrix.name }} - ${{ matrix.browser }} runs-on: ${{ matrix.os }} @@ -76,7 +74,6 @@ jobs: - uses: actions/setup-node@v4 - run: npm install - run: npm run setup_demo - if: matrix.os != 'windows-latest' - name: Run tests if: matrix.os != 'windows-latest' uses: cypress-io/github-action@v6 @@ -85,5 +82,9 @@ jobs: wait-on: 'http://localhost:5173' browser: ${{ matrix.browser }} - name: Run test (Windows) - run: npm test + run: | + npx concurrently --hide 0 --kill-others \ + "npm start" \ + "npx wait-on http://localhost:5173 && \ + cypress run --browser ${{ matrix.browser }}" -n server,cypress -s command-cypress if: matrix.os == 'windows-latest' diff --git a/README.md b/README.md index 1403ec3..f274e20 100644 --- a/README.md +++ b/README.md @@ -202,7 +202,7 @@ You can run ``` npm install -npm run test +npm test ``` for the automated cypress tests.