From: Stephen Haberman Date: Tue, 11 Nov 2008 22:19:48 +0000 (-0600) Subject: Fix post-receive-email test for USER_EMAIL variable. X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=f7bba4bfe619be92b4872e2a6c9cff84af43b92d;p=git-central.git Fix post-receive-email test for USER_EMAIL variable. --- diff --git a/tests/t2200-1.txt b/tests/t2200-1.txt index cd80be7..79f3e01 100644 --- a/tests/t2200-1.txt +++ b/tests/t2200-1.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] master branch updated. $new_commit_hash X-Git-Refname: refs/heads/master diff --git a/tests/t2200-server-post-receive-email.sh b/tests/t2200-server-post-receive-email.sh index 3b42aff..28733db 100644 --- a/tests/t2200-server-post-receive-email.sh +++ b/tests/t2200-server-post-receive-email.sh @@ -4,7 +4,7 @@ test_description='server post-receive email notification' . ./test-lib.sh -export USER=author +export USER_EMAIL=author@example.com test_expect_success 'setup' ' echo "setup" >a && @@ -13,11 +13,10 @@ test_expect_success 'setup' ' git clone ./. server && rm -fr server/.git/hooks && git remote add origin ./server && - git config --add branch.master.remote origin && - git config --add branch.master.merge refs/heads/master && - GIT_DIR=./server/.git git config --add hooks.post-receive-email.mailinglist commits@list.com && - GIT_DIR=./server/.git git config --add hooks.post-receive-email.debug true && - GIT_DIR=. + git config branch.master.remote origin && + git config branch.master.merge refs/heads/master && + GIT_DIR=./server/.git git config hooks.post-receive-email.mailinglist commits@list.com && + GIT_DIR=./server/.git git config hooks.post-receive-email.debug true && echo cbas >./server/.git/description ' diff --git a/tests/t2201-1.txt b/tests/t2201-1.txt index d19fb71..46b6099 100644 --- a/tests/t2201-1.txt +++ b/tests/t2201-1.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] 1.0 annotated tag created. 1.0 X-Git-Refname: refs/tags/1.0 diff --git a/tests/t2201-2.txt b/tests/t2201-2.txt index c00a443..18b0c05 100644 --- a/tests/t2201-2.txt +++ b/tests/t2201-2.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] master branch updated. 1.0-2-g$new_commit_abbrev X-Git-Refname: refs/heads/master diff --git a/tests/t2201-3.txt b/tests/t2201-3.txt index 3646a09..1f128f4 100644 --- a/tests/t2201-3.txt +++ b/tests/t2201-3.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] 2.0 annotated tag created. 2.0 X-Git-Refname: refs/tags/2.0 diff --git a/tests/t2201-4.txt b/tests/t2201-4.txt index 0cc9d47..47bd8c3 100644 --- a/tests/t2201-4.txt +++ b/tests/t2201-4.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] 2.1 tag created. $new_commit_describe X-Git-Refname: refs/tags/2.1 diff --git a/tests/t2201-5.txt b/tests/t2201-5.txt index 70379a7..8fbafe6 100644 --- a/tests/t2201-5.txt +++ b/tests/t2201-5.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] 2.1 tag updated. $new_commit_describe X-Git-Refname: refs/tags/2.1 diff --git a/tests/t2201-6.txt b/tests/t2201-6.txt index a0f2f93..abcd52d 100644 --- a/tests/t2201-6.txt +++ b/tests/t2201-6.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] 2.1 tag deleted. $old_commit_describe X-Git-Refname: refs/tags/2.1 diff --git a/tests/t2201-7.txt b/tests/t2201-7.txt index afcf165..9bb498e 100644 --- a/tests/t2201-7.txt +++ b/tests/t2201-7.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] 2.0 annotated tag updated. 2.0 X-Git-Refname: refs/tags/2.0 diff --git a/tests/t2201-8.txt b/tests/t2201-8.txt index 669dedd..500b78c 100644 --- a/tests/t2201-8.txt +++ b/tests/t2201-8.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] 2.0 annotated tag deleted. $new_commit_describe X-Git-Refname: refs/tags/2.0 diff --git a/tests/t2201-server-post-receive-email-tags.sh b/tests/t2201-server-post-receive-email-tags.sh index 480f9cf..4b9f5a5 100644 --- a/tests/t2201-server-post-receive-email-tags.sh +++ b/tests/t2201-server-post-receive-email-tags.sh @@ -4,7 +4,7 @@ test_description='server post-receive email notification' . ./test-lib.sh -export USER=author +export USER_EMAIL=author@example.com test_expect_success 'setup' ' echo "setup" >a && @@ -13,11 +13,10 @@ test_expect_success 'setup' ' git clone ./. server && rm -fr server/.git/hooks && git remote add origin ./server && - git config --add branch.master.remote origin && - git config --add branch.master.merge refs/heads/master && - GIT_DIR=./server/.git git config --add hooks.post-receive-email.mailinglist commits@list.com && - GIT_DIR=./server/.git git config --add hooks.post-receive-email.debug true && - GIT_DIR=. + git config branch.master.remote origin && + git config branch.master.merge refs/heads/master && + GIT_DIR=./server/.git git config hooks.post-receive-email.mailinglist commits@list.com && + GIT_DIR=./server/.git git config hooks.post-receive-email.debug true && echo cbas >./server/.git/description ' diff --git a/tests/t2202-1.txt b/tests/t2202-1.txt index 3e5566c..ab04863 100644 --- a/tests/t2202-1.txt +++ b/tests/t2202-1.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] topic branch created. $new_commit_hash X-Git-Refname: refs/heads/topic diff --git a/tests/t2202-2.txt b/tests/t2202-2.txt index 573f010..519d370 100644 --- a/tests/t2202-2.txt +++ b/tests/t2202-2.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] topic branch deleted. $old_commit_hash X-Git-Refname: refs/heads/topic diff --git a/tests/t2202-3.txt b/tests/t2202-3.txt index a6d04c8..128a1c8 100644 --- a/tests/t2202-3.txt +++ b/tests/t2202-3.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] topic2 branch created. $existing_commit_hash X-Git-Refname: refs/heads/topic2 diff --git a/tests/t2202-4.txt b/tests/t2202-4.txt index ffab4be..f967307 100644 --- a/tests/t2202-4.txt +++ b/tests/t2202-4.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] topic branch updated. $existing_commit_hash X-Git-Refname: refs/heads/topic diff --git a/tests/t2202-5.txt b/tests/t2202-5.txt index ca00200..8261dec 100644 --- a/tests/t2202-5.txt +++ b/tests/t2202-5.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] topic branch updated. $new_commit_hash X-Git-Refname: refs/heads/topic diff --git a/tests/t2202-6.txt b/tests/t2202-6.txt index 218bcde..c7178b5 100644 --- a/tests/t2202-6.txt +++ b/tests/t2202-6.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] topic branch updated. $new_commit_hash X-Git-Refname: refs/heads/topic diff --git a/tests/t2202-server-post-receive-email-branches.sh b/tests/t2202-server-post-receive-email-branches.sh index 830a860..d794b11 100644 --- a/tests/t2202-server-post-receive-email-branches.sh +++ b/tests/t2202-server-post-receive-email-branches.sh @@ -4,7 +4,7 @@ test_description='server post-receive email notification' . ./test-lib.sh -export USER=author +export USER_EMAIL=author@example.com test_expect_success 'setup' ' echo "setup" >a && @@ -13,11 +13,10 @@ test_expect_success 'setup' ' git clone ./. server && rm -fr server/.git/hooks && git remote add origin ./server && - git config --add branch.master.remote origin && - git config --add branch.master.merge refs/heads/master && - GIT_DIR=./server/.git git config --add hooks.post-receive-email.mailinglist commits@list.com && - GIT_DIR=./server/.git git config --add hooks.post-receive-email.debug true && - GIT_DIR=. + git config branch.master.remote origin && + git config branch.master.merge refs/heads/master && + GIT_DIR=./server/.git git config hooks.post-receive-email.mailinglist commits@list.com && + GIT_DIR=./server/.git git config hooks.post-receive-email.debug true && echo cbas >./server/.git/description ' diff --git a/tests/t2203-1.txt b/tests/t2203-1.txt index 2279ac1..bf8d28f 100644 --- a/tests/t2203-1.txt +++ b/tests/t2203-1.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] topic1 branch updated. $new_commit_hash X-Git-Refname: refs/heads/topic1 diff --git a/tests/t2203-2.txt b/tests/t2203-2.txt index 81f3c52..3da2cdb 100644 --- a/tests/t2203-2.txt +++ b/tests/t2203-2.txt @@ -1,4 +1,4 @@ -From: author@payflex.com +From: author@example.com To: commits@list.com Subject: [cbas] topic1 branch updated. $new_commit_hash X-Git-Refname: refs/heads/topic1 diff --git a/tests/t2203-server-post-receive-email-stable.sh b/tests/t2203-server-post-receive-email-stable.sh index f8fe3ed..bf545f9 100644 --- a/tests/t2203-server-post-receive-email-stable.sh +++ b/tests/t2203-server-post-receive-email-stable.sh @@ -4,7 +4,7 @@ test_description='server post-receive email notification and how it behaves in o . ./test-lib.sh -export USER=author +export USER_EMAIL=author@example.com test_expect_success 'setup' ' echo "setup" >a && @@ -15,11 +15,10 @@ test_expect_success 'setup' ' git clone ./. server && rm -fr server/.git/hooks && git remote add origin ./server && - git config --add branch.master.remote origin && - git config --add branch.master.merge refs/heads/master && - GIT_DIR=./server/.git git config --add hooks.post-receive-email.mailinglist commits@list.com && - GIT_DIR=./server/.git git config --add hooks.post-receive-email.debug true && - GIT_DIR=. && + git config branch.master.remote origin && + git config branch.master.merge refs/heads/master && + GIT_DIR=./server/.git git config hooks.post-receive-email.mailinglist commits@list.com && + GIT_DIR=./server/.git git config hooks.post-receive-email.debug true && echo cbas >./server/.git/description && git checkout -b stable && diff --git a/tests/t2204-1.txt b/tests/t2204-1.txt index 4b7d92b..8e5bef1 100644 --- a/tests/t2204-1.txt +++ b/tests/t2204-1.txt @@ -1,45 +1,45 @@ -From: author@payflex.com -To: commits@list.com -Subject: [cbas] topic1 branch updated. $new_commit_hash -X-Git-Refname: refs/heads/topic1 -X-Git-Reftype: branch -X-Git-Oldrev: $old_commit_hash -X-Git-Newrev: $new_commit_hash - -The branch, topic1 has been updated - via $new_commit_abbrev resolved lines for merging stable into topic1 - from $old_commit_abbrev lines changed on topic1 - -Those revisions listed above that are new to this repository have -not appeared on any other notification email; so we list those -revisions in full, below. - -- Log ----------------------------------------------------------------- - -commit $new_commit_hash -Merge: $old_commit_hash $stable_hash -Author: A U Thor -Date: $new_commit_date - - resolved lines for merging stable into topic1 - -$new_commit_hash -diff --cc a -index d288e69,a9ccdfe..3f45f93 ---- a/a -+++ b/a -@@@ -1,3 -1,3 +1,3 @@@ -- line1.topic1 -- line2.topic1 -- line3.topic1 - -line1.stable -++line1.topic -+ line2.stable - -line3.stable -++line3.resolved - ------------------------------------------------------------------------ - -Summary of changes: - a | 6 +++--- - 1 files changed, 3 insertions(+), 3 deletions(-) +From: author@example.com +To: commits@list.com +Subject: [cbas] topic1 branch updated. $new_commit_hash +X-Git-Refname: refs/heads/topic1 +X-Git-Reftype: branch +X-Git-Oldrev: $old_commit_hash +X-Git-Newrev: $new_commit_hash + +The branch, topic1 has been updated + via $new_commit_abbrev resolved lines for merging stable into topic1 + from $old_commit_abbrev lines changed on topic1 + +Those revisions listed above that are new to this repository have +not appeared on any other notification email; so we list those +revisions in full, below. + +- Log ----------------------------------------------------------------- + +commit $new_commit_hash +Merge: $old_commit_hash $stable_hash +Author: A U Thor +Date: $new_commit_date + + resolved lines for merging stable into topic1 + +$new_commit_hash +diff --cc a +index d288e69,a9ccdfe..3f45f93 +--- a/a ++++ b/a +@@@ -1,3 -1,3 +1,3 @@@ +- line1.topic1 +- line2.topic1 +- line3.topic1 + -line1.stable +++line1.topic ++ line2.stable + -line3.stable +++line3.resolved + +----------------------------------------------------------------------- + +Summary of changes: + a | 6 +++--- + 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/t2204-server-post-receive-email-conflicts.sh b/tests/t2204-server-post-receive-email-conflicts.sh index 45b7cb9..f86e6ba 100644 --- a/tests/t2204-server-post-receive-email-conflicts.sh +++ b/tests/t2204-server-post-receive-email-conflicts.sh @@ -4,7 +4,7 @@ test_description='server post-receive email notification and how it behaves in o . ./test-lib.sh -export USER=author +export USER_EMAIL=author@example.com test_expect_success 'setup' ' echo "setup" >a && @@ -15,11 +15,10 @@ test_expect_success 'setup' ' git clone ./. server && rm -fr server/.git/hooks && git remote add origin ./server && - git config --add branch.master.remote origin && - git config --add branch.master.merge refs/heads/master && - GIT_DIR=./server/.git git config --add hooks.post-receive-email.mailinglist commits@list.com && - GIT_DIR=./server/.git git config --add hooks.post-receive-email.debug true && - GIT_DIR=. && + git config branch.master.remote origin && + git config branch.master.merge refs/heads/master && + GIT_DIR=./server/.git git config hooks.post-receive-email.mailinglist commits@list.com && + GIT_DIR=./server/.git git config hooks.post-receive-email.debug true && echo cbas >./server/.git/description && git checkout -b stable &&