anki/ts/BUILD.bazel
Damien Elmes c891f45ed9 add Jest for TS unit tests
@hgiesel the reason no files were being found is because Jest ignores
symlinks by default. The Bazel example includes a patch we can use
to work around it, and Jest plan to add symlink support in a future
update.

https://github.com/bazelbuild/rules_nodejs/blob/stable/examples/jest/patches/jest-haste-map%2B24.9.0.patch

https://github.com/facebook/jest/pull/9351
2021-03-28 19:41:20 +10:00

34 lines
522 B
Python

load("//ts:prettier.bzl", "prettier", "prettier_test")
load("//ts:sql_format.bzl", "sql_format_setup")
prettier()
prettier_test(
name = "format_check",
srcs = glob([
"*.ts",
"*.js",
]),
)
sql_format_setup()
# Exported files
#################
exports_files([
"tsconfig.json",
".prettierrc",
".eslintrc.js",
"licenses.json",
"sql_format.ts",
"protobuf-shim.js",
"jest.config.js",
"package.json",
])
alias(
name = "yarn",
actual = "@nodejs//:yarn",
)