mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-08-19 19:03:07 +02:00
tests: Use updated unittest method
This commit is contained in:
parent
407d66d681
commit
02db131fa1
50 changed files with 315 additions and 315 deletions
|
@ -54,19 +54,19 @@ class TestEnpassantMultiple(BaseTestEnpassant):
|
|||
def validate_info(self, id, desc):
|
||||
code, out, err = self.t((id, "info"))
|
||||
|
||||
self.assertRegexpMatches(
|
||||
self.assertRegex(
|
||||
out, "Status +Completed",
|
||||
msg="enpassant {0} status change".format(id),
|
||||
)
|
||||
self.assertRegexpMatches(
|
||||
self.assertRegex(
|
||||
out, "Priority +H",
|
||||
msg="enpassant {0} priority change".format(id),
|
||||
)
|
||||
self.assertRegexpMatches(
|
||||
self.assertRegex(
|
||||
out, "Tags +tag",
|
||||
msg="enpassant {0} tag change".format(id),
|
||||
)
|
||||
self.assertRegexpMatches(
|
||||
self.assertRegex(
|
||||
out, "Description +{0}".format(desc),
|
||||
msg="enpassant {0} description change".format(id),
|
||||
)
|
||||
|
@ -95,27 +95,27 @@ class TestEnpassant(BaseTestEnpassant):
|
|||
def perform_action(self, action):
|
||||
self.t(("1", action, "oneanno"))
|
||||
code, out, err = self.t("1 info")
|
||||
self.assertRegexpMatches(out, "Description +one\n[0-9: -]+ oneanno",
|
||||
self.assertRegex(out, "Description +one\n[0-9: -]+ oneanno",
|
||||
msg="{0} enpassant annotation".format(action))
|
||||
|
||||
self.t(("2", action, "/two/TWO/"))
|
||||
code, out, err = self.t("2 info")
|
||||
self.assertRegexpMatches(out, "Description +TWO",
|
||||
self.assertRegex(out, "Description +TWO",
|
||||
msg="{0} enpassant modify".format(action))
|
||||
|
||||
self.t(("3", action, "+threetag"))
|
||||
code, out, err = self.t("3 info")
|
||||
self.assertRegexpMatches(out, "Tags +threetag",
|
||||
self.assertRegex(out, "Tags +threetag",
|
||||
msg="{0} enpassant tag".format(action))
|
||||
|
||||
self.t(("4", action, "pri:H"))
|
||||
code, out, err = self.t("4 info")
|
||||
self.assertRegexpMatches(out, "Priority +H",
|
||||
self.assertRegex(out, "Priority +H",
|
||||
msg="{0} enpassant priority".format(action))
|
||||
|
||||
self.t(("5", action, "pro:PROJ"))
|
||||
code, out, err = self.t("5 info")
|
||||
self.assertRegexpMatches(out, "Project +PROJ",
|
||||
self.assertRegex(out, "Project +PROJ",
|
||||
msg="{0} enpassant project".format(action))
|
||||
|
||||
def test_done(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue