mirror of
https://github.com/GothenburgBitFactory/timewarrior.git
synced 2025-06-26 10:54:28 +02:00
TI-62: Fix test for invalid command
This commit is contained in:
parent
f65c672b73
commit
01a3c8e3f6
1 changed files with 5 additions and 3 deletions
|
@ -51,6 +51,7 @@ from basetest import Timew, TestCase
|
||||||
# self.assertNotRegexpMatches(text, pattern)
|
# self.assertNotRegexpMatches(text, pattern)
|
||||||
# self.tap("")
|
# self.tap("")
|
||||||
|
|
||||||
|
|
||||||
class TestCLI(TestCase):
|
class TestCLI(TestCase):
|
||||||
def setUp(self):
|
def setUp(self):
|
||||||
"""Executed before each test in the class"""
|
"""Executed before each test in the class"""
|
||||||
|
@ -68,9 +69,10 @@ class TestCLI(TestCase):
|
||||||
self.assertIn("Tracking FOO", out)
|
self.assertIn("Tracking FOO", out)
|
||||||
|
|
||||||
def test_TimeWarrior_with_invalid_command(self):
|
def test_TimeWarrior_with_invalid_command(self):
|
||||||
"""Call a non-existing TimeWarrior command"""
|
"""Call a non-existing TimeWarrior command should be an error"""
|
||||||
code, out, err = self.t("bogus")
|
code, out, err = self.t.runError("bogus")
|
||||||
self.assertIn("'bogus' is not a timew command. See 'timew help'.", out)
|
self.assertIn("'bogus' is not a timew command. See 'timew help'.", err)
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
from simpletap import TAPTestRunner
|
from simpletap import TAPTestRunner
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue