diff options
author | 2023-01-09 08:28:37 -0800 | |
---|---|---|
committer | 2023-01-09 08:28:37 -0800 | |
commit | 30b10d5fb1aeb94c7c19bb8d8d732f61202609cd (patch) | |
tree | 4ffbf066213e6afd2f560e1fab98b1f14b7a2168 /src/bunfig.zig | |
parent | ca58556c541e3dd7f8f5c51350c85bbd3e11eed8 (diff) | |
download | bun-30b10d5fb1aeb94c7c19bb8d8d732f61202609cd.tar.gz bun-30b10d5fb1aeb94c7c19bb8d8d732f61202609cd.tar.zst bun-30b10d5fb1aeb94c7c19bb8d8d732f61202609cd.zip |
[bun:test] Implement `test.root` configuration option
Diffstat (limited to 'src/bunfig.zig')
-rw-r--r-- | src/bunfig.zig | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/bunfig.zig b/src/bunfig.zig index f840c7c58..10a35edd4 100644 --- a/src/bunfig.zig +++ b/src/bunfig.zig @@ -191,6 +191,14 @@ pub const Bunfig = struct { } } + if (comptime cmd == .TestCommand) { + if (json.get("test")) |test_| { + if (test_.get("root")) |root| { + this.ctx.debug.test_directory = root.asString(this.allocator) orelse ""; + } + } + } + if (comptime cmd.isNPMRelated() or cmd == .RunCommand or cmd == .AutoCommand) { if (json.get("install")) |_bun| { var install: *Api.BunInstall = this.ctx.install orelse brk: { |