diff options
author | Enrico Granata <egranata@apple.com> | 2016-03-31 01:10:54 +0000 |
---|---|---|
committer | Enrico Granata <egranata@apple.com> | 2016-03-31 01:10:54 +0000 |
commit | 45d0e238d5854d33facd8600cfe8e62556850d8a (patch) | |
tree | dabd7e12b5e4f0e8f54cf5a9dac185f763be63c9 /lldb/packages/Python/lldbsuite/test/help | |
parent | d0a643e7dc653a0578865638cd10b23e7dd5f577 (diff) | |
download | bcm5719-llvm-45d0e238d5854d33facd8600cfe8e62556850d8a.tar.gz bcm5719-llvm-45d0e238d5854d33facd8600cfe8e62556850d8a.zip |
Add --help and --long-help options to 'command alias' such that one can now specify a help string for an alias as they are defining it
llvm-svn: 264980
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/help')
-rw-r--r-- | lldb/packages/Python/lldbsuite/test/help/TestHelp.py | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/lldb/packages/Python/lldbsuite/test/help/TestHelp.py b/lldb/packages/Python/lldbsuite/test/help/TestHelp.py index 92bb9fa5f21..ce0682d8f24 100644 --- a/lldb/packages/Python/lldbsuite/test/help/TestHelp.py +++ b/lldb/packages/Python/lldbsuite/test/help/TestHelp.py @@ -198,3 +198,16 @@ class HelpCommandTestCase(TestBase): "Try 'help' to see a current list of commands.", "Try 'apropos thisisnotadebuggercommand' for a list of related commands.", "Try 'type lookup thisisnotadebuggercommand' for information on types, methods, functions, modules, etc."]) + + @no_debug_info_test + def test_custom_help_alias(self): + """Test that aliases pick up custom help text.""" + def cleanup(): + self.runCmd('command unalias afriendlyalias', check=False) + self.runCmd('command unalias averyfriendlyalias', check=False) + + self.addTearDownHook(cleanup) + self.runCmd('command alias --help "I am a friendly alias" -- afriendlyalias help') + self.expect("help afriendlyalias", matching=True, substrs = ['I am a friendly alias']) + self.runCmd('command alias --long-help "I am a very friendly alias" -- averyfriendlyalias help') + self.expect("help averyfriendlyalias", matching=True, substrs = ['I am a very friendly alias']) |