# HG changeset patch # User Augie Fackler # Date 1536988417 14400 # Node ID 10c53b2e9d52dda60b17fa8d2a2fa4f5be9785d8 # Parent d2c81e83de2ac771943f1793c5f0c4d554c87dc8 phabricator: add tests of templatekeyword Having tests is paying off: I found a bug and now it'll be easy to fix! Differential Revision: https://phab.mercurial-scm.org/D4603 diff -r d2c81e83de2a -r 10c53b2e9d52 tests/test-phabricator.t --- a/tests/test-phabricator.t Sat Sep 15 00:46:17 2018 -0400 +++ b/tests/test-phabricator.t Sat Sep 15 01:13:37 2018 -0400 @@ -64,4 +64,16 @@ D4596 - updated - f70265671c65: create alpha for phabricator test D4597 - created - 1a5640df7bbf: create beta for phabricator test saved backup bundle to $TESTTMP/repo/.hg/strip-backup/1a5640df7bbf-6daf3e6e-phabsend.hg + +Template keywords + $ hg log -T'{rev} {phabreview|json}\n' + 1 {"id": "D4597", "url": "https://phab.mercurial-scm.org/D4597"} + 0 {"id": "D4596", "url": "https://phab.mercurial-scm.org/D4596"} + +BUG: this should work, but doesn't. + $ hg log -T'{rev} {phabreview.url}\n' + hg: parse error: {* 'D4597'*} is not a dictionary (glob) + (keyword 'phabreview' does not support member operation) + [255] + $ cd ..