From: Junio C Hamano <gitster@pobox.com>
To: Thomas Rast <trast@student.ethz.ch>
Cc: git@vger.kernel.org, Johannes Schindelin <johannes.schindelin@gmx.de>
Subject: Re: [PATCH] rebase -i: correctly remember --root flag across --continue
Date: Mon, 26 Jan 2009 13:49:24 -0800 [thread overview]
Message-ID: <7vzlhd3fh7.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <7veiyp4w2m.fsf@gitster.siamese.dyndns.org> (Junio C. Hamano's message of "Mon, 26 Jan 2009 13:05:37 -0800")
Junio C Hamano <gitster@pobox.com> writes:
> Thomas Rast <trast@student.ethz.ch> writes:
> ...
>> +sed 's/#/ /g' > expect-conflict-p <<'EOF'
>> +* Merge branch 'third' into other
>> +|\##
>> +| * 6
>> +* | Merge branch 'side' into other
>> +|\ \##
>> +| * | 5
>> +* | | 4
>> +|/ /##
>> +* | 3
>> +|/##
>> +* conflict
>> +* 2
>> +* 1
>> +EOF
>
> I do not like this very much. Future improvements of the graph drawing
> algorithm (one obvious "flaw" you are exposing by the above is that it has
> trailing whitespaces that can be trimmed, and somebody else may be
> inclined to fix) would break the expectation this test vector has.
>
> Do you have to compare the topology this way, or are there other more
> reliable ways?
Perhaps something like this.
t/t3412-rebase-root.sh | 36 +++++++++++++++++++++---------------
1 files changed, 21 insertions(+), 15 deletions(-)
diff --git i/t/t3412-rebase-root.sh w/t/t3412-rebase-root.sh
index 29bb6d0..2408cf8 100755
--- i/t/t3412-rebase-root.sh
+++ w/t/t3412-rebase-root.sh
@@ -240,19 +240,24 @@ test_expect_success 'rebase -i --root with conflict (second part)' '
'
sed 's/#/ /g' > expect-conflict-p <<'EOF'
-* Merge branch 'third' into other
-|\##
-| * 6
-* | Merge branch 'side' into other
-|\ \##
-| * | 5
-* | | 4
-|/ /##
-* | 3
-|/##
-* conflict
-* 2
-* 1
+commit conflict3 conflict3~1 conflict3^2
+Merge branch 'third' into other
+commit conflict3^2 conflict3~4
+6
+commit conflict3~1 conflict3~2 conflict3~1^2
+Merge branch 'side' into other
+commit conflict3~1^2 conflict3~3
+5
+commit conflict3~2 conflict3~3
+4
+commit conflict3~3 conflict3~4
+3
+commit conflict3~4 conflict3~5
+conflict
+commit conflict3~5 conflict3~6
+2
+commit conflict3~6
+1
EOF
test_expect_success 'rebase -i -p --root with conflict (first part)' '
@@ -268,8 +273,9 @@ test_expect_success 'fix the conflict' '
test_expect_success 'rebase -i -p --root with conflict (second part)' '
git rebase --continue &&
- git log --graph --topo-order --pretty=tformat:"%s" > conflict3 &&
- test_cmp expect-conflict-p conflict3
+ git rev-list --topo-order --parents --pretty="tformat:%s" HEAD |
+ git name-rev --stdin --name-only --refs=refs/heads/conflict3 >out &&
+ test_cmp expect-conflict-p out
'
test_done
next prev parent reply other threads:[~2009-01-26 21:50 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-25 23:31 [PATCH 0/2] rebase -i --root cleanups Johannes Schindelin
2009-01-25 23:31 ` [PATCH 1/2] rebase -i --root: simplify code Johannes Schindelin
2009-01-25 23:49 ` Thomas Rast
2009-01-25 23:53 ` Thomas Rast
2009-01-26 5:54 ` Junio C Hamano
2009-01-26 9:05 ` [PATCH] rebase -i: correctly remember --root flag across --continue Thomas Rast
2009-01-26 20:47 ` Junio C Hamano
2009-01-26 21:05 ` Junio C Hamano
2009-01-26 21:09 ` Jeff King
2009-01-26 21:12 ` Jeff King
2009-01-26 21:28 ` Thomas Rast
2009-01-27 0:29 ` Junio C Hamano
2009-01-26 21:49 ` Junio C Hamano [this message]
2009-01-30 22:43 ` Thomas Rast
2009-01-30 22:47 ` [PATCH 1/2] t3412: clean up GIT_EDITOR usage Thomas Rast
2009-01-30 22:47 ` [PATCH 2/2] t3412: use log|name-rev instead of log --graph Thomas Rast
2009-02-01 22:24 ` [PATCH 1/2] t3412: clean up GIT_EDITOR usage Johannes Schindelin
2009-02-02 8:39 ` Thomas Rast
2009-01-26 0:44 ` [PATCH 1/2] rebase -i --root: simplify code Johannes Schindelin
2009-01-25 23:32 ` [PATCH 2/2] rebase -i --root: fix check for number of arguments Johannes Schindelin
2009-01-26 0:07 ` Thomas Rast
2009-01-26 0:49 ` Johannes Schindelin
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=7vzlhd3fh7.fsf@gitster.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=johannes.schindelin@gmx.de \
--cc=trast@student.ethz.ch \
/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.