To test my CLI I want to run the following commands in this order:
cli startcli scancli import input.csvcli scancli export output.csv
This modifies files in the work tree, notably creating a binary blob that I don’t want. Currently I run rm -rf binaryblob.
Doing everything in a temporary directory wasn’t my first thought as I am already testing the output code (from cli import) using the snapshot testing Loris Cro put forth in this blog post: Dead Simple Snapshot Testing In Zig | Loris Cro's Blog
Current solution is a dependOn chain but that doesn’t work correctly with the cache and transisitive failures don’t trigger rm -rf.
How should I test this?