Skip to content

Commit

Permalink
webkit system tests
Browse files Browse the repository at this point in the history
  • Loading branch information
flotwig committed Aug 30, 2022
1 parent e41dd70 commit 9ececdb
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 8 deletions.
34 changes: 29 additions & 5 deletions circle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,14 @@ commands:
mv ~/cypress/system-tests/node_modules /tmp/node_modules_cache/system-tests_node_modules
mv ~/cypress/globbed_node_modules /tmp/node_modules_cache/globbed_node_modules
install-webkit-deps:
steps:
- run:
name: Install WebKit dependencies
command: |
npx playwright install webkit
npx playwright install-deps webkit
build-and-persist:
description: Save entire folder as artifact for other jobs to run without reinstalling
steps:
Expand Down Expand Up @@ -462,6 +470,11 @@ commands:
- install-chrome:
channel: <<parameters.install-chrome-channel>>
version: $(node ./scripts/get-browser-version.js chrome:<<parameters.install-chrome-channel>>)
- when:
condition:
equal: [ webkit, << parameters.browser >> ]
steps:
- install-webkit-deps
- run:
name: Run driver tests in Cypress
environment:
Expand All @@ -470,11 +483,6 @@ commands:
echo Current working directory is $PWD
echo Total containers $CIRCLE_NODE_TOTAL
if [[ "<<parameters.browser>>" = "webkit" ]]; then
npx playwright install webkit
npx playwright install-deps webkit
fi
if [[ -v MAIN_RECORD_KEY ]]; then
# internal PR
if <<parameters.experimentalSessionAndOrigin>>; then
Expand Down Expand Up @@ -610,6 +618,11 @@ commands:
steps:
- restore_cached_workspace
- restore_cached_system_tests_deps
- when:
condition:
equal: [ webkit, << parameters.browser >> ]
steps:
- install-webkit-deps
- run:
name: Run system tests
command: |
Expand Down Expand Up @@ -1448,6 +1461,13 @@ jobs:
- run-system-tests:
browser: firefox

system-tests-webkit:
<<: *defaults
parallelism: 8
steps:
- run-system-tests:
browser: webkit

system-tests-non-root:
<<: *defaults
steps:
Expand Down Expand Up @@ -2363,6 +2383,10 @@ linux-x64-workflow: &linux-x64-workflow
context: test-runner:performance-tracking
requires:
- system-tests-node-modules-install
- system-tests-webkit:
context: test-runner:performance-tracking
requires:
- system-tests-node-modules-install
- system-tests-non-root:
context: test-runner:performance-tracking
executor: non-root-docker-user
Expand Down
1 change: 1 addition & 0 deletions system-tests/lib/dep-installer/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -291,6 +291,7 @@ export async function scaffoldCommonNodeModules () {
'jimp',
'lazy-ass',
'lodash',
'playwright-webkit',
'proxyquire',
'semver',
'systeminformation',
Expand Down
2 changes: 1 addition & 1 deletion system-tests/lib/normalizeStdout.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import _ from 'lodash'

export const e2ePath = Fixtures.projectPath('e2e')

export const DEFAULT_BROWSERS = ['electron', 'chrome', 'firefox']
export const DEFAULT_BROWSERS = ['electron', 'chrome', 'firefox', 'webkit']

export const pathUpToProjectName = Fixtures.projectPath('')

Expand Down
4 changes: 2 additions & 2 deletions system-tests/lib/system-tests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ require(`@packages/server/lib/project-base`)

type CypressConfig = { [key: string]: any }

export type BrowserName = 'electron' | 'firefox' | 'chrome'
| '!electron' | '!chrome' | '!firefox'
export type BrowserName = 'electron' | 'firefox' | 'chrome' | 'webkit'
| '!electron' | '!chrome' | '!firefox' | '!webkit'

type ExecResult = {
code: number
Expand Down

0 comments on commit 9ececdb

Please sign in to comment.