Mercurial > hg
comparison tests/test-commit.t @ 48370:45a073af50a2
errors: use detailed error for invalid commit-extras argument
Differential Revision: https://phab.mercurial-scm.org/D11831
author | Martin von Zweigbergk <martinvonz@google.com> |
---|---|
date | Mon, 22 Nov 2021 17:21:55 -0800 |
parents | 35f1ecd84bd0 |
children | 42d2b31cee0b |
comparison
equal
deleted
inserted
replaced
48369:35f1ecd84bd0 | 48370:45a073af50a2 |
---|---|
132 $ hg status | 132 $ hg status |
133 ? quux | 133 ? quux |
134 $ hg add quux | 134 $ hg add quux |
135 $ hg commit -m "adding internal used extras" --extra amend_source=hash | 135 $ hg commit -m "adding internal used extras" --extra amend_source=hash |
136 abort: key 'amend_source' is used internally, can't be set manually | 136 abort: key 'amend_source' is used internally, can't be set manually |
137 [255] | 137 [10] |
138 $ hg commit -m "special chars in extra" --extra id@phab=214 | 138 $ hg commit -m "special chars in extra" --extra id@phab=214 |
139 abort: keys can only contain ascii letters, digits, '_' and '-' | 139 abort: keys can only contain ascii letters, digits, '_' and '-' |
140 [255] | 140 [10] |
141 $ hg commit -m "empty key" --extra =value | 141 $ hg commit -m "empty key" --extra =value |
142 abort: unable to parse '=value', keys can't be empty | 142 abort: unable to parse '=value', keys can't be empty |
143 [255] | 143 [10] |
144 $ hg commit -m "adding extras" --extra sourcehash=foo --extra oldhash=bar | 144 $ hg commit -m "adding extras" --extra sourcehash=foo --extra oldhash=bar |
145 $ hg log -r . -T '{extras % "{extra}\n"}' | 145 $ hg log -r . -T '{extras % "{extra}\n"}' |
146 branch=default | 146 branch=default |
147 oldhash=bar | 147 oldhash=bar |
148 sourcehash=foo | 148 sourcehash=foo |