rules_closure
rules_closure copied to clipboard
When tests are compiled, sourceMappingUrl is not added to the resulting _bin.js file
When I invoke closure_js_test like so:
closure_js_test(
name = "sometest",
entry_points = ...,
srcs = ...,
deps = ...,
language = "ECMASCRIPT6_STRICT",
defs = [
"--jscomp_error=*",
"--jscomp_off=analyzerChecks",
"--dependency_mode=LOOSE"
],
)
the resulting _bin.js file doesn't contain
//# sourceMappingURL=sometest_bin.js.map
which would allow browsers to use the source map.
Another very related issue is that the sourcemaps are generated with a / -> / base map, despite the phantomjs server actually serving from the runfiles directory, which requires file paths to be prepended with __main__
. It would be neat to resolve this ambiguity between the source map and the actual test harness.