mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-06-26 10:54:26 +02:00
Test: Added _config tests
This commit is contained in:
parent
130f98175a
commit
476561fb87
1 changed files with 15 additions and 0 deletions
|
@ -57,6 +57,21 @@ class TestConfiguration(TestCase):
|
|||
self.assertIn("unrecognized variables", out)
|
||||
self.assertIn(" foo\n", out)
|
||||
|
||||
def test_config_completion(self):
|
||||
"""verify that the '_config' command generates a full list"""
|
||||
code, out, err = self.t("_config")
|
||||
self.assertIn("_forcecolor", out) # first
|
||||
self.assertIn("xterm.title", out) # last
|
||||
|
||||
def test_config_nothing(self):
|
||||
"""Verify error handling with no args"""
|
||||
code, out, err = self.t.runError("config")
|
||||
self.assertIn("Specify the name of a config variable to modify.", err)
|
||||
|
||||
def test_config_no_change(self):
|
||||
"""Verify error handling with no change"""
|
||||
code, out, err = self.t.runError("config foo")
|
||||
self.assertIn("No entry named 'foo' found.", err)
|
||||
|
||||
if __name__ == "__main__":
|
||||
from simpletap import TAPTestRunner
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue