tests: Use updated unittest method

This commit is contained in:
Tomas Babej 2020-11-20 23:59:56 -05:00 committed by Paul Beckingham
parent 407d66d681
commit 02db131fa1
50 changed files with 315 additions and 315 deletions

View file

@ -50,7 +50,7 @@ class TestGC(TestCase):
self.t.config("gc", "0")
self.t("1 done")
code, out, err = self.t("gctest")
self.assertRegexpMatches(out, "1\s+one", "should still have ID")
self.assertRegex(out, "1\s+one", "should still have ID")
def test_gc_off_mod(self):
"""mod by ID after done with gc off"""
@ -59,7 +59,7 @@ class TestGC(TestCase):
self.t("gctest")
self.t("2 mod +TWO")
code, out, err = self.t("gctest")
self.assertRegexpMatches(out, "2\s+two\s+TWO", "modified 'two'")
self.assertRegex(out, "2\s+two\s+TWO", "modified 'two'")
def test_gc_on_id(self):
"""IDs reshuffle after report when GC on"""
@ -67,8 +67,8 @@ class TestGC(TestCase):
self.t("1 done")
self.t("2 mod +TWO")
code, out, err = self.t("gctest")
self.assertRegexpMatches(out, "1\s+two\s+TWO")
self.assertRegexpMatches(out, "2\s+three")
self.assertRegex(out, "1\s+two\s+TWO")
self.assertRegex(out, "2\s+three")
if __name__ == "__main__":