blob: 49c17287c386a7685a7a77625058df655d75a507 [file] [log] [blame]
Eugene Kliuchnikova6292892017-08-28 11:31:29 +02001package(
2 default_visibility = ["//visibility:public"],
3)
4
5licenses(["notice"]) # MIT
6
7load("@io_bazel_rules_closure//closure:defs.bzl", "closure_js_library")
8
9# Not a real polyfill. Do NOT use for anything, but tests.
10closure_js_library(
11 name = "polyfill",
12 srcs = ["polyfill.js"],
Tianjie Xua5dcb7c2018-09-25 12:25:15 -070013 suppress = [
14 "JSC_INVALID_OPERAND_TYPE",
15 "JSC_MISSING_JSDOC",
16 "JSC_STRICT_INEXISTENT_PROPERTY",
17 "JSC_TYPE_MISMATCH",
18 "JSC_UNKNOWN_EXPR_TYPE",
19 ],
Eugene Kliuchnikova6292892017-08-28 11:31:29 +020020)
21
22# Do NOT use this artifact; it is for test purposes only.
23closure_js_library(
24 name = "decode",
25 srcs = ["decode.js"],
Tianjie Xua5dcb7c2018-09-25 12:25:15 -070026 suppress = [
27 "JSC_DUP_VAR_DECLARATION",
28 "JSC_USELESS_BLOCK",
29 ],
Eugene Kliuchnikova6292892017-08-28 11:31:29 +020030 deps = [":polyfill"],
31)
32
33load("@io_bazel_rules_closure//closure:defs.bzl", "closure_js_test")
34
35closure_js_test(
36 name = "all_tests",
37 srcs = ["decode_test.js"],
Eugene Kliuchnikova6292892017-08-28 11:31:29 +020038 deps = [
39 ":decode",
40 ":polyfill",
41 "@io_bazel_rules_closure//closure/library:testing",
42 ],
43)