Mercurial > evolve
annotate tests/testlib/common.sh @ 6117:a27bdd116761 stable
topic: wrap applychange from histedit to preserve topics
This should fix https://bz.mercurial-scm.org/show_bug.cgi?id=6550
author | Simon Sapin <simon.sapin@octobus.net> |
---|---|
date | Fri, 07 Jan 2022 17:52:34 +0100 |
parents | b1a04ff0f99e |
children |
rev | line source |
---|---|
2119
e1c26c632b6d
tests: adds simple test case for heads checking
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
1 . $TESTDIR/testlib/pythonpath.sh |
e1c26c632b6d
tests: adds simple test case for heads checking
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
2 |
e1c26c632b6d
tests: adds simple test case for heads checking
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
3 mkcommit() { |
6039
51249e4e9025
tests: port upstream 86f39a89b63e to our version of mkcommit()
Anton Shestakov <av6@dwimlabs.net>
parents:
5911
diff
changeset
|
4 name="$1" |
51249e4e9025
tests: port upstream 86f39a89b63e to our version of mkcommit()
Anton Shestakov <av6@dwimlabs.net>
parents:
5911
diff
changeset
|
5 shift |
51249e4e9025
tests: port upstream 86f39a89b63e to our version of mkcommit()
Anton Shestakov <av6@dwimlabs.net>
parents:
5911
diff
changeset
|
6 echo "$name" > "$name" |
51249e4e9025
tests: port upstream 86f39a89b63e to our version of mkcommit()
Anton Shestakov <av6@dwimlabs.net>
parents:
5911
diff
changeset
|
7 hg add "$name" |
51249e4e9025
tests: port upstream 86f39a89b63e to our version of mkcommit()
Anton Shestakov <av6@dwimlabs.net>
parents:
5911
diff
changeset
|
8 hg ci -m "$name" "$@" |
2119
e1c26c632b6d
tests: adds simple test case for heads checking
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
9 } |
e1c26c632b6d
tests: adds simple test case for heads checking
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
10 |
e1c26c632b6d
tests: adds simple test case for heads checking
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
11 getid() { |
e1c26c632b6d
tests: adds simple test case for heads checking
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
12 hg log --hidden --template '{node}\n' --rev "$1" |
e1c26c632b6d
tests: adds simple test case for heads checking
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents:
diff
changeset
|
13 } |
6041
6b7ef731141b
tests: move the most often used glog alias to common.sh
Anton Shestakov <av6@dwimlabs.net>
parents:
6039
diff
changeset
|
14 |
6b7ef731141b
tests: move the most often used glog alias to common.sh
Anton Shestakov <av6@dwimlabs.net>
parents:
6039
diff
changeset
|
15 cat >> $HGRCPATH << EOF |
6b7ef731141b
tests: move the most often used glog alias to common.sh
Anton Shestakov <av6@dwimlabs.net>
parents:
6039
diff
changeset
|
16 [alias] |
6043
b1a04ff0f99e
tests: add \n to glog alias, just in case
Anton Shestakov <av6@dwimlabs.net>
parents:
6042
diff
changeset
|
17 glog = log -GT "{rev}:{node|short} {desc}\n ({bookmarks}) {phase} {instabilities}\n" |
6041
6b7ef731141b
tests: move the most often used glog alias to common.sh
Anton Shestakov <av6@dwimlabs.net>
parents:
6039
diff
changeset
|
18 EOF |