3 # This -*- sh -*- script tests whether 'guild compile' leaves traces
4 # behind it upon SIGINT.
6 source="t-guild-compile-$$"
9 trap 'rm -f "$source" "$target"' EXIT
12 (eval-when (expand load eval)
17 guild compile
-o "$target" "$source" &
21 sleep 2 && kill -INT "$pid"
23 # Wait for 'guild compile' to terminate.
26 # Check whether there are any leftovers.
27 for file in "$target"*
29 if test "$file" != "${target}*"
31 echo "error: 'guild compile' failed to remove '$file'" >&2
40 echo "error: '$target' produced" >&2