-
-
Notifications
You must be signed in to change notification settings - Fork 8.6k
[js] run applicable JS tests on Windows GHA #16812
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
titusfortner
wants to merge
11
commits into
trunk
Choose a base branch
from
js_gha
base: trunk
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Changes from all commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
73496a8
[js] run applicable JS tests on Windows GHA
titusfortner 9828b26
pinning seems to work on my mac, so uncommenting
titusfortner 6f1d46c
force browser download to get Chrome for Testing
titusfortner 22fa54b
ensure targets are relevant for browser
titusfortner d3d2111
split up tests
titusfortner d49ad12
fix formatting
titusfortner 4b66a7a
actually needs a target for unit tests
titusfortner f7eb2e2
downgrade windows to avoid a potential VS bug
titusfortner 013eebc
support specific runner versions
titusfortner 5510ada
fix workflows
titusfortner 82369e5
wire unit tests to run earliest and latest versions of nodejs
titusfortner File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,87 @@ | ||
| name: CI - JavaScript | ||
|
|
||
| on: | ||
| workflow_call: | ||
| inputs: | ||
| targets: | ||
| required: false | ||
| type: string | ||
| default: '' | ||
| run-full-suite: | ||
| required: false | ||
| type: boolean | ||
| default: true | ||
| workflow_dispatch: | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: | ||
| unit-tests: | ||
| name: Unit Tests | ||
| if: ${{ github.event_name == 'workflow_dispatch' || inputs.run-full-suite }} | ||
| uses: ./.github/workflows/bazel.yml | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| nodejs-version: ['20.19.5', '24.11.1'] | ||
| os: [macos, windows] | ||
| with: | ||
| name: Unit Tests (node ${{ matrix.node-version }}, ${{ matrix.os }}) | ||
| os: ${{ matrix.os }} | ||
| node-version: ${{ matrix.node-version }} | ||
| run: > | ||
| bazel test | ||
| --keep_going | ||
| --build_tests_only | ||
| --test_size_filters=small | ||
| //javascript/selenium-webdriver/... | ||
|
|
||
| filter-targets: | ||
| name: Filter Targets | ||
| runs-on: ubuntu-latest | ||
| outputs: | ||
| targets: ${{ steps.filter.outputs.targets }} | ||
| steps: | ||
| - name: Filter JavaScript targets | ||
| id: filter | ||
| shell: bash | ||
| run: | | ||
| targets="${{ inputs.targets }}" | ||
| filtered=() | ||
|
|
||
| for t in $targets; do | ||
| [[ "$t" == //javascript/selenium-webdriver* ]] && filtered+=("$t") | ||
| done | ||
|
|
||
| if [ ${#filtered[@]} -eq 0 ]; then | ||
| echo "targets=//javascript/selenium-webdriver/..." >> "$GITHUB_OUTPUT" | ||
| else | ||
| echo "targets=${filtered[*]}" >> "$GITHUB_OUTPUT" | ||
| fi | ||
|
|
||
| browser-tests: | ||
| name: Browser Tests | ||
| needs: filter-targets | ||
| uses: ./.github/workflows/bazel.yml | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| browser: [chrome, firefox, chrome-bidi, firefox-bidi] | ||
| os: [windows-2022] | ||
| with: | ||
| name: Browser Tests (${{ matrix.browser }}, ${{ matrix.os }}) | ||
| os: ${{ matrix.os }} | ||
| browser: ${{ matrix.browser }} | ||
| run: > | ||
| bazel test | ||
| --keep_going | ||
| --build_tests_only | ||
| --flaky_test_attempts 3 | ||
| --local_test_jobs 1 | ||
| --test_size_filters=large | ||
| --test_tag_filters=${{ matrix.browser }} | ||
| --pin_browsers=false | ||
| --test_env=SE_FORCE_BROWSER_DOWNLOAD=true | ||
| --test_env=SE_SKIP_DRIVER_IN_PATH=true | ||
| ${{ needs.filter-targets.outputs.targets }} | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| 24.11.1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not 22 instead of 20?
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because 20 doesn't EOL until April, and we say we still support it.
We want to test the newest and oldest to make sure nothing is broken in either.
I'd use 25 instead of 24 if the current version of bazel rules supported it.
In May we switch to 22 and 26