aboutsummaryrefslogtreecommitdiffstats
path: root/libbe/cmdutil.py
diff options
context:
space:
mode:
authorW. Trevor King <wking@drexel.edu>2009-07-10 17:58:49 -0400
committerW. Trevor King <wking@drexel.edu>2009-07-10 17:58:49 -0400
commitf0300038113e2754d83ee73f32a51072ad9b1f3b (patch)
treed0f0f0a8aaff5d812b77b78f82fda9ccabd5c7fe /libbe/cmdutil.py
parentc5da71a900d6263e29deb94d81aa22e6ba6f34ea (diff)
downloadbugseverywhere-f0300038113e2754d83ee73f32a51072ad9b1f3b.tar.gz
seems to work ;)
Diffstat (limited to 'libbe/cmdutil.py')
-rw-r--r--libbe/cmdutil.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/libbe/cmdutil.py b/libbe/cmdutil.py
index 7414e46..ada0423 100644
--- a/libbe/cmdutil.py
+++ b/libbe/cmdutil.py
@@ -56,9 +56,11 @@ def iter_commands():
def get_command(command_name):
"""Retrieves the module for a user command
- >>> get_command("asdf")
- Traceback (most recent call last):
- UnknownCommand: Unknown command asdf
+ >>> try:
+ ... get_command("asdf")
+ ... except UnknownCommand, e:
+ ... print e
+ Unknown command asdf
>>> repr(get_command("list")).startswith("<module 'becommands.list' from ")
True
"""