Fixed test cases so they're not machine-specific
authorAaron Bentley <aaron.bentley@utoronto.ca>
Sun, 20 Mar 2005 19:43:09 +0000 (19:43 +0000)
committerAaron Bentley <aaron.bentley@utoronto.ca>
Sun, 20 Mar 2005 19:43:09 +0000 (19:43 +0000)
libbe/cmdutil.py
libbe/plugin.py

index b550eb0df73722340a107246f346699e2d913702..7ce8ac2450622b9ffb0709dc6f144276d3faa381 100644 (file)
@@ -69,8 +69,8 @@ def get_command(command_name):
     File "/home/abentley/be/libbe/cmdutil.py", line 60, in get_command
       raise UserError("Unknown command %s" % command_name)
     UserError: Unknown command asdf
-    >>> get_command("list")
-    <module 'becommands.list' from '/home/abentley/be/becommands/list.pyc'>
+    >>> repr(get_command("list")).startswith("<module 'becommands.list' from ")
+    True
     """
     cmd = plugin.get_plugin("becommands", command_name.replace("-", "_"))
     if cmd is None:
index 5f0fa4de53d42580153d9e15775a3bfc72ec04dc..f567cbb50c5195cf6aa74e7668f718d139f75af1 100644 (file)
@@ -26,8 +26,9 @@ def get_plugin(prefix, name):
     """
     >>> get_plugin("becommands", "asdf") is None
     True
-    >>> get_plugin("becommands", "list")
-    <module 'becommands.list' from '/home/abentley/be/becommands/list.pyc'>
+    >>> q = repr(get_plugin("becommands", "list"))
+    >>> q.startswith("<module 'becommands.list' from ")
+    True
     """
     dirprefix = '/'.join(prefix.split('.'))
     command_path = os.path.join(plugin_path, dirprefix, name+".py")