mirror of
https://github.com/angular/angular.git
synced 2026-09-14 13:54:52 +08:00
build: mark all e2e test suites as flaky within bazel (#16376)
Marks all e2e test suites as flaky with Bazel's `flaky` rule attribute. This should improve CI stability as e2e tests can sometimes fail due to browser crashes, port collisions.
This commit is contained in:
committed by
Andrew Seguin
parent
760058a5c5
commit
a5f8ee9b09
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module", "ng_test_library", "ng_web_test_suite")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module", "ng_test_library", "ng_web_test_suite", "protractor_web_test_suite")
|
||||
|
||||
ng_module(
|
||||
name = "scrolling",
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("//tools:defaults.bzl", "ng_module", "ng_web_test_suite")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load("//tools:defaults.bzl", "ng_module", "ng_web_test_suite", "protractor_web_test_suite")
|
||||
|
||||
ng_module(
|
||||
name = "testing",
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module", "protractor_web_test_suite")
|
||||
|
||||
ng_module(
|
||||
name = "mdc-button",
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module", "protractor_web_test_suite")
|
||||
|
||||
ng_module(
|
||||
name = "mdc-card",
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module", "ng_test_library", "ng_web_test_suite", "ts_library")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module", "ng_test_library", "ng_web_test_suite", "protractor_web_test_suite", "ts_library")
|
||||
|
||||
ng_module(
|
||||
name = "mdc-checkbox",
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module", "protractor_web_test_suite")
|
||||
|
||||
ng_module(
|
||||
name = "mdc-chips",
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module", "ng_test_library", "ng_web_test_suite")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module", "ng_test_library", "ng_web_test_suite", "protractor_web_test_suite")
|
||||
|
||||
ng_module(
|
||||
name = "mdc-menu",
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module", "protractor_web_test_suite")
|
||||
|
||||
ng_module(
|
||||
name = "mdc-radio",
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module", "ng_test_library", "ng_web_test_suite")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module", "ng_test_library", "ng_web_test_suite", "protractor_web_test_suite")
|
||||
|
||||
ng_module(
|
||||
name = "mdc-slide-toggle",
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module")
|
||||
load("//tools:defaults.bzl", "ng_e2e_test_library", "ng_module", "protractor_web_test_suite")
|
||||
|
||||
ng_module(
|
||||
name = "mdc-tabs",
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load("//tools:defaults.bzl", "markdown_to_html", "ng_e2e_test_library", "ng_module")
|
||||
load("//tools:defaults.bzl", "markdown_to_html", "ng_e2e_test_library", "ng_module", "protractor_web_test_suite")
|
||||
|
||||
ng_module(
|
||||
name = "card",
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load("@io_bazel_rules_sass//:defs.bzl", "sass_binary", "sass_library")
|
||||
load("@npm_angular_bazel//:index.bzl", "protractor_web_test_suite")
|
||||
load(
|
||||
"//tools:defaults.bzl",
|
||||
"markdown_to_html",
|
||||
@@ -9,6 +8,7 @@ load(
|
||||
"ng_module",
|
||||
"ng_test_library",
|
||||
"ng_web_test_suite",
|
||||
"protractor_web_test_suite",
|
||||
)
|
||||
|
||||
ng_module(
|
||||
|
||||
+10
-1
@@ -1,6 +1,6 @@
|
||||
# Re-export of Bazel rules with repository-wide defaults
|
||||
|
||||
load("@npm_angular_bazel//:index.bzl", _ng_module = "ng_module", _ng_package = "ng_package")
|
||||
load("@npm_angular_bazel//:index.bzl", _ng_module = "ng_module", _ng_package = "ng_package", _protractor_web_test_suite = "protractor_web_test_suite")
|
||||
load("@npm_bazel_jasmine//:index.bzl", _jasmine_node_test = "jasmine_node_test")
|
||||
load("@npm_bazel_typescript//:defs.bzl", _ts_library = "ts_library")
|
||||
load("@npm_bazel_karma//:defs.bzl", _ts_web_test_suite = "ts_web_test_suite")
|
||||
@@ -122,6 +122,15 @@ def ts_web_test_suite(deps = [], srcs = [], **kwargs):
|
||||
**kwargs
|
||||
)
|
||||
|
||||
# Protractor web test targets are flaky by default as the browser can sometimes
|
||||
# crash (e.g. due to too much concurrency). Passing the "flaky" flag ensures that
|
||||
# Bazel detects flaky tests and re-runs these a second time in case of a flake.
|
||||
def protractor_web_test_suite(flaky = True, **kwargs):
|
||||
_protractor_web_test_suite(
|
||||
flaky = flaky,
|
||||
**kwargs
|
||||
)
|
||||
|
||||
def ng_web_test_suite(deps = [], static_css = [], bootstrap = [], **kwargs):
|
||||
# Always include a prebuilt theme in the test suite because otherwise tests, which depend on CSS
|
||||
# that is needed for measuring, will unexpectedly fail. Also always adding a prebuilt theme
|
||||
|
||||
Reference in New Issue
Block a user