Mercurial > hg-stable
diff tests/test-help.t @ 28828:3640c1702c43
help: report source of aliases
author | timeless <timeless@mozdev.org> |
---|---|
date | Fri, 08 Apr 2016 18:35:49 +0000 |
parents | d001d6d27570 |
children | eb017d52899d |
line wrap: on
line diff
--- a/tests/test-help.t Fri Apr 08 16:05:52 2016 +0000 +++ b/tests/test-help.t Fri Apr 08 18:35:49 2016 +0000 @@ -673,10 +673,50 @@ > def nohelp(ui, *args, **kwargs): > pass > + > def uisetup(ui): + > ui.setconfig('alias', 'shellalias', '!echo hi', 'helpext') + > ui.setconfig('alias', 'hgalias', 'summary', 'helpext') + > > EOF $ echo '[extensions]' >> $HGRCPATH $ echo "helpext = `pwd`/helpext.py" >> $HGRCPATH +Test for aliases + + $ hg help hgalias + hg hgalias [--remote] + + alias for: hg summary + + summarize working directory state + + This generates a brief summary of the working directory state, including + parents, branch, commit status, phase and available updates. + + With the --remote option, this will check the default paths for incoming + and outgoing changes. This can be time-consuming. + + Returns 0 on success. + + defined by: helpext + + options: + + --remote check for push and pull + + (some details hidden, use --verbose to show complete help) + + $ hg help shellalias + hg shellalias + + shell alias for: + + echo hi + + defined by: helpext + + (some details hidden, use --verbose to show complete help) + Test command with no help text $ hg help nohelp @@ -2064,6 +2104,13 @@ show help for a given topic or a help overview </td></tr> <tr><td> + <a href="/help/hgalias"> + hgalias + </a> + </td><td> + summarize working directory state + </td></tr> + <tr><td> <a href="/help/identify"> identify </a> @@ -2155,6 +2202,13 @@ print the root (top) of the current working directory </td></tr> <tr><td> + <a href="/help/shellalias"> + shellalias + </a> + </td><td> + (no help text available) + </td></tr> + <tr><td> <a href="/help/tag"> tag </a>