diff --git a/examples/out_dir/BUILD.bazel b/examples/out_dir/BUILD.bazel index 4e7793d1..01e1c538 100644 --- a/examples/out_dir/BUILD.bazel +++ b/examples/out_dir/BUILD.bazel @@ -1,4 +1,5 @@ load("@aspect_rules_ts//ts:defs.bzl", "ts_project") +load("@bazel_skylib//rules:build_test.bzl", "build_test") ts_project( name = "out_dir-tsconfig", @@ -30,3 +31,26 @@ ts_project( out_dir = "declaration_dir", tsconfig = {}, ) + +build_test( + name = "test", + targets = [ + # outputs specified by the tsconfig attr + ":out_dir-tsconfig", + "tsconfig/main.js", + "tsconfig/main.d.ts", + "tsconfig/main.d.ts.map", + + # outputs specified by the ts_project attrs + ":out_dir-params", + "param/main.js", + "param/main.d.ts", + "param/main.d.ts.map", + + # outptus specified with out_dir *and* declaration_dir + ":out_dir-declaration_dir", + "declaration_dir/main.js", + "decl_map/main.d.ts", + "decl_map/main.d.ts.map", + ], +)