Skip to content

Commit

Permalink
Update to latest bazel/rules_nodejs (#7347)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexeagle authored and shs96c committed Jul 1, 2019
1 parent 41730f6 commit ddf5d43
Show file tree
Hide file tree
Showing 6 changed files with 893 additions and 432 deletions.
6 changes: 6 additions & 0 deletions .bazelrc
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,9 @@ test --test_output=errors

# Need to be able to open sockets on localhost
test --noexperimental_sandbox_default_allow_network

# Turn on the "Managed Directories" feature.
# This allows Bazel to share the same node_modules directory with other tools
# NB: this option was introduced in Bazel 0.26
# See https://docs.bazel.build/versions/master/command-line-reference.html#flag--experimental_allow_incremental_repository_updates
common --experimental_allow_incremental_repository_updates
12 changes: 9 additions & 3 deletions WORKSPACE
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
workspace(name = "selenium")
workspace(
name = "selenium",
managed_directories = {
# Share the node_modules directory between Bazel and other tooling
"@npm": ["node_modules"],
}
)

load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")

Expand Down Expand Up @@ -98,8 +104,8 @@ dotnet_nuget_new(

http_archive(
name = "build_bazel_rules_nodejs",
sha256 = "4c702ffeeab2d24dd4101601b6d27cf582d2e0d4cdc3abefddd4834664669b6b",
urls = ["https://github.com/bazelbuild/rules_nodejs/releases/download/0.28.0/rules_nodejs-0.28.0.tar.gz"],
sha256 = "6d4edbf28ff6720aedf5f97f9b9a7679401bf7fca9d14a0fff80f644a99992b4",
urls = ["https://github.com/bazelbuild/rules_nodejs/releases/download/0.32.2/rules_nodejs-0.32.2.tar.gz"],
)

load("@build_bazel_rules_nodejs//:defs.bzl", "npm_install")
Expand Down
2 changes: 1 addition & 1 deletion javascript/node/selenium-webdriver/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ nodejs_binary(
"//javascript/node/selenium-webdriver/lib/atoms:get_attribute",
"//javascript/node/selenium-webdriver/lib/atoms:is_displayed",
],
entry_point = "selenium/javascript/node/selenium-webdriver/lib/test/fileserver.js",
entry_point = "lib/test/fileserver.ts",
)

jasmine_node_test(
Expand Down
2 changes: 1 addition & 1 deletion javascript/node/selenium-webdriver/lib/atoms/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ load("@build_bazel_rules_nodejs//:defs.bzl", "nodejs_binary")
nodejs_binary(
name = "make_atoms_module",
data = ["make-atoms-module.js"],
entry_point = "selenium/javascript/node/selenium-webdriver/lib/atoms/make-atoms-module",
entry_point = ":make-atoms-module.js",
)

# genrules used to copy closure_js_binary outputs to locations
Expand Down

0 comments on commit ddf5d43

Please sign in to comment.