aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdam Spiers <git@adamspiers.org>2013-04-11 03:07:04 +0100
committerJunio C Hamano <gitster@pobox.com>2013-04-11 17:39:05 -0700
commit200732744a32a378b636da4d840aeb410adfb2ad (patch)
tree7df5246baec1a40081fb61486c65d1a975ed4785
parent59a7714c8909f1a925a7faa4f3015f015c087ee5 (diff)
downloadgit-200732744a32a378b636da4d840aeb410adfb2ad.tar.gz
git-200732744a32a378b636da4d840aeb410adfb2ad.tar.xz
t: make PIPE a standard test prerequisite
The 'PIPE' test prerequisite was already defined identically by t9010 and t9300, therefore it makes sense to make it a predefined prerequisite. Signed-off-by: Adam Spiers <git@adamspiers.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rw-r--r--t/README5
-rwxr-xr-xt/t9010-svn-fe.sh8
-rwxr-xr-xt/t9300-fast-import.sh8
-rw-r--r--t/test-lib.sh5
4 files changed, 10 insertions, 16 deletions
diff --git a/t/README b/t/README
index 6e536a02b..f8bf3ec31 100644
--- a/t/README
+++ b/t/README
@@ -613,6 +613,11 @@ use these, and "test_set_prereq" for how to define your own.
The process retains the same pid across exec(2). See fb9a2bea for
details.
+ - PIPE
+
+ The filesystem we're on supports creation of FIFOs (named pipes)
+ via mkfifo(1).
+
- SYMLINKS
The filesystem we're on supports symbolic links. E.g. a FAT
diff --git a/t/t9010-svn-fe.sh b/t/t9010-svn-fe.sh
index b7eed2489..6dafe7e99 100755
--- a/t/t9010-svn-fe.sh
+++ b/t/t9010-svn-fe.sh
@@ -54,14 +54,6 @@ text_no_props () {
>empty
-test_expect_success 'setup: have pipes?' '
- rm -f frob &&
- if mkfifo frob
- then
- test_set_prereq PIPE
- fi
-'
-
test_expect_success PIPE 'empty dump' '
reinit_git &&
echo "SVN-fs-dump-format-version: 2" >input &&
diff --git a/t/t9300-fast-import.sh b/t/t9300-fast-import.sh
index 2fcf26946..ac6f3b6af 100755
--- a/t/t9300-fast-import.sh
+++ b/t/t9300-fast-import.sh
@@ -49,14 +49,6 @@ echo "$@"'
>empty
-test_expect_success 'setup: have pipes?' '
- rm -f frob &&
- if mkfifo frob
- then
- test_set_prereq PIPE
- fi
-'
-
###
### series A
###
diff --git a/t/test-lib.sh b/t/test-lib.sh
index 1f510252a..8d76cf23d 100644
--- a/t/test-lib.sh
+++ b/t/test-lib.sh
@@ -727,6 +727,11 @@ test_i18ngrep () {
fi
}
+test_lazy_prereq PIPE '
+ # test whether the filesystem supports FIFOs
+ rm -f testfifo && mkfifo testfifo
+'
+
test_lazy_prereq SYMLINKS '
# test whether the filesystem supports symbolic links
ln -s x y && test -h y