Git fork

t: remove test_oid_init in tests

Now that we call test_oid_init in the setup for all test scripts,
there's no point in calling it individually. Remove all of the places
where we've done so to help keep tests tidy.

Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net>
Reviewed-by: Eric Sunshine <sunshine@sunshineco.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

authored by

brian m. carlson and committed by
Junio C Hamano
e023ff06 4feb562f

+2 -37
-3
t/lib-pack.sh
··· 35 35 # have hardcoded some well-known objects. See the case statements below for the 36 36 # complete list. 37 37 pack_obj () { 38 - test_oid_init 39 - 40 38 case "$1" in 41 39 # empty blob 42 40 $EMPTY_BLOB) ··· 121 119 122 120 # Compute and append pack trailer to "$1" 123 121 pack_trailer () { 124 - test_oid_init && 125 122 test-tool $(test_oid algo) -b <"$1" >trailer.tmp && 126 123 cat trailer.tmp >>"$1" && 127 124 rm -f trailer.tmp
-1
t/lib-submodule-update.sh
··· 196 196 # the submodule repo if it doesn't exist and configures the most problematic 197 197 # settings for diff.ignoreSubmodules. 198 198 prolog () { 199 - test_oid_init && 200 199 (test -d submodule_update_repo || create_lib_submodule_repo) && 201 200 test_config_global diff.ignoreSubmodules all && 202 201 test_config diff.ignoreSubmodules all
-4
t/t0000-basic.sh
··· 891 891 test_path_is_missing also-clean-atexit 892 892 " 893 893 894 - test_expect_success 'test_oid setup' ' 895 - test_oid_init 896 - ' 897 - 898 894 test_expect_success 'test_oid provides sane info by default' ' 899 895 test_oid zero >actual && 900 896 grep "^00*\$" actual &&
-2
t/t1006-cat-file.sh
··· 140 140 test_cmp expect actual 141 141 ' 142 142 143 - test_oid_init 144 - 145 143 tree_sha1=$(git write-tree) 146 144 tree_size=$(($(test_oid rawsz) + 13)) 147 145 tree_pretty_content="100644 blob $hello_sha1 hello"
-1
t/t1050-large.sh
··· 12 12 } 13 13 14 14 test_expect_success setup ' 15 - test_oid_init && 16 15 # clone does not allow us to pass core.bigfilethreshold to 17 16 # new repos, so set core.bigfilethreshold globally 18 17 git config --global core.bigfilethreshold 200k &&
-1
t/t1410-reflog.sh
··· 54 54 } 55 55 56 56 test_expect_success setup ' 57 - test_oid_init && 58 57 mkdir -p A/B && 59 58 echo rat >C && 60 59 echo ox >A/D &&
-1
t/t1450-fsck.sh
··· 9 9 . ./test-lib.sh 10 10 11 11 test_expect_success setup ' 12 - test_oid_init && 13 12 git config gc.auto 0 && 14 13 git config i18n.commitencoding ISO-8859-1 && 15 14 test_commit A fileA one &&
-1
t/t1500-rev-parse.sh
··· 59 59 ROOT=$(pwd) 60 60 61 61 test_expect_success 'setup' ' 62 - test_oid_init && 63 62 mkdir -p sub/dir work && 64 63 cp -R .git repo.git 65 64 '
-1
t/t3308-notes-merge.sh
··· 22 22 # Copy notes to remote-notes 23 23 git fetch . refs/notes/*:refs/remote-notes/origin/* && 24 24 25 - test_oid_init && 26 25 test_oid_cache <<-EOF 27 26 hash4a sha1:5e93d24084d32e1cb61f7070505b9d2530cca987 28 27 hash3a sha1:8366731eeee53787d2bdf8fc1eff7d94757e8da0
-1
t/t3600-rm.sh
··· 241 241 ' 242 242 243 243 test_expect_success 'choking "git rm" should not let it die with cruft' ' 244 - test_oid_init && 245 244 git reset -q --hard && 246 245 test_when_finished "rm -f .git/index.lock && git reset -q --hard" && 247 246 i=0 &&
-1
t/t3800-mktag.sh
··· 23 23 # first create a commit, so we have a valid object/type 24 24 # for the tag. 25 25 test_expect_success 'setup' ' 26 - test_oid_init && 27 26 echo Hello >A && 28 27 git update-index --add A && 29 28 git commit -m "Initial commit" &&
-2
t/t4002-diff-basic.sh
··· 10 10 11 11 . "$TEST_DIRECTORY"/lib-read-tree-m-3way.sh 12 12 13 - test_oid_init 14 - 15 13 test_oid_cache <<\EOF 16 14 aa_1 sha1:ccba72ad3888a3520b39efcf780b9ee64167535d 17 15 aa_1 sha256:9febfbf18197819b2735c45291f138525d2476d59470f98239647544586ba403
-1
t/t4027-diff-submodule.sh
··· 6 6 . "$TEST_DIRECTORY"/diff-lib.sh 7 7 8 8 test_expect_success setup ' 9 - test_oid_init && 10 9 test_tick && 11 10 test_create_repo sub && 12 11 (
-1
t/t4134-apply-submodule.sh
··· 8 8 . ./test-lib.sh 9 9 10 10 test_expect_success setup ' 11 - test_oid_init && 12 11 cat > create-sm.patch <<EOF && 13 12 diff --git a/dir/sm b/dir/sm 14 13 new file mode 160000
-1
t/t4200-rerere.sh
··· 25 25 . ./test-lib.sh 26 26 27 27 test_expect_success 'setup' ' 28 - test_oid_init && 29 28 cat >a1 <<-\EOF && 30 29 Some title 31 30 ==========
-1
t/t4211-line-log.sh
··· 4 4 . ./test-lib.sh 5 5 6 6 test_expect_success 'setup (import history)' ' 7 - test_oid_init && 8 7 git fast-import < "$TEST_DIRECTORY"/t4211/history.export && 9 8 git reset --hard 10 9 '
+1 -2
t/t5300-pack-object.sh
··· 12 12 13 13 test_expect_success \ 14 14 'setup' \ 15 - 'test_oid_init && 16 - rm -f .git/index* && 15 + 'rm -f .git/index* && 17 16 perl -e "print \"a\" x 4096;" > a && 18 17 perl -e "print \"b\" x 4096;" > b && 19 18 perl -e "print \"c\" x 4096;" > c &&
-1
t/t5302-pack-index.sh
··· 7 7 . ./test-lib.sh 8 8 9 9 test_expect_success 'setup' ' 10 - test_oid_init && 11 10 rawsz=$(test_oid rawsz) && 12 11 rm -rf .git && 13 12 git init &&
-1
t/t5313-pack-bounds-checks.sh
··· 45 45 } 46 46 47 47 test_expect_success 'setup' ' 48 - test_oid_init && 49 48 test_oid_cache <<-EOF 50 49 oid000 sha1:1485 51 50 oid000 sha256:4222
+1 -2
t/t5318-commit-graph.sh
··· 10 10 cd "$TRASH_DIRECTORY/full" && 11 11 git init && 12 12 git config core.commitGraph true && 13 - objdir=".git/objects" && 14 - test_oid_init 13 + objdir=".git/objects" 15 14 ' 16 15 17 16 test_expect_success POSIXPERM 'tweak umask for modebit tests' '
-1
t/t5319-multi-pack-index.sh
··· 29 29 } 30 30 31 31 test_expect_success 'setup' ' 32 - test_oid_init && 33 32 test_oid_cache <<-EOF 34 33 idxoff sha1:2999 35 34 idxoff sha256:3739
-1
t/t5324-split-commit-graph.sh
··· 12 12 git config gc.writeCommitGraph false && 13 13 infodir=".git/objects/info" && 14 14 graphdir="$infodir/commit-graphs" && 15 - test_oid_init && 16 15 test_oid_cache <<-EOM 17 16 shallow sha1:1760 18 17 shallow sha256:2064
-1
t/t5504-fetch-receive-strict.sh
··· 4 4 . ./test-lib.sh 5 5 6 6 test_expect_success 'setup and inject "corrupt or missing" object' ' 7 - test_oid_init && 8 7 echo hello >greetings && 9 8 git add greetings && 10 9 git commit -m greetings &&
-1
t/t5530-upload-pack-error.sh
··· 14 14 } 15 15 16 16 test_expect_success 'setup and corrupt repository' ' 17 - test_oid_init && 18 17 echo file >file && 19 18 git add file && 20 19 git rev-parse :file &&
-1
t/t5562-http-backend-content-length.sh
··· 46 46 } 47 47 48 48 test_expect_success 'setup' ' 49 - test_oid_init && 50 49 HTTP_CONTENT_ENCODING="identity" && 51 50 export HTTP_CONTENT_ENCODING && 52 51 git config http.receivepack true &&
-1
t/t5702-protocol-v2.sh
··· 13 13 daemon_parent=$GIT_DAEMON_DOCUMENT_ROOT_PATH/parent 14 14 15 15 test_expect_success 'create repo to be served by git-daemon' ' 16 - test_oid_init && 17 16 git init "$daemon_parent" && 18 17 test_commit -C "$daemon_parent" one 19 18 '
-1
t/t5703-upload-pack-ref-in-want.sh
··· 43 43 # \ | / 44 44 # a 45 45 test_expect_success 'setup repository' ' 46 - test_oid_init && 47 46 test_commit a && 48 47 git checkout -b o/foo && 49 48 test_commit b &&
-1
t/t6006-rev-list-format.sh
··· 32 32 truncate_count=20 33 33 34 34 test_expect_success 'setup' ' 35 - test_oid_init && 36 35 : >foo && 37 36 git add foo && 38 37 git config i18n.commitEncoding $test_encoding &&