blob: 1d6ac5ddf32cf7ad56430b546a34d72a8eff7515 [file] [log] [blame]
Philipp Schrader175a93c2023-02-19 13:13:40 -08001load("@aspect_rules_cypress//cypress:defs.bzl", "cypress_module_test")
Philipp Schrader4e661d62022-03-13 22:15:56 -07002load("//tools/build_rules:apache.bzl", "apache_wrapper")
Philipp Schrader684a8e82022-02-25 17:39:28 -08003
4sh_binary(
5 name = "scouting",
6 srcs = [
7 "scouting.sh",
8 ],
9 data = [
Philipp Schrader684a8e82022-02-25 17:39:28 -080010 "//scouting/webserver",
Philipp Schrader577befe2022-03-15 00:00:49 -070011 "//scouting/www:static_files",
Philipp Schrader684a8e82022-02-25 17:39:28 -080012 ],
Philipp Schrader94305722022-03-13 12:59:21 -070013 visibility = ["//visibility:public"],
Philipp Schraderd41e27f2023-02-20 16:14:51 -080014 deps = [
15 "@bazel_tools//tools/bash/runfiles",
16 ],
Philipp Schrader684a8e82022-02-25 17:39:28 -080017)
18
Philipp Schrader175a93c2023-02-19 13:13:40 -080019cypress_module_test(
Philipp Schrader684a8e82022-02-25 17:39:28 -080020 name = "scouting_test",
Philipp Schrader175a93c2023-02-19 13:13:40 -080021 args = [
22 "run",
23 "--config-file=cypress.config.js",
24 "--browser=../../chrome_linux/chrome",
Philipp Schrader684a8e82022-02-25 17:39:28 -080025 ],
Philipp Schrader175a93c2023-02-19 13:13:40 -080026 browsers = ["@chrome_linux//:all"],
27 copy_data_to_bin = False,
28 cypress = "//:node_modules/cypress",
29 data = [
30 "cypress.config.js",
31 "scouting_test.cy.js",
32 "//scouting/testing:scouting_test_servers",
33 "@xvfb_amd64//:wrapped_bin/Xvfb",
34 ],
35 runner = "cypress_runner.js",
Philipp Schrader684a8e82022-02-25 17:39:28 -080036)
Philipp Schrader4e661d62022-03-13 22:15:56 -070037
38apache_wrapper(
39 name = "https",
40 binary = ":scouting",
41)