aboutsummaryrefslogtreecommitdiff
path: root/t/t5521-pull-options.sh
diff options
context:
space:
mode:
authorTuncer Ayaz <tuncer.ayaz@gmail.com>2008-11-15 01:14:24 +0100
committerJunio C Hamano <gitster@pobox.com>2008-11-14 17:18:32 -0800
commit7f87aff22c0232a5ce327ea3d2923776936c97f4 (patch)
treee7fe32985b21b731d159fb6f73768fc09d1d63af /t/t5521-pull-options.sh
parenta0d3ab9c277f1a198ec8e29432c0127d4cf719d2 (diff)
downloadgit-7f87aff22c0232a5ce327ea3d2923776936c97f4.tar.gz
git-7f87aff22c0232a5ce327ea3d2923776936c97f4.tar.xz
Teach/Fix pull/fetch -q/-v options
Implement git-pull --quiet and git-pull --verbose by adding the options to git-pull and fixing verbosity handling in git-fetch. Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t5521-pull-options.sh')
-rwxr-xr-xt/t5521-pull-options.sh60
1 files changed, 60 insertions, 0 deletions
diff --git a/t/t5521-pull-options.sh b/t/t5521-pull-options.sh
new file mode 100755
index 000000000..83e2e8ab8
--- /dev/null
+++ b/t/t5521-pull-options.sh
@@ -0,0 +1,60 @@
+#!/bin/sh
+
+test_description='pull options'
+
+. ./test-lib.sh
+
+D=`pwd`
+
+test_expect_success 'setup' '
+ mkdir parent &&
+ (cd parent && git init &&
+ echo one >file && git add file &&
+ git commit -m one)
+'
+
+cd "$D"
+
+test_expect_success 'git pull -q' '
+ mkdir clonedq &&
+ cd clonedq &&
+ git pull -q "$D/parent" >out 2>err &&
+ test ! -s out
+'
+
+cd "$D"
+
+test_expect_success 'git pull' '
+ mkdir cloned &&
+ cd cloned &&
+ git pull "$D/parent" >out 2>err &&
+ test -s out
+'
+cd "$D"
+
+test_expect_success 'git pull -v' '
+ mkdir clonedv &&
+ cd clonedv &&
+ git pull -v "$D/parent" >out 2>err &&
+ test -s out
+'
+
+cd "$D"
+
+test_expect_success 'git pull -v -q' '
+ mkdir clonedvq &&
+ cd clonedvq &&
+ git pull -v -q "$D/parent" >out 2>err &&
+ test ! -s out
+'
+
+cd "$D"
+
+test_expect_success 'git pull -q -v' '
+ mkdir clonedqv &&
+ cd clonedqv &&
+ git pull -q -v "$D/parent" >out 2>err &&
+ test -s out
+'
+
+test_done