Arxcis / adventofcode2020

Community-project solving https://adventofcode.com/ - problems, with Github CI, Docker and support for many languages.
6 stars 8 forks source link

Zigday01 #140

Closed Avokadoen closed 2 years ago

Avokadoen commented 2 years ago

Love it. The testing in zig looks very chill. How do you run the tests? What does the command look like?

for single files you can run zig test *file* :)

but usually you use build scripts to set up your testbed and bind it to zig build test

Example: https://github.com/ziglang/zig/blob/77836e08a2384450b5e7933094511b61e3c22140/build.zig#L415