#How to capture bun test output

1 messages · Page 1 of 1 (latest)

round timber
#

Piping bun test to a file when calling it via Bun.spawn() and having a lot of trouble getting it out of my terminal and into a file. Can anyone offer insight on that or point me to a resource for documentation please? It seems to just skip the tests entirely when I try to utilize the shell to redirect the output

arctic ether
#

🙂

#
const { stderr } = Bun.spawnSync(["bun", "test"]);
Bun.write("test_result.txt", stderr.toString());
round timber
#

Oh my. You’re amazing. Thank you so much!!! @arctic ether