Thread (2 messages) flat view 2 messages, 2 authors, 2016-12-01

Re: Re* git pull --rebase should use fast forward merge if possible

From: Junio C Hamano <hidden>
Date: 2016-12-01 18:51:08

Stefan Beller [off-list ref] writes:
On Thu, Dec 1, 2016 at 9:59 AM, Junio C Hamano [off-list ref] wrote:
quoted
+test_expect_success '--rebase fast forward' '
+       git reset --hard before-rebase &&
+       git checkout -b ff &&
+       echo another modification >file &&
+       git commit -m third file &&
+
+       git checkout to-rebase &&
+       git pull --rebase . ff &&
+       test "$(git rev-parse HEAD)" = "$(git rev-parse ff)" &&
+
+       # The above only validates the result.  Did we actually bypass rebase?
Good catch for the test, but I think we can make the sed regexp simpler, as we
can leave out the second "[0-9a-f]"? (git reflog |sed
"s/^[0-9a-f]*/OBJID/" works here)
This mimics the existing tests around there for consistency.
Simplifying or cleaning of this test script as a whole is outside
the scope.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help