-
Notifications
You must be signed in to change notification settings - Fork 422
test(wtr): run in multiple browsers and with API_VERSION=66 #5533
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
Open
wjhsf
wants to merge
37
commits into
master
Choose a base branch
from
wjh/wtr-keep-on-enving
base: master
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.
Open
Changes from 6 commits
Commits
Show all changes
37 commits
Select commit
Hold shift + click to select a range
099ab86
test(wtr): use vitest spy instead of jasmine
wjhsf a249b96
test(wtr): add API version 66 coverage to CI
wjhsf 1e50ff1
test(wtr): indent consistently
wjhsf 715cac8
test(wtr): move base config into shared dir
wjhsf 22cfa8d
test(wtr): run tests in multiple browsers
wjhsf af60a96
test(wtr): use build script to install playwright
wjhsf 41676b5
chore: bundlesize
wjhsf 1b44785
test(wtr): add type for param
wjhsf 2072694
test(wtr): use sauce helper in CI
wjhsf 423c051
test(wtr): add install to playwright setup
wjhsf 7841184
test(wtr): enable saucelabs in all runs
wjhsf 52915ff
test(wtr): kerjigger playwright again
wjhsf f17448b
test(wtr): rekerjigger playwright again
wjhsf 6412646
test(wtr): make fake SSR file more clear
wjhsf e4092b4
test(wtr): install playwright deps in WTR CI
wjhsf 5357cd7
test(wtr): and much rekerjiggering there was
wjhsf 3fade97
test(wtr): isolate server-side LWC
wjhsf 9e4ac3e
test(wtr): hack for nucleus
wjhsf 465dd72
test(wtr): re-enable CTE tests @W-19098211 (#5535)
wjhsf 5c81592
chore(ci): split hydration tests into engine-server and ssr-v2
wjhsf e928017
chore(ci): split integration tests into two groups
wjhsf 1deb775
Merge branch 'master' into wjh/wtr-keep-on-enving
wjhsf f6ea8de
chore(ci): build first and cache result so parallel jobs are faster
wjhsf e83ec4e
test(wtr): check correct CI env var
wjhsf 02c8206
test(wtr): use concurrency in CI
wjhsf 8564bec
test(wtr): always run browsers concurrently
wjhsf e1288ce
chore(ci): give up on caching (for now?)
wjhsf b1fef23
test(wtr): try difference sauce config
wjhsf 2aa45e1
chore(ci): don't needs: install-and-build
wjhsf 9d59c9a
chore(ci): use distinct tunnel IDs for SauceLabs
wjhsf 3b7657d
Merge branch 'master' into wjh/wtr-keep-on-enving
wjhsf 45d38da
test(wtr): revert concurrency in CI
wjhsf 199412f
test(wtr): disable tests that sauce doesn't like
wjhsf 4672320
test(wtr): only run chrome in saucelabs
wjhsf 41ce390
chore(ci): use env var for runs-on for easier updates
wjhsf 3fc2bc2
chore(ci): use matrix values to ensure unique tunnel IDs
wjhsf 570da42
Revert "chore(ci): use env var for runs-on for easier updates"
wjhsf 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
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
56 changes: 56 additions & 0 deletions
56
packages/@lwc/integration-not-karma/configs/shared/browsers.js
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,56 @@ | ||
import { playwrightLauncher } from '@web/test-runner-playwright'; | ||
import { createSauceLabsLauncher } from '@web/test-runner-saucelabs'; | ||
|
||
/** @type {(options: typeof import('../../helpers/options.js')) => import("@web/test-runner").BrowserLauncher[]} */ | ||
export function getBrowsers(options) { | ||
if (options.IS_CI) { | ||
if (!options.SAUCE_USERNAME || !options.SAUCE_ACCESS_KEY || !options.SAUCE_TUNNEL_ID) { | ||
throw new Error( | ||
`SAUCE_USERNAME, SAUCE_ACCESS_KEY, and SAUCE_TUNNEL_ID must be configured in CI` | ||
); | ||
} | ||
const sauceLabsLauncher = createSauceLabsLauncher( | ||
{ | ||
user: options.SAUCE_USERNAME, | ||
key: options.SAUCE_ACCESS_KEY, | ||
}, | ||
{ | ||
tunnelName: options.SAUCE_TUNNEL_ID, | ||
} | ||
); | ||
return [ | ||
sauceLabsLauncher({ | ||
browserName: 'chrome', | ||
browserVersion: 'latest', | ||
}), | ||
sauceLabsLauncher({ | ||
browserName: 'firefox', | ||
browserVersion: 'latest', | ||
}), | ||
sauceLabsLauncher({ | ||
browserName: 'safari', | ||
browserVersion: 'latest', | ||
platformName: 'macOS 15', // Update this with new Mac releases | ||
}), | ||
...(options.LEGACY_BROWSERS | ||
? [ | ||
sauceLabsLauncher({ | ||
browserName: 'chrome', | ||
browserVersion: 'latest-2', | ||
}), | ||
sauceLabsLauncher({ | ||
browserName: 'safari', | ||
browserVersion: 'latest-2', | ||
platformName: 'macOS 13', // Should be 2 behind latest | ||
}), | ||
] | ||
: []), | ||
]; | ||
} else { | ||
return [ | ||
playwrightLauncher({ product: 'chromium' }), | ||
playwrightLauncher({ product: 'firefox' }), | ||
playwrightLauncher({ product: 'webkit' }), | ||
]; | ||
} | ||
} |
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 |
---|---|---|
|
@@ -2091,9 +2091,11 @@ | |
|
||
"@lwc/eslint-plugin-lwc-internal@link:./scripts/eslint-plugin": | ||
version "0.0.0" | ||
uid "" | ||
|
||
"@lwc/test-utils-lwc-internals@link:./scripts/test-utils": | ||
version "0.0.0" | ||
uid "" | ||
|
||
"@napi-rs/[email protected]": | ||
version "0.2.4" | ||
|
@@ -4026,6 +4028,35 @@ | |
dependencies: | ||
"@web/test-runner-core" "^0.13.0" | ||
|
||
"@web/test-runner-playwright@^0.11.1": | ||
version "0.11.1" | ||
resolved "https://registry.yarnpkg.com/@web/test-runner-playwright/-/test-runner-playwright-0.11.1.tgz#d993112ae2126eb74c1c5a171d6ea44c2dd24b4e" | ||
integrity sha512-l9tmX0LtBqMaKAApS4WshpB87A/M8sOHZyfCobSGuYqnREgz5rqQpX314yx+4fwHXLLTa5N64mTrawsYkLjliw== | ||
dependencies: | ||
"@web/test-runner-core" "^0.13.0" | ||
"@web/test-runner-coverage-v8" "^0.8.0" | ||
playwright "^1.53.0" | ||
|
||
"@web/test-runner-saucelabs@^0.13.0": | ||
version "0.13.0" | ||
resolved "https://registry.yarnpkg.com/@web/test-runner-saucelabs/-/test-runner-saucelabs-0.13.0.tgz#66b50d4cf6ca29163e8c67e0d6a0b5863ac69172" | ||
integrity sha512-RHVDIFVaiOoxydigx1S4wrA20wjjLF9IAxlT7HxYHxO1qx1UIuWLabd6jEGlxluC0xFhuBJLm+zFj8zMEXJNyg== | ||
dependencies: | ||
"@web/test-runner-webdriver" "^0.9.0" | ||
internal-ip "^6.2.0" | ||
nanoid "^3.1.25" | ||
saucelabs "^9.0.0" | ||
webdriver "^9.0.0" | ||
webdriverio "^9.0.0" | ||
|
||
"@web/test-runner-webdriver@^0.9.0": | ||
version "0.9.0" | ||
resolved "https://registry.yarnpkg.com/@web/test-runner-webdriver/-/test-runner-webdriver-0.9.0.tgz#18fb3299ddc258a2782028de19f21ee4c27895c5" | ||
integrity sha512-G2io6ph0v/sX0U/DEgh/EUHsLsq8/Gs/uUw8N7rcUaXSdIFCUbxlwzx/qZv2ZKY52q84oYUyeOhViNZ2OqYl6Q== | ||
dependencies: | ||
"@web/test-runner-core" "^0.13.0" | ||
webdriverio "^9.0.0" | ||
|
||
"@web/test-runner@^0.20.2": | ||
version "0.20.2" | ||
resolved "https://registry.yarnpkg.com/@web/test-runner/-/test-runner-0.20.2.tgz#3045de8f14eb9f9b8aa51aa7fd9849dd95bb0a93" | ||
|
@@ -7605,6 +7636,11 @@ fs.realpath@^1.0.0: | |
resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" | ||
integrity sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw== | ||
|
||
[email protected]: | ||
version "2.3.2" | ||
resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.3.2.tgz#8a526f78b8fdf4623b709e0b975c52c24c02fd1a" | ||
integrity sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA== | ||
|
||
fsevents@~2.3.2, fsevents@~2.3.3: | ||
version "2.3.3" | ||
resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.3.3.tgz#cac6407785d03675a2a5e1a5305c697b347d90d6" | ||
|
@@ -11279,6 +11315,20 @@ pkg-up@^4.0.0: | |
dependencies: | ||
find-up "^6.2.0" | ||
|
||
[email protected]: | ||
version "1.56.0" | ||
resolved "https://registry.yarnpkg.com/playwright-core/-/playwright-core-1.56.0.tgz#14b40ea436551b0bcefe19c5bfb8d1804c83739c" | ||
integrity sha512-1SXl7pMfemAMSDn5rkPeZljxOCYAmQnYLBTExuh6E8USHXGSX3dx6lYZN/xPpTz1vimXmPA9CDnILvmJaB8aSQ== | ||
|
||
playwright@^1.53.0, playwright@^1.56.0: | ||
version "1.56.0" | ||
resolved "https://registry.yarnpkg.com/playwright/-/playwright-1.56.0.tgz#71c533c61da33e95812f8c6fa53960e073548d9a" | ||
integrity sha512-X5Q1b8lOdWIE4KAoHpW3SE8HvUB+ZZsUoN64ZhjnN8dOb1UpujxBtENGiZFE+9F/yhzJwYa+ca3u43FeLbboHA== | ||
dependencies: | ||
playwright-core "1.56.0" | ||
optionalDependencies: | ||
fsevents "2.3.2" | ||
|
||
portfinder@^1.0.32: | ||
version "1.0.37" | ||
resolved "https://registry.yarnpkg.com/portfinder/-/portfinder-1.0.37.tgz#92b754ef89a11801c8efe4b0e5cd845b0064c212" | ||
|
@@ -12132,7 +12182,7 @@ [email protected]: | |
tunnel "0.0.6" | ||
yargs "^17.0.1" | ||
|
||
saucelabs@^9.0.1: | ||
saucelabs@^9.0.0, saucelabs@^9.0.1: | ||
version "9.0.2" | ||
resolved "https://registry.yarnpkg.com/saucelabs/-/saucelabs-9.0.2.tgz#99f6170f3d789fcb0be2f270f7d37a9d7cdf5187" | ||
integrity sha512-37QGEOgp9BP1re6S06qpNcBZ0Hw+ZSkZkDepbXHT9VjYoRQwRzUoLtKqE4yyVeK7dzcQXQapmTGF1kp1jO2VDw== | ||
|
@@ -13856,7 +13906,7 @@ [email protected]: | |
ky "^0.30.0" | ||
lodash.merge "^4.6.1" | ||
|
||
[email protected]: | ||
[email protected], webdriver@^9.0.0: | ||
version "9.20.0" | ||
resolved "https://registry.yarnpkg.com/webdriver/-/webdriver-9.20.0.tgz#518fa61abd0b0435509548ef54fb0824f0fa04fd" | ||
integrity sha512-Kk+AGV1xWLNHVpzUynQJDULMzbcO3IjXo3s0BzfC30OpGxhpaNmoazMQodhtv0Lp242Mb1VYXD89dCb4oAHc4w== | ||
|
@@ -13906,7 +13956,7 @@ [email protected]: | |
serialize-error "^8.0.0" | ||
webdriver "7.19.5" | ||
|
||
[email protected], webdriverio@^9.19.2: | ||
[email protected], webdriverio@^9.0.0, webdriverio@^9.19.2: | ||
version "9.20.0" | ||
resolved "https://registry.yarnpkg.com/webdriverio/-/webdriverio-9.20.0.tgz#46f45268f2c4021a18045a7e7dfd738225514ece" | ||
integrity sha512-cqaXfahTzCFaQLlk++feZaze6tAsW8OSdaVRgmOGJRII1z2A4uh4YGHtusTpqOiZAST7OBPqycOwfh01G/Ktbg== | ||
|
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.
This is somewhat misleading, how much does things change in (2 versions prior to latest?) to call them legacy?
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.
It's a silly name, but it's what we did with the Karma tests.