Mercurial > hg
comparison tests/test-histedit-merge-tools.t @ 42052:15d2afa31e57
histedit: narrow the scope of discarded ui output
In 34165875fa5df813bec3a0cd348932b304d44efb, a lot of the output from
histedit was excluded. This slightly adjusts the scope of that exclusion,
to both discard more uninsteresting messages, and ensure that pre-merge-tool
output gets shown before the external merge tool is executed.
Differential Revision: https://phab.mercurial-scm.org/D6177
author | Rodrigo Damazio Bovendorp <rdamazio@google.com> |
---|---|
date | Mon, 01 Apr 2019 19:02:24 -0700 |
parents | |
children | 5effb1992c17 |
comparison
equal
deleted
inserted
replaced
42051:f4147ca63d39 | 42052:15d2afa31e57 |
---|---|
1 Test histedit extension: Merge tools | |
2 ==================================== | |
3 | |
4 Initialization | |
5 --------------- | |
6 | |
7 $ . "$TESTDIR/histedit-helpers.sh" | |
8 | |
9 $ cat >> $HGRCPATH <<EOF | |
10 > [alias] | |
11 > logt = log --template '{rev}:{node|short} {desc|firstline}\n' | |
12 > [extensions] | |
13 > histedit= | |
14 > mockmakedate = $TESTDIR/mockmakedate.py | |
15 > [ui] | |
16 > pre-merge-tool-output-template='pre-merge message for {node}\n' | |
17 > EOF | |
18 | |
19 Merge conflict | |
20 -------------- | |
21 | |
22 $ hg init r | |
23 $ cd r | |
24 $ echo foo > file | |
25 $ hg add file | |
26 $ hg ci -m "First" -d "1 0" | |
27 $ echo bar > file | |
28 $ hg ci -m "Second" -d "2 0" | |
29 | |
30 $ hg logt --graph | |
31 @ 1:2aa920f62fb9 Second | |
32 | | |
33 o 0:7181f42b8fca First | |
34 | |
35 | |
36 Invert the order of the commits, but fail the merge. | |
37 $ hg histedit --config ui.merge=false --commands - 2>&1 <<EOF | fixbundle | |
38 > pick 2aa920f62fb9 Second | |
39 > pick 7181f42b8fca First | |
40 > EOF | |
41 merging file | |
42 pre-merge message for b90fa2e91a6d11013945a5f684be45b84a8ca6ec | |
43 merging file failed! | |
44 Fix up the change (pick 7181f42b8fca) | |
45 (hg histedit --continue to resume) | |
46 | |
47 $ hg histedit --abort | fixbundle | |
48 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
49 | |
50 Invert the order of the commits, and pretend the merge succeeded. | |
51 $ hg histedit --config ui.merge=true --commands - 2>&1 <<EOF | fixbundle | |
52 > pick 2aa920f62fb9 Second | |
53 > pick 7181f42b8fca First | |
54 > EOF | |
55 merging file | |
56 pre-merge message for b90fa2e91a6d11013945a5f684be45b84a8ca6ec | |
57 7181f42b8fca: skipping changeset (no changes) |