Skip to content

Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.

devops: migrate from master to main branch (#10303)

Max Schmitt5ba7903ba098
diff --git a/.github/workflows/infra.yml b/.github/workflows/infra.yml
index fd67d4f521..420be3a1d9 100644
--- a/.github/workflows/infra.yml
+++ b/.github/workflows/infra.yml
@@ -3,11 +3,11 @@ name: "infra"
on:
push:
branches:
- - master
+ - main
- release-*
pull_request:
branches:
- - master
+ - main
- release-*
jobs:
diff --git a/.github/workflows/pr_check_client_side_changes.yml b/.github/workflows/pr_check_client_side_changes.yml
index 1cb5d49466..50f5d3fc4f 100644
--- a/.github/workflows/pr_check_client_side_changes.yml
+++ b/.github/workflows/pr_check_client_side_changes.yml
@@ -2,7 +2,7 @@ name: "Check client side changes"
on:
push:
branches:
- - master
+ - main
paths:
- 'packages/playwright-core/src/client/**/*'
jobs:
diff --git a/.github/workflows/publish_canary.yml b/.github/workflows/publish_canary.yml
index af49bae670..8c600295ae 100644
--- a/.github/workflows/publish_canary.yml
+++ b/.github/workflows/publish_canary.yml
@@ -24,14 +24,14 @@ jobs:
- run: npm run build
- run: npx playwright install-deps
- name: "@next: publish with commit timestamp (triggered manually)"
- if: contains(github.ref, 'master') && github.event_name == 'workflow_dispatch'
+ if: contains(github.ref, 'main') && github.event_name == 'workflow_dispatch'
run: |
node utils/build/update_canary_version.js --alpha --commit-timestamp
utils/publish_all_packages.sh --alpha
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: "@next: publish with today's date (triggered automatically)"
- if: contains(github.ref, 'master') && github.event_name != 'workflow_dispatch'
+ if: contains(github.ref, 'main') && github.event_name != 'workflow_dispatch'
run: |
node utils/build/update_canary_version.js --alpha --today-date
utils/publish_all_packages.sh --alpha
@@ -76,7 +76,7 @@ jobs:
- run: npm i -g npm@7
- name: Deploy Canary
run: bash utils/build/deploy-trace-viewer.sh --canary
- if: contains(github.ref, 'master')
+ if: contains(github.ref, 'main')
env:
GH_SERVICE_ACCOUNT_TOKEN: ${{ secrets.GH_SERVICE_ACCOUNT_TOKEN }}
- name: Deploy BETA
diff --git a/.github/workflows/roll_browser_into_playwright.yml b/.github/workflows/roll_browser_into_playwright.yml
index 5702179c3d..c043fc2e9a 100644
--- a/.github/workflows/roll_browser_into_playwright.yml
+++ b/.github/workflows/roll_browser_into_playwright.yml
@@ -41,6 +41,6 @@ jobs:
owner: 'microsoft',
repo: 'playwright',
head: 'microsoft:${{ steps.prepare-branch.outputs.BRANCH_NAME }}',
- base: 'master',
+ base: 'main',
title: 'feat(${{ github.event.client_payload.browser }}): roll to r${{ github.event.client_payload.revision }}',
});
diff --git a/.github/workflows/roll_chromium_build.yml b/.github/workflows/roll_chromium_build.yml
index 2f366ce713..3b4436abde 100644
--- a/.github/workflows/roll_chromium_build.yml
+++ b/.github/workflows/roll_chromium_build.yml
@@ -41,7 +41,7 @@ jobs:
owner: 'microsoft',
repo: 'playwright',
head: 'microsoft:${{ steps.prepare-branch.outputs.BRANCH_NAME }}',
- base: 'master',
+ base: 'main',
title: 'browser(chromium): roll to r${{ steps.bump-chromium.outputs.BASE_POSITION }}',
body: 'Upstream commit: https://github.com/chromium/chromium/commit/${{ steps.bump-chromium.outputs.GIT_COMMIT }}',
});
diff --git a/.github/workflows/tests_docker.yml b/.github/workflows/tests_docker.yml
index 0e745bba30..767605a6d2 100644
--- a/.github/workflows/tests_docker.yml
+++ b/.github/workflows/tests_docker.yml
@@ -3,7 +3,7 @@ name: "Docker tests"
on:
push:
branches:
- - master
+ - main
- release-*
pull_request:
paths:
@@ -12,7 +12,7 @@ on:
- 'browsers.json'
- 'package.json'
branches:
- - master
+ - main
- release-*
env:
diff --git a/.github/workflows/tests_fyi.yml b/.github/workflows/tests_fyi.yml
index 875e20bf2f..231cd0d04f 100644
--- a/.github/workflows/tests_fyi.yml
+++ b/.github/workflows/tests_fyi.yml
@@ -3,7 +3,7 @@ name: "tests 3"
on:
push:
branches:
- - master
+ - main
- release-*
env:
diff --git a/.github/workflows/tests_primary.yml b/.github/workflows/tests_primary.yml
index bb37892d5c..f5d8c9b65d 100644
--- a/.github/workflows/tests_primary.yml
+++ b/.github/workflows/tests_primary.yml
@@ -3,14 +3,14 @@ name: "tests 1"
on:
push:
branches:
- - master
+ - main
- release-*
pull_request:
paths-ignore:
- 'browser_patches/**'
- 'docs/**'
branches:
- - master
+ - main
- release-*
env:
diff --git a/.github/workflows/tests_secondary.yml b/.github/workflows/tests_secondary.yml
index 547f7f9f59..aed751b360 100644
--- a/.github/workflows/tests_secondary.yml
+++ b/.github/workflows/tests_secondary.yml
@@ -3,7 +3,7 @@ name: "tests 2"
on:
push:
branches:
- - master
+ - main
- release-*
pull_request:
paths-ignore:
@@ -11,7 +11,7 @@ on:
- 'docs/**'
types: [ labeled ]
branches:
- - master
+ - main
- release-*
env:
diff --git a/.github/workflows/trigger_build_chromium.yml b/.github/workflows/trigger_build_chromium.yml
index 0fec2b46f7..e2b2314624 100644
--- a/.github/workflows/trigger_build_chromium.yml
+++ b/.github/workflows/trigger_build_chromium.yml
@@ -6,10 +6,10 @@ on:
ref:
description: 'Playwright SHA / ref to build Chromium'
required: true
- default: 'master'
+ default: 'main'
push:
branches:
- - master
+ - main
- release-*
paths:
- browser_patches/chromium/BUILD_NUMBER
diff --git a/.github/workflows/trigger_build_chromium_with_symbols.yml b/.github/workflows/trigger_build_chromium_with_symbols.yml
index 3085303ed6..8fd161a5a7 100644
--- a/.github/workflows/trigger_build_chromium_with_symbols.yml
+++ b/.github/workflows/trigger_build_chromium_with_symbols.yml
@@ -7,7 +7,7 @@ on:
ref:
description: 'Playwright SHA / ref to build Chromium With Symbols'
required: true
- default: 'master'
+ default: 'main'
release:
types: [published]
push:
diff --git a/.github/workflows/trigger_build_deprecated_webkit_mac_10.14.yml b/.github/workflows/trigger_build_deprecated_webkit_mac_10.14.yml
index 5be83a97ee..68e280a105 100644
--- a/.github/workflows/trigger_build_deprecated_webkit_mac_10.14.yml
+++ b/.github/workflows/trigger_build_deprecated_webkit_mac_10.14.yml
@@ -3,7 +3,7 @@ name: "Deprecated WebKit Mac 10.14 Builder"
on:
push:
branches:
- - master
+ - main
- release-*
paths:
- browser_patches/depcrecated-webkit-mac-10.14/BUILD_NUMBER
diff --git a/.github/workflows/trigger_build_ffmpeg.yml b/.github/workflows/trigger_build_ffmpeg.yml
index 987b5f935e..6202c68a16 100644
--- a/.github/workflows/trigger_build_ffmpeg.yml
+++ b/.github/workflows/trigger_build_ffmpeg.yml
@@ -3,7 +3,7 @@ name: "FFMPEG Builder"
on:
push:
branches:
- - master
+ - main
- release-*
paths:
- browser_patches/ffmpeg/BUILD_NUMBER
diff --git a/.github/workflows/trigger_build_firefox.yml b/.github/workflows/trigger_build_firefox.yml
index bad8806c71..f0dc3b3daf 100644
--- a/.github/workflows/trigger_build_firefox.yml
+++ b/.github/workflows/trigger_build_firefox.yml
@@ -3,7 +3,7 @@ name: "Firefox Builder"
on:
push:
branches:
- - master
+ - main
- release-*
paths:
- browser_patches/firefox/BUILD_NUMBER
diff --git a/.github/workflows/trigger_build_firefox_beta.yml b/.github/workflows/trigger_build_firefox_beta.yml
index e3a08094fb..762dd95e18 100644
--- a/.github/workflows/trigger_build_firefox_beta.yml
+++ b/.github/workflows/trigger_build_firefox_beta.yml
@@ -3,7 +3,7 @@ name: "Firefox Beta Builder"
on:
push:
branches:
- - master
+ - main
- release-*
paths:
- browser_patches/firefox-beta/BUILD_NUMBER
diff --git a/.github/workflows/trigger_build_webkit.yml b/.github/workflows/trigger_build_webkit.yml
index 22e69c0ff8..3dd79da40c 100644
--- a/.github/workflows/trigger_build_webkit.yml
+++ b/.github/workflows/trigger_build_webkit.yml
@@ -3,7 +3,7 @@ name: "WebKit Builder"
on:
push:
branches:
- - master
+ - main
- release-*
paths:
- browser_patches/webkit/BUILD_NUMBER
diff --git a/.github/workflows/trigger_build_winldd.yml b/.github/workflows/trigger_build_winldd.yml
index 4d45987240..dfb2f4bfeb 100644
--- a/.github/workflows/trigger_build_winldd.yml
+++ b/.github/workflows/trigger_build_winldd.yml
@@ -3,7 +3,7 @@ name: "WinLDD Builder"
on:
push:
branches:
- - master
+ - main
- release-*
paths:
- browser_patches/winldd/BUILD_NUMBER
diff --git a/.github/workflows/trigger_tests.yml b/.github/workflows/trigger_tests.yml
index d130c40550..7267c843ba 100644
--- a/.github/workflows/trigger_tests.yml
+++ b/.github/workflows/trigger_tests.yml
@@ -3,7 +3,7 @@ name: "Internal Tests"
on:
push:
branches:
- - master
+ - main
- release-*
jobs:
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 14f63fa920..21e4a95568 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -51,7 +51,7 @@ information on using pull requests.
### Code Style
-- Coding style is fully defined in [.eslintrc](https://github.com/microsoft/playwright/blob/master/.eslintrc.js)
+- Coding style is fully defined in [.eslintrc](https://github.com/microsoft/playwright/blob/main/.eslintrc.js)
- Comments should be generally avoided. If the code would not be understood without comments, consider re-writing the code to make it self-explanatory.
To run code linter, use:
@@ -106,7 +106,7 @@ Fixes #123, fixes #234
### Writing Documentation
-All API classes, methods, and events should have a description in [`docs/src`](https://github.com/microsoft/playwright/blob/master/docs/src). There's a [documentation linter](https://github.com/microsoft/playwright/tree/master/utils/doclint) which makes sure documentation is aligned with the codebase.
+All API classes, methods, and events should have a description in [`docs/src`](https://github.com/microsoft/playwright/blob/main/docs/src). There's a [documentation linter](https://github.com/microsoft/playwright/tree/main/utils/doclint) which makes sure documentation is aligned with the codebase.
To run the documentation linter, use:
@@ -130,7 +130,7 @@ A barrier for introducing new installation dependencies is especially high:
- Tests should be *hermetic*. Tests should not depend on external services.
- Tests should work on all three platforms: Mac, Linux and Win. This is especially important for screenshot tests.
-Playwright tests are located in [`tests`](https://github.com/microsoft/playwright/blob/master/tests) and use `@playwright/test` test runner.
+Playwright tests are located in [`tests`](https://github.com/microsoft/playwright/blob/main/tests) and use `@playwright/test` test runner.
These are integration tests, making sure public API methods and events work as expected.
- To run all tests:
diff --git a/docs/development/releasing.md b/docs/development/releasing.md
index 61a031b430..945d0dcbd3 100644
--- a/docs/development/releasing.md
+++ b/docs/development/releasing.md
@@ -3,7 +3,7 @@ Releasing is a 3-step process.
# 1. Create a release branch
1. On your local machine, create a new branch `release-X.Y` based off the "cutting" commit and land a `chore: mark vX.Y.Z` in the local branch:
- - `git checkout master`
+ - `git checkout main`
- `git checkout -b release-X.Y`
- `./utils/update_version.js vX.Y`
- `npm run doc`
diff --git a/docs/src/ci.md b/docs/src/ci.md
index 115e9af842..0c16679e50 100644
--- a/docs/src/ci.md
+++ b/docs/src/ci.md
@@ -74,7 +74,7 @@ steps:
run: pytest
```
-We run [our tests](https://github.com/microsoft/playwright/blob/master/.github/workflows/tests_secondary.yml) on GitHub Actions, across a matrix of 3 platforms (Windows, Linux, macOS) and 3 browsers (Chromium, Firefox, WebKit).
+We run [our tests](https://github.com/microsoft/playwright/blob/main/.github/workflows/tests_secondary.yml) on GitHub Actions, across a matrix of 3 platforms (Windows, Linux, macOS) and 3 browsers (Chromium, Firefox, WebKit).
### GitHub Actions on deployment
diff --git a/docs/src/docker.md b/docs/src/docker.md
index 60311fe1fe..3383e32643 100644
--- a/docs/src/docker.md
+++ b/docs/src/docker.md
@@ -59,7 +59,7 @@ docker run -it --rm --ipc=host --user pwuser --security-opt seccomp=seccomp_prof
docker run -it --rm --ipc=host --user pwuser --security-opt seccomp=seccomp_profile.json mcr.microsoft.com/playwright/java:focal /bin/bash
```
-[`seccomp_profile.json`](https://github.com/microsoft/playwright/blob/master/utils/docker/seccomp_profile.json) is needed to run Chromium with sandbox. This is a [default Docker seccomp profile](https://github.com/docker/engine/blob/d0d99b04cf6e00ed3fc27e81fc3d94e7eda70af3/profiles/seccomp/default.json) with extra user namespace cloning permissions:
+[`seccomp_profile.json`](https://github.com/microsoft/playwright/blob/main/utils/docker/seccomp_profile.json) is needed to run Chromium with sandbox. This is a [default Docker seccomp profile](https://github.com/docker/engine/blob/d0d99b04cf6e00ed3fc27e81fc3d94e7eda70af3/profiles/seccomp/default.json) with extra user namespace cloning permissions:
```json
[
@@ -118,7 +118,7 @@ Browser builds for Firefox and WebKit are built for the [glibc](https://en.wikip
### Build the image
-Use [`//utils/docker/build.sh`](https://github.com/microsoft/playwright/blob/master/utils/docker/build.sh) to build the image.
+Use [`//utils/docker/build.sh`](https://github.com/microsoft/playwright/blob/main/utils/docker/build.sh) to build the image.
```
./utils/docker/build.sh focal playwright:localbuild-focal
diff --git a/docs/src/release-notes-js.md b/docs/src/release-notes-js.md
index 991ec6805f..b696686b32 100644
--- a/docs/src/release-notes-js.md
+++ b/docs/src/release-notes-js.md
@@ -409,7 +409,7 @@ Learn more in the [documentation](./test-advanced#launching-a-development-web-se
#### Playwright Test
-- **⚡️ Introducing [Reporter API](https://github.com/microsoft/playwright/blob/master/types/testReporter.d.ts)** which is already used to create an [Allure Playwright reporter](https://github.com/allure-framework/allure-js/pull/297).
+- **⚡️ Introducing [Reporter API](https://github.com/microsoft/playwright/blob/65a9037461ffc15d70cdc2055832a0c5512b227c/packages/playwright-test/types/testReporter.d.ts)** which is already used to create an [Allure Playwright reporter](https://github.com/allure-framework/allure-js/pull/297).
- **⛺️ New [`baseURL` fixture](./test-configuration#basic-options)** to support relative paths in tests.
diff --git a/packages/playwright-core/src/server/chromium/chromium.ts b/packages/playwright-core/src/server/chromium/chromium.ts
index 8dc285c4f2..ca5c251694 100644
--- a/packages/playwright-core/src/server/chromium/chromium.ts
+++ b/packages/playwright-core/src/server/chromium/chromium.ts
@@ -129,7 +129,7 @@ export class Chromium extends BrowserType {
`Chromium sandboxing failed!`,
`================================`,
`To workaround sandboxing issues, do either of the following:`,
- ` - (preferred): Configure environment to support sandboxing: https://github.com/microsoft/playwright/blob/master/docs/troubleshooting.md`,
+ ` - (preferred): Configure environment to support sandboxing: https://playwright.dev/docs/troubleshooting`,
` - (alternative): Launch Chromium without sandbox using 'chromiumSandbox: false' option`,
`================================`,
``,
diff --git a/utils/upload_flakiness_dashboard.sh b/utils/upload_flakiness_dashboard.sh
index caab4cfa37..caf6d6fee7 100755
--- a/utils/upload_flakiness_dashboard.sh
+++ b/utils/upload_flakiness_dashboard.sh
@@ -32,7 +32,7 @@ if [[ ("${GITHUB_REPOSITORY}" != "microsoft/playwright") && ("${GITHUB_REPOSITOR
exit 0
fi
-if [[ "${GITHUB_REF}" != "refs/heads/master" && "${GITHUB_REF}" != 'refs/heads/release-'* ]]; then
+if [[ "${GITHUB_REF}" != "refs/heads/main" && "${GITHUB_REF}" != 'refs/heads/release-'* ]]; then
echo "NOTE: skipping dashboard uploading from Playwright branches"
exit 0
fi