Skip to content

Commit c1c0560

Browse files
authored
feat: Add playwright_integrity_map rule (#12)
Fixes #11 This PR adds a rule which can generate an integrity map for a matrix of playwright browsers and platforms. This should help users who are using different versions of playwright than what are contained with KNOWN_BROWSER_INTEGRITY to more easily update their toolchain with the right key value pairs.
1 parent 6e76625 commit c1c0560

24 files changed

+1060
-108
lines changed

BUILD.bazel

Lines changed: 32 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
load("@bazel_skylib//rules:common_settings.bzl", "string_flag")
2-
load("//playwright:defs.bzl", "LINUX_DISTROS", "MACOS_VERSIONS")
2+
load("//playwright:defs.bzl", "LINUX_DISTROS", "MACOS_VERSIONS", "playwright_browser_matrix", "playwright_integrity_map")
33

44
package(default_visibility = ["//visibility:public"])
55

@@ -14,3 +14,34 @@ string_flag(
1414
build_setting_default = "ubuntu24.04",
1515
values = LINUX_DISTROS,
1616
)
17+
18+
playwright_integrity_map(
19+
name = "playwright_integrity_map_1.49.1",
20+
browsers = playwright_browser_matrix(
21+
browser_names = [
22+
"chromium-headless-shell",
23+
"chromium",
24+
],
25+
platforms = [
26+
"mac14-arm64",
27+
"ubuntu20.04-x64",
28+
],
29+
playright_repo_name = "playwright-1.49.1",
30+
),
31+
)
32+
33+
playwright_integrity_map(
34+
name = "playwright_integrity_map_1.50.1",
35+
browsers = playwright_browser_matrix(
36+
browser_names = [
37+
"chromium-headless-shell",
38+
"chromium",
39+
],
40+
platforms = [
41+
"mac14-arm64",
42+
"ubuntu20.04-x64",
43+
],
44+
playright_repo_name = "playwright-1.50.1",
45+
),
46+
silent = True,
47+
)

0 commit comments

Comments
 (0)