summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2009-01-31 17:43:56 -0800
committerJunio C Hamano <gitster@pobox.com>2009-01-31 17:43:56 -0800
commitfa5bc8abb35e34f673c41cb5c66d0a2f21536861 (patch)
treee76e7f9d8d64db34f148f7ddfa6bca928c194d65 /t
parent2edefe38a813deb4dfbd62dcf47520aeb1af15fc (diff)
parent0ea8039644968e53d79a8dfbf739c87af4261d46 (diff)
downloadgit-fa5bc8abb35e34f673c41cb5c66d0a2f21536861.tar.gz
Merge branch 'jk/signal-cleanup'
* jk/signal-cleanup: t0005: use SIGTERM for sigchain test pager: do wait_for_pager on signal death refactor signal handling for cleanup functions chain kill signals for cleanup functions diff: refactor tempfile cleanup handling Windows: Fix signal numbers
Diffstat (limited to 't')
-rwxr-xr-xt/t0005-signals.sh22
1 files changed, 22 insertions, 0 deletions
diff --git a/t/t0005-signals.sh b/t/t0005-signals.sh
new file mode 100755
index 0000000000..09f855af3e
--- /dev/null
+++ b/t/t0005-signals.sh
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+test_description='signals work as we expect'
+. ./test-lib.sh
+
+cat >expect <<EOF
+three
+two
+one
+EOF
+
+test_expect_success 'sigchain works' '
+ test-sigchain >actual
+ case "$?" in
+ 143) true ;; # POSIX w/ SIGTERM=15
+ 3) true ;; # Windows
+ *) false ;;
+ esac &&
+ test_cmp expect actual
+'
+
+test_done