From: Stephen Boyd <sboyd@codeaurora.org>
To: git@vger.kernel.org
Subject: [BUG/TEST 2/2] t3501: Expose addinfo_cache error message in cherry-pick
Date: Mon, 11 Feb 2013 20:27:42 -0800 [thread overview]
Message-ID: <1360643262-1472-3-git-send-email-sboyd@codeaurora.org> (raw)
In-Reply-To: <1360643262-1472-1-git-send-email-sboyd@codeaurora.org>
I encountered a mysterious error message while doing some
cherry-picking into a dirty tree. In this case, the working tree
was dirty with changes to two files that had been renamed, we'll
call them 'file and 'otherfile'. The change I wanted to
cherry-pick was made along a branch before the rename to 'file'.
When I cherry-picked the change from the other branch without the
rename to my current branch with the rename, the change applied
cleanly and the dirty bits were committed but a mysterious error
message was printed indicating something went wrong with the file
that was still dirty after the cherry-pick.
error: addinfo_cache failed for path 'otherfile'
I suspect this error message shouldn't be printed, so recreate
the problem in t3501 so that it can be fixed.
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
---
t/t3501-revert-cherry-pick.sh | 32 ++++++++++++++++++++++++++++++++
1 file changed, 32 insertions(+)
diff --git a/t/t3501-revert-cherry-pick.sh b/t/t3501-revert-cherry-pick.sh
index eef4d8c..522a9fd 100755
--- a/t/t3501-revert-cherry-pick.sh
+++ b/t/t3501-revert-cherry-pick.sh
@@ -137,4 +137,36 @@ test_expect_success 'cherry-pick on dirty rename should stay dirty' '
! git diff --quiet
'
+test_expect_success 'cherry-pick on dirty rename should not complain' '
+ git checkout initial &&
+
+ test_commit file1
+
+ for l in b c d e f g h i j k l m n o
+ do
+ echo $l$l$l$l$l$l$l$l$l
+ done >oops &&
+
+ test_tick &&
+ git add oops &&
+ git commit -m drop2 &&
+ git tag drop2 &&
+
+ git checkout file1 &&
+ test_tick &&
+ git mv oops spoo &&
+ git mv file1.t file2.t &&
+ git commit -m rename4 &&
+ git tag rename4 &&
+
+ echo file2 > file2.t &&
+ for l in b c d e f g h i j k m n o
+ do
+ echo $l$l$l$l$l$l$l$l$l
+ done >spoo &&
+
+ git cherry-pick drop2 2> errors &&
+ ! test -s errors
+'
+
test_done
--
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
hosted by The Linux Foundation
next prev parent reply other threads:[~2013-02-12 4:28 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-02-12 4:27 [BUG/TEST 0/2] bugs with cherry-pick renames Stephen Boyd
2013-02-12 4:27 ` [BUG/TEST 1/2] t3501: Expose bug with cherry-pick into dirty trees w/ renames Stephen Boyd
2013-02-12 4:27 ` Stephen Boyd [this message]
2013-03-04 18:48 ` [BUG/TEST 0/2] bugs with cherry-pick renames Stephen Boyd
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=1360643262-1472-3-git-send-email-sboyd@codeaurora.org \
--to=sboyd@codeaurora.org \
--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.