tix/test/watch.test.nix
2024-01-03 07:37:49 +00:00

20 lines
374 B
Nix

{
describe,
it,
...
}: let
mockpkgs = {
writeShellScriptBin = name: content: content;
inotify-tools = "inotify-tools";
};
watch = import ../tix/watch.nix mockpkgs;
in
describe "watch" [
(it "contains the command" {
actual = builtins.match ".*(run me).*" ( watch {
cmd = "run me";
} );
expected = ["run me"];
})
]