Skip to content

Commit

Permalink
[build] Add Bazel bidi flag (SeleniumHQ#14083)
Browse files Browse the repository at this point in the history
* [build] implement bazel targets for running ruby tests with BiDi

* add necessary bidi targets to skipped-tests for rbe
  • Loading branch information
titusfortner authored and sandeepsuryaprasad committed Oct 29, 2024
1 parent bd4f019 commit a9c64fc
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
6 changes: 6 additions & 0 deletions .skipped-tests
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,9 @@
-//rb/spec/integration/selenium/webdriver/firefox:service-firefox-beta
-//rb/spec/integration/selenium/webdriver:element-chrome
-//rb/spec/integration/selenium/webdriver/firefox:driver-firefox-beta
-//rb/spec/integration/selenium/webdriver/chrome:service-chrome-bidi
-//rb/spec/integration/selenium/webdriver/edge:service-edge-bidi
-//rb/spec/integration/selenium/webdriver/firefox:service-firefox-bidi
-//rb/spec/integration/selenium/webdriver/firefox:service-firefox-beta-bidi
-//rb/spec/integration/selenium/webdriver:element-chrome-bidi
-//rb/spec/integration/selenium/webdriver/firefox:driver-firefox-beta-bidi
15 changes: 15 additions & 0 deletions rb/spec/tests.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,21 @@ def rb_integration_test(name, srcs, deps = [], data = [], browsers = BROWSERS.ke
target_compatible_with = BROWSERS[browser]["target_compatible_with"],
)

# Generate a test target for bidi browser execution.
rb_test(
name = "{}-{}-bidi".format(name, browser),
size = "large",
srcs = srcs,
args = ["rb/spec/"],
data = BROWSERS[browser]["data"] + data + ["//common/src/web"],
env = BROWSERS[browser]["env"] | {"WEBDRIVER_BIDI": "true"},
main = "@bundle//bin:rspec",
tags = COMMON_TAGS + BROWSERS[browser]["tags"] + tags + ["{}-bidi".format(browser)],
deps = ["//rb/spec/integration/selenium/webdriver:spec_helper"] + BROWSERS[browser]["deps"] + deps,
visibility = ["//rb:__subpackages__"],
target_compatible_with = BROWSERS[browser]["target_compatible_with"],
)

def rb_unit_test(name, srcs, deps, data = []):
rb_test(
name = name,
Expand Down

0 comments on commit a9c64fc

Please sign in to comment.