Fixing a broken test in Python 2.6

This commit is contained in:
Ryan Petrello
2012-03-17 15:59:57 -04:00
parent 87e8f87e3b
commit 056288141c

View File

@@ -26,8 +26,11 @@ class TestCommandRunner(unittest.TestCase):
def test_run(self):
from pecan.commands import CommandRunner
runner = CommandRunner()
with self.assertRaises(RuntimeError):
runner.run(['serve', 'missing_file.py'])
self.assertRaises(
RuntimeError,
runner.run,
['serve', 'missing_file.py']
)
class TestCreateCommand(unittest.TestCase):