annotate tests/test-evolve-effectflags.t @ 2448:66f05d5f4769

effectflag: detect meta changes Add the detection of known meta field changes. The known meta fields that we check are: - user - date - branch
author Boris Feld <boris.feld@octobus.net>
date Fri, 19 May 2017 19:48:44 +0200
parents 631ccf45f0bb
children 0b05142117d2
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2446
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
1 Test the 'effect-flags' feature
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
2
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
3 Global setup
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
4 ============
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
5
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
6 $ . $TESTDIR/testlib/common.sh
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
7 $ cat >> $HGRCPATH <<EOF
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
8 > [ui]
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
9 > interactive = true
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
10 > [phases]
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
11 > publish=False
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
12 > [extensions]
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
13 > evolve =
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
14 > [experimental]
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
15 > evolution.effect-flags = 1
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
16 > EOF
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
17
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
18 $ hg init $TESTTMP/effect-flags
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
19 $ cd $TESTTMP/effect-flags
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
20 $ mkcommit ROOT
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
21
2447
631ccf45f0bb effect-flag: rework existing test to prepare for mor tests
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 2446
diff changeset
22 amend touching the description only
631ccf45f0bb effect-flag: rework existing test to prepare for mor tests
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 2446
diff changeset
23 -----------------------------------
2446
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
24
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
25 $ mkcommit A0
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
26 $ hg amend -m "A1"
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
27
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
28 check result
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
29
2447
631ccf45f0bb effect-flag: rework existing test to prepare for mor tests
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 2446
diff changeset
30 $ hg debugobsolete --rev .
2446
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
31 471f378eab4c5e25f6c77f785b27c936efb22874 fdf9bde5129a28d4548fadd3f62b265cdd3b7a2e 0 (*) {'ef1': '1', 'user': 'test'} (glob)
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
32 $ hg obslog .
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
33 @ fdf9bde5129a (2) A1
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
34 |
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
35 x 471f378eab4c (1) A0
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
36 rewritten by test (*) as fdf9bde5129a (glob)
4b2f4da124a2 effectflag: allow to save effect of change in obsmarkers
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
37
2448
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
38
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
39 amend touching the metadata only
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
40 --------------------------------
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
41
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
42 $ mkcommit B0
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
43 $ hg amend -u "bob <bob@bob.com>"
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
44
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
45 check result
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
46
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
47 $ hg debugobsolete --rev .
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
48 ef4a313b1e0ade55718395d80e6b88c5ccd875eb 5485c92d34330dac9d7a63dc07e1e3373835b964 0 (*) {'ef1': '2', 'user': 'test'} (glob)
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
49 $ hg obslog .
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
50 @ 5485c92d3433 (4) B0
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
51 |
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
52 x ef4a313b1e0a (3) B0
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
53 rewritten by test (*) as 5485c92d3433 (glob)
66f05d5f4769 effectflag: detect meta changes
Boris Feld <boris.feld@octobus.net>
parents: 2447
diff changeset
54