Skip to content

Commit

Permalink
chore: bump @playwright/test from 1.42.1 to 1.49.0 (#4836) (#4944)
Browse files Browse the repository at this point in the history
* chore: bump @playwright/test from 1.42.1 to 1.49.0

Bumps [@playwright/test](https://github.com/microsoft/playwright) from 1.42.1 to 1.49.0.
- [Release notes](https://github.com/microsoft/playwright/releases)
- [Commits](microsoft/playwright@v1.42.1...v1.49.0)

---
updated-dependencies:
- dependency-name: "@playwright/test"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* docs: retrigger build

* chore: use new headless chrome

* chore: remove security bulletins and reduce verbose output

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Carolina Delwing Rosa <carolina.delwing@spectrocloud.com>
Co-authored-by: Karl Cardenas <karl@spectrocloud.com>
Co-authored-by: Karl Cardenas <29551334+karl-cardenas-coding@users.noreply.github.com>
(cherry picked from commit 30b4054)

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
  • Loading branch information
1 parent 0c8e95d commit 100e3f6
Show file tree
Hide file tree
Showing 5 changed files with 43 additions and 19 deletions.
27 changes: 18 additions & 9 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@
"devDependencies": {
"@argos-ci/cli": "^2.4.2",
"@argos-ci/playwright": "^2.0.0",
"@playwright/test": "^1.42.1",
"@playwright/test": "^1.49.0",
"@semantic-release/changelog": "^6.0.1",
"@semantic-release/exec": "^6.0.3",
"@semantic-release/git": "latest",
Expand Down
11 changes: 10 additions & 1 deletion playwright.config.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { PlaywrightTestConfig } from "@playwright/test";
import { devices } from "@playwright/test";
import type { PlaywrightTestConfig } from "@playwright/test";

const config: PlaywrightTestConfig = {
snapshotDir: "screenshots/",
Expand All @@ -20,6 +21,14 @@ const config: PlaywrightTestConfig = {
url: "http://127.0.0.1:3000",
reuseExistingServer: !process.env.CI,
},
projects: [
{
name: "chromium",
use: {
...devices["Desktop Chrome"],
},
},
],
};

export default config;
2 changes: 1 addition & 1 deletion visuals/exclude.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
["/integrations/"]
["/integrations/*", "/security-bulletins/reports/*"]
20 changes: 13 additions & 7 deletions visuals/screenshot.docs.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,23 +11,29 @@ const stylesheet = fs.readFileSync(stylesheetPath).toString();
test.describe.configure({ mode: "parallel" });

function isVersionedDocsPathname(pathname: string, excludeList: string[]): boolean {
if (excludeList.some((excludedPath) => pathname === excludedPath || pathname.startsWith(excludedPath))) {
console.log(`Excluding ${pathname} because it matches or starts with an exclude list pattern`);
if (
excludeList.some((excludedPath) => {
if (excludedPath.endsWith("/*")) {
// Let's remove the trailing "/*" to match sub-paths
const basePath = excludedPath.slice(0, -2);
// Exclude sub-paths only, not the index page
return pathname.startsWith(basePath) && pathname !== `${basePath}/`;
}
// This is an exact match
return pathname === excludedPath;
})
) {
return false;
}

// Additional exclusion criteria
if (pathname.startsWith("/api/") || pathname.match(/\/\d+\.\d+\.x\//)) {
return false;
}

return true;
}

test.beforeAll(() => {
console.log("Excluded pages: ", excludeList);
console.log("Total pages: ", extractSitemapPathnames(sitemapPath).length);
});

function screenshotPathname(pathname: string) {
test(`pathname ${pathname}`, async ({ page }) => {
console.log(`Taking screenshot of ${pathname}`);
Expand Down

0 comments on commit 100e3f6

Please sign in to comment.