Skip to content

Commit

Permalink
Tests: Migrate test runner to jquery-test-runner
Browse files Browse the repository at this point in the history
Closes gh-560
  • Loading branch information
timmywil authored Jan 14, 2025
1 parent 758a93f commit b830568
Show file tree
Hide file tree
Showing 33 changed files with 354 additions and 2,915 deletions.
32 changes: 5 additions & 27 deletions .github/workflows/browser-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
- main

env:
NODE_VERSION: 20.x
NODE_VERSION: 22.x

jobs:
test:
Expand Down Expand Up @@ -45,14 +45,8 @@ jobs:
- name: Run tests
run: |
npm run pretest
npm run test:unit -- -b ${{ matrix.BROWSER }} -h \
--jquery-migrate ${{ matrix.MIGRATE_VERSION }} \
--jquery git --jquery git.min --jquery git.slim --jquery git.slim.min \
--jquery 3.x-git --jquery 3.x-git.min --jquery 3.x-git.slim --jquery 3.x-git.slim.min \
--jquery 3.7.1 --jquery 3.7.1.slim \
--jquery 3.6.4 --jquery 3.5.1 --jquery 3.4.1 \
--jquery 3.3.1 --jquery 3.2.1 --jquery 3.1.1 --jquery 3.0.0 \
--retries 1
npm run test:unit -- -c jtr-local.yml \
--headless -b ${{ matrix.BROWSER }} -f plugin=${{ matrix.MIGRATE_VERSION }}
ie:
runs-on: windows-latest
Expand Down Expand Up @@ -81,15 +75,7 @@ jobs:

- name: Run tests
shell: cmd
run: |
npm run test:ie -- ^
--jquery-migrate ${{ env.MIGRATE_VERSION }} ^
--jquery git --jquery git.min --jquery git.slim --jquery git.slim.min ^
--jquery 3.x-git --jquery 3.x-git.min --jquery 3.x-git.slim --jquery 3.x-git.slim.min ^
--jquery 3.7.1 --jquery 3.7.1.slim ^
--jquery 3.6.4 --jquery 3.5.1 --jquery 3.4.1 ^
--jquery 3.3.1 --jquery 3.2.1 --jquery 3.1.1 --jquery 3.0.0 ^
--retries 1
run: npm run test:ie -- -c jtr-local.yml -f plugin=${{ env.MIGRATE_VERSION }}

safari:
runs-on: macos-latest
Expand Down Expand Up @@ -117,12 +103,4 @@ jobs:
run: npm install

- name: Run tests
run: |
npm run test:safari -- \
--jquery-migrate ${{ env.MIGRATE_VERSION }} \
--jquery git --jquery git.min --jquery git.slim --jquery git.slim.min \
--jquery 3.x-git --jquery 3.x-git.min --jquery 3.x-git.slim --jquery 3.x-git.slim.min \
--jquery 3.7.1 --jquery 3.7.1.slim \
--jquery 3.6.4 --jquery 3.5.1 --jquery 3.4.1 \
--jquery 3.3.1 --jquery 3.2.1 --jquery 3.1.1 --jquery 3.0.0 \
--retries 1
run: npm run test:safari -- -c jtr-local.yml -f plugin=${{ env.MIGRATE_VERSION }}
13 changes: 3 additions & 10 deletions .github/workflows/browserstack-3.x.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
env:
BROWSERSTACK_USERNAME: ${{ secrets.BROWSERSTACK_USERNAME }}
BROWSERSTACK_ACCESS_KEY: ${{ secrets.BROWSERSTACK_ACCESS_KEY }}
NODE_VERSION: 20.x
NODE_VERSION: 22.x
name: ${{ matrix.BROWSER }}
concurrency:
group: ${{ matrix.BROWSER }} - ${{ github.sha }}
Expand Down Expand Up @@ -79,13 +79,6 @@ jobs:

- name: Test
run: |
npm run test:unit -- \
-v --browserstack "${{ matrix.BROWSER }}" \
--jquery-migrate dev --jquery-migrate min \
--jquery 3.x-git --jquery 3.x-git.min --jquery 3.x-git.slim --jquery 3.x-git.slim.min \
--jquery 3.7.1 --jquery 3.7.1.slim --jquery 3.6.4 --jquery 3.6.4.slim \
--jquery 3.5.1 --jquery 3.5.1.slim --jquery 3.4.1 --jquery 3.4.1.slim \
--jquery 3.3.1 --jquery 3.3.1.slim --jquery 3.2.1 --jquery 3.2.1.slim \
--jquery 3.1.1 --jquery 3.1.1.slim --jquery 3.0.0 --jquery 3.0.0.slim \
npm run test:unit -- -v -c jtr-3.x.yml \
--browserstack "${{ matrix.BROWSER }}" \
--run-id ${{ github.run_id }} \
--retries 3 --hard-retries 1
9 changes: 3 additions & 6 deletions .github/workflows/browserstack-git.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
env:
BROWSERSTACK_USERNAME: ${{ secrets.BROWSERSTACK_USERNAME }}
BROWSERSTACK_ACCESS_KEY: ${{ secrets.BROWSERSTACK_ACCESS_KEY }}
NODE_VERSION: 20.x
NODE_VERSION: 22.x
name: ${{ matrix.BROWSER }}
concurrency:
group: ${{ matrix.BROWSER }} - ${{ github.sha }}
Expand Down Expand Up @@ -63,9 +63,6 @@ jobs:

- name: Test
run: |
npm run test:unit -- \
-v --browserstack "${{ matrix.BROWSER }}" \
--jquery-migrate dev --jquery-migrate min \
--jquery git --jquery git.min --jquery git.slim --jquery git.slim.min \
npm run test:unit -- -v -c jtr-git.yml \
--browserstack "${{ matrix.BROWSER }}" \
--run-id ${{ github.run_id }} \
--retries 3 --hard-retries 1
2 changes: 1 addition & 1 deletion .github/workflows/filestash.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
runs-on: ubuntu-latest
environment: filestash
env:
NODE_VERSION: 20.x
NODE_VERSION: 22.x
name: Update Filestash
steps:
- name: Checkout
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/node.js.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
branches-ignore: "dependabot/**"

env:
NODE_VERSION: 20.x
NODE_VERSION: 22.x

jobs:
node-smoke-test:
Expand Down
30 changes: 30 additions & 0 deletions jtr-3.x.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
version: 1

runs:
jquery:
- 3.x-git
- 3.x-git.min
- 3.x-git.slim
- 3.x-git.slim.min
- 3.7.1
- 3.7.1.slim
- 3.6.4
- 3.6.4.slim
- 3.5.1
- 3.5.1.slim
- 3.4.1
- 3.4.1.slim
- 3.3.1
- 3.3.1.slim
- 3.2.1
- 3.2.1.slim
- 3.1.1
- 3.1.1.slim
- 3.0.0
- 3.0.0.slim
plugin:
- dev
- min

retries: 2
hard-retries: 1
14 changes: 14 additions & 0 deletions jtr-git.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
version: 1

runs:
jquery:
- git
- git.min
- git.slim
- git.slim.min
plugin:
- dev
- min

retries: 2
hard-retries: 1
23 changes: 23 additions & 0 deletions jtr-local.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
version: 1

flags:
jquery:
- git
- git.min
- git.slim
- git.slim.min
- 3.x-git
- 3.x-git.min
- 3.x-git.slim
- 3.x-git.slim.min
- 3.7.1
- 3.7.1.slim
- 3.6.4
- 3.5.1
- 3.4.1
- 3.3.1
- 3.2.1
- 3.1.1
- 3.0.0

retries: 1
Loading

0 comments on commit b830568

Please sign in to comment.