Add bats test suite
Black-box tests that run the script with stub commands on a minimal PATH and temp config/state folders.
This commit is contained in:
Executable
+8
@@ -0,0 +1,8 @@
|
||||
#!/bin/bash
|
||||
# "pacdiff -o": prints $STUB_DATA/pacdiff.
|
||||
printf '%s %s\n' "${0##*/}" "$*" >> "$STUB_DATA/calls"
|
||||
[[ ${1:-} == -o ]] || exit 1
|
||||
if [[ -s $STUB_DATA/pacdiff ]]; then
|
||||
printf '%s\n' "$(<"$STUB_DATA/pacdiff")"
|
||||
fi
|
||||
exit 0
|
||||
Reference in New Issue
Block a user