blob: 8da14007e7aa6e7317c967fd79cf4dcf2f386e3b [file] [log] [blame]
Philipp Schrader4e661d62022-03-13 22:15:56 -07001load("//tools/build_rules:apache.bzl", "apache_wrapper")
Philipp Schrader155e76c2023-02-25 18:42:31 -08002load("//tools/build_rules:js.bzl", "cypress_test")
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 ],
Austin Schuhf737d472023-07-29 17:35:59 -070013 tags = [
14 "no-remote-cache",
15 ],
Philipp Schrader94305722022-03-13 12:59:21 -070016 visibility = ["//visibility:public"],
Philipp Schraderd41e27f2023-02-20 16:14:51 -080017 deps = [
18 "@bazel_tools//tools/bash/runfiles",
19 ],
Philipp Schrader684a8e82022-02-25 17:39:28 -080020)
21
Philipp Schrader23768c82023-07-01 14:37:28 -070022# TODO(philipp): Sandbox the following:
23# - libnss3
24# - libdrm2
25# - libgbm1
26# - x11-xkb-utils (See TODO in scouting/scouting_test_runner.js)
Philipp Schrader155e76c2023-02-25 18:42:31 -080027cypress_test(
Philipp Schrader684a8e82022-02-25 17:39:28 -080028 name = "scouting_test",
Philipp Schrader175a93c2023-02-19 13:13:40 -080029 data = [
Philipp Schrader175a93c2023-02-19 13:13:40 -080030 "scouting_test.cy.js",
Emily Markova8e39f452023-12-23 12:17:30 -080031 "test_img_1.png",
32 "test_img_2.png",
Philipp Schrader175a93c2023-02-19 13:13:40 -080033 "//scouting/testing:scouting_test_servers",
Philipp Schrader175a93c2023-02-19 13:13:40 -080034 ],
Philipp Schrader25c10e42023-02-26 14:57:07 -080035 runner = "scouting_test_runner.js",
Austin Schuhf737d472023-07-29 17:35:59 -070036 tags = [
37 "no-remote-cache",
38 ],
Philipp Schrader684a8e82022-02-25 17:39:28 -080039)
Philipp Schrader4e661d62022-03-13 22:15:56 -070040
Philipp Schradere2e27ff2024-02-25 22:08:55 -080041# The QR code test is separate from scouting_test because it's slow. Most of
42# the time folks will want to iterate on `scouting_test`.
43cypress_test(
44 name = "scouting_qrcode_test",
45 size = "large",
46 data = [
47 "scouting_qrcode_test.cy.js",
48 "//scouting/testing:scouting_test_servers",
49 "//scouting/testing/camera_simulator",
50 ],
51 runner = "scouting_test_runner.js",
52 tags = [
Austin Schuh869bf092024-04-13 17:45:12 -070053 # This test fails for some reason when run on remote execution. It
54 # would be great to figure out why and fix it.
55 "no-remote",
Philipp Schradere2e27ff2024-02-25 22:08:55 -080056 ],
57)
58
Philipp Schrader4e661d62022-03-13 22:15:56 -070059apache_wrapper(
60 name = "https",
61 binary = ":scouting",
62)