All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Nguyễn Thái Ngọc Duy" <pclouds@gmail.com>
To: git@vger.kernel.org
Cc: "Nguyễn Thái Ngọc Duy" <pclouds@gmail.com>
Subject: [WIP PATCH 26/26] Turn on GIT_HARDENED_SETUP for the whole test suite
Date: Tue, 16 Feb 2010 23:05:17 +0700	[thread overview]
Message-ID: <1266336317-607-27-git-send-email-pclouds@gmail.com> (raw)
In-Reply-To: <1266336317-607-1-git-send-email-pclouds@gmail.com>


Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
---
 t/t0000-basic.sh              |    2 --
 t/t0001-init.sh               |    2 --
 t/t0003-attributes.sh         |    2 --
 t/t0024-crlf-archive.sh       |    2 --
 t/t4201-shortlog.sh           |    2 --
 t/t5000-tar-tree.sh           |    2 --
 t/t5001-archive-attr.sh       |    2 --
 t/t5600-clone-fail-cleanup.sh |    2 --
 t/t5601-clone.sh              |    2 --
 t/t5602-clone-remote-exec.sh  |    2 --
 t/t5700-clone-reference.sh    |    2 --
 t/t5701-clone-local.sh        |    2 --
 t/t5702-clone-options.sh      |    2 --
 t/t5704-bundle.sh             |    2 --
 t/t5705-clone-2gb.sh          |    2 --
 t/t5706-clone-branch.sh       |    2 --
 t/t7002-grep.sh               |    2 --
 t/test-lib.sh                 |    3 +++
 18 files changed, 3 insertions(+), 34 deletions(-)

diff --git a/t/t0000-basic.sh b/t/t0000-basic.sh
index 0a4be17..f4ca4fc 100755
--- a/t/t0000-basic.sh
+++ b/t/t0000-basic.sh
@@ -28,8 +28,6 @@ then
 	exit 1
 fi
 
-export GIT_HARDENED_SETUP=1
-
 . ./test-lib.sh
 
 ################################################################
diff --git a/t/t0001-init.sh b/t/t0001-init.sh
index 0dd6ffa..5386504 100755
--- a/t/t0001-init.sh
+++ b/t/t0001-init.sh
@@ -4,8 +4,6 @@ test_description='git init'
 
 . ./test-lib.sh
 
-export GIT_HARDENED_SETUP=1
-
 check_config () {
 	if test -d "$1" && test -f "$1/config" && test -d "$1/refs"
 	then
diff --git a/t/t0003-attributes.sh b/t/t0003-attributes.sh
index 2ebb345..1c77192 100755
--- a/t/t0003-attributes.sh
+++ b/t/t0003-attributes.sh
@@ -4,8 +4,6 @@ test_description=gitattributes
 
 . ./test-lib.sh
 
-export GIT_HARDENED_SETUP=1
-
 attr_check () {
 
 	path="$1"
diff --git a/t/t0024-crlf-archive.sh b/t/t0024-crlf-archive.sh
index f96db4d..ff345ea 100755
--- a/t/t0024-crlf-archive.sh
+++ b/t/t0024-crlf-archive.sh
@@ -4,8 +4,6 @@ test_description='respect crlf in git archive'
 
 . ./test-lib.sh
 
-export GIT_HARDENED_SETUP=1
-
 UNZIP=${UNZIP:-unzip}
 
 test_expect_success setup '
diff --git a/t/t4201-shortlog.sh b/t/t4201-shortlog.sh
index 7ae327a..a01e55b 100755
--- a/t/t4201-shortlog.sh
+++ b/t/t4201-shortlog.sh
@@ -8,8 +8,6 @@ test_description='git shortlog
 
 . ./test-lib.sh
 
-export GIT_HARDENED_SETUP=1
-
 echo 1 > a1
 git add a1
 tree=$(git write-tree)
diff --git a/t/t5000-tar-tree.sh b/t/t5000-tar-tree.sh
index 4c69dd2..27bfba5 100755
--- a/t/t5000-tar-tree.sh
+++ b/t/t5000-tar-tree.sh
@@ -29,8 +29,6 @@ UNZIP=${UNZIP:-unzip}
 
 SUBSTFORMAT=%H%n
 
-export GIT_HARDENED_SETUP=1
-
 test_expect_success \
     'populate workdir' \
     'mkdir a b c &&
diff --git a/t/t5001-archive-attr.sh b/t/t5001-archive-attr.sh
index 80e1e72..426b319 100755
--- a/t/t5001-archive-attr.sh
+++ b/t/t5001-archive-attr.sh
@@ -4,8 +4,6 @@ test_description='git archive attribute tests'
 
 . ./test-lib.sh
 
-export GIT_HARDENED_SETUP=1
-
 SUBSTFORMAT=%H%n
 
 test_expect_exists() {
diff --git a/t/t5600-clone-fail-cleanup.sh b/t/t5600-clone-fail-cleanup.sh
index 424e6ad..ee06d28 100755
--- a/t/t5600-clone-fail-cleanup.sh
+++ b/t/t5600-clone-fail-cleanup.sh
@@ -11,8 +11,6 @@ remove the directory before attempting a clone again.'
 
 . ./test-lib.sh
 
-export GIT_HARDENED_SETUP=1
-
 test_expect_success \
     'clone of non-existent source should fail' \
     'test_must_fail git clone foo bar'
diff --git a/t/t5601-clone.sh b/t/t5601-clone.sh
index a598f75..2147567 100755
--- a/t/t5601-clone.sh
+++ b/t/t5601-clone.sh
@@ -4,8 +4,6 @@ test_description=clone
 
 . ./test-lib.sh
 
-export GIT_HARDENED_SETUP=1
-
 test_expect_success setup '
 
 	rm -fr .git &&
diff --git a/t/t5602-clone-remote-exec.sh b/t/t5602-clone-remote-exec.sh
index a94c528..deffdae 100755
--- a/t/t5602-clone-remote-exec.sh
+++ b/t/t5602-clone-remote-exec.sh
@@ -4,8 +4,6 @@ test_description=clone
 
 . ./test-lib.sh
 
-export GIT_HARDENED_SETUP=1
-
 test_expect_success setup '
 	echo "#!/bin/sh" > not_ssh
 	echo "echo \"\$*\" > not_ssh_output" >> not_ssh
diff --git a/t/t5700-clone-reference.sh b/t/t5700-clone-reference.sh
index 2464f57..1c10916 100755
--- a/t/t5700-clone-reference.sh
+++ b/t/t5700-clone-reference.sh
@@ -6,8 +6,6 @@
 test_description='test clone --reference'
 . ./test-lib.sh
 
-export GIT_HARDENED_SETUP=1
-
 base_dir=`pwd`
 
 U=$base_dir/UPLOAD_LOG
diff --git a/t/t5701-clone-local.sh b/t/t5701-clone-local.sh
index 3c3d6ed..8b4c356 100755
--- a/t/t5701-clone-local.sh
+++ b/t/t5701-clone-local.sh
@@ -3,8 +3,6 @@
 test_description='test local clone'
 . ./test-lib.sh
 
-export GIT_HARDENED_SETUP=1
-
 D=`pwd`
 
 test_expect_success 'preparing origin repository' '
diff --git a/t/t5702-clone-options.sh b/t/t5702-clone-options.sh
index 63f59ba..02cb024 100755
--- a/t/t5702-clone-options.sh
+++ b/t/t5702-clone-options.sh
@@ -3,8 +3,6 @@
 test_description='basic clone options'
 . ./test-lib.sh
 
-export GIT_HARDENED_SETUP=1
-
 test_expect_success 'setup' '
 
 	mkdir parent &&
diff --git a/t/t5704-bundle.sh b/t/t5704-bundle.sh
index 507c838..a8f4419 100755
--- a/t/t5704-bundle.sh
+++ b/t/t5704-bundle.sh
@@ -3,8 +3,6 @@
 test_description='some bundle related tests'
 . ./test-lib.sh
 
-export GIT_HARDENED_SETUP=1
-
 test_expect_success 'setup' '
 
 	: > file &&
diff --git a/t/t5705-clone-2gb.sh b/t/t5705-clone-2gb.sh
index f63a557..adfaae8 100755
--- a/t/t5705-clone-2gb.sh
+++ b/t/t5705-clone-2gb.sh
@@ -3,8 +3,6 @@
 test_description='Test cloning a repository larger than 2 gigabyte'
 . ./test-lib.sh
 
-export GIT_HARDENED_SETUP=1
-
 test -z "$GIT_TEST_CLONE_2GB" &&
 say "Skipping expensive 2GB clone test; enable it with GIT_TEST_CLONE_2GB=t" &&
 test_done &&
diff --git a/t/t5706-clone-branch.sh b/t/t5706-clone-branch.sh
index fbee0d0..f3f9a76 100755
--- a/t/t5706-clone-branch.sh
+++ b/t/t5706-clone-branch.sh
@@ -3,8 +3,6 @@
 test_description='clone --branch option'
 . ./test-lib.sh
 
-export GIT_HARDENED_SETUP=1
-
 check_HEAD() {
 	echo refs/heads/"$1" >expect &&
 	git symbolic-ref HEAD >actual &&
diff --git a/t/t7002-grep.sh b/t/t7002-grep.sh
index 67afb42..ebae152 100755
--- a/t/t7002-grep.sh
+++ b/t/t7002-grep.sh
@@ -8,8 +8,6 @@ test_description='git grep various.
 
 . ./test-lib.sh
 
-export GIT_HARDENED_SETUP=1
-
 cat >hello.c <<EOF
 #include <stdio.h>
 int main(int argc, const char **argv)
diff --git a/t/test-lib.sh b/t/test-lib.sh
index afd3053..e3e3084 100644
--- a/t/test-lib.sh
+++ b/t/test-lib.sh
@@ -61,6 +61,9 @@ export GIT_COMMITTER_EMAIL GIT_COMMITTER_NAME
 export EDITOR
 GIT_TEST_CMP=${GIT_TEST_CMP:-diff -u}
 
+GIT_HARDENED_SETUP=1
+export GIT_HARDENED_SETUP
+
 # Protect ourselves from common misconfiguration to export
 # CDPATH into the environment
 unset CDPATH
-- 
1.7.0.195.g637a2

      parent reply	other threads:[~2010-02-16 16:18 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-16 16:04 [WIP PATCH 00/26] Git setup cleanup series Nguyễn Thái Ngọc Duy
2010-02-16 16:04 ` [WIP PATCH 01/26] rev-parse --git-dir: print relative gitdir correctly Nguyễn Thái Ngọc Duy
2010-02-16 16:04 ` [WIP PATCH 02/26] setup_git_directory*: Explicitly set git dir Nguyễn Thái Ngọc Duy
2010-02-16 16:04 ` [WIP PATCH 03/26] Save setup_git_dir* info globally for later use Nguyễn Thái Ngọc Duy
2010-02-16 16:04 ` [WIP PATCH 04/26] Add GIT_HARDENED_SETUP to detect gitdir/worktree related mis-setup errors Nguyễn Thái Ngọc Duy
2010-02-16 16:04 ` [WIP PATCH 05/26] enter_repo(): use setup_git_directory_gently internally Nguyễn Thái Ngọc Duy
2010-02-16 16:04 ` [WIP PATCH 06/26] Tweak init/clone to work properly with GIT_HARDENED_SETUP=1 Nguyễn Thái Ngọc Duy
2010-02-16 16:04 ` [WIP PATCH 07/26] Support running setup_git_dir_gently() from the beginning for builtin commands Nguyễn Thái Ngọc Duy
2010-02-16 16:04 ` [WIP PATCH 08/26] config: move up gitdir setup to run_builtin() Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 09/26] hash-object: move " Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 10/26] shortlog: move up " Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 11/26] Do not look for .git/info/exclude when gitdir is not set up Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 12/26] grep: move up gitdir setup to run_builtin() Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 13/26] USE_PAGER should not be used without RUN_SETUP* Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 14/26] Do not try to read $GIT_DIR/info/attributes if there is no repository Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 15/26] archive: move up gitdir setup to run_builtin() Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 16/26] mailinfo: " Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 17/26] check-ref-format: setup gitdir gently Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 18/26] verify-pack: set up " Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 19/26] apply: move up gitdir setup to run_builtin() Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 20/26] bundle: " Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 21/26] diff: " Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 22/26] help: " Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 23/26] ls-remote: " Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 24/26] var: " Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` [WIP PATCH 25/26] merge-file: " Nguyễn Thái Ngọc Duy
2010-02-16 16:05 ` Nguyễn Thái Ngọc Duy [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1266336317-607-27-git-send-email-pclouds@gmail.com \
    --to=pclouds@gmail.com \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.