mirror of
https://github.com/GothenburgBitFactory/timewarrior.git
synced 2025-06-26 10:54:28 +02:00
Add quotes around expected/actual string in assertion message
Signed-off-by: Thomas Lauf <thomas.lauf@tngtech.com>
This commit is contained in:
parent
7fe4d2ff39
commit
6d09d8fe13
1 changed files with 3 additions and 3 deletions
|
@ -63,14 +63,14 @@ class TestCase(BaseTestCase):
|
|||
"tags",
|
||||
expectedTags,
|
||||
description,
|
||||
"{} of {} do not match (expected: {}, actual: {})")
|
||||
"{} of {} do not match (expected: '{}', actual: '{}')")
|
||||
if expectedAnnotation:
|
||||
self.assertKeyExists(interval, "annotation", description, "{} is not annotated")
|
||||
self.assertIntervalValue(interval,
|
||||
"annotation",
|
||||
expectedAnnotation,
|
||||
description,
|
||||
"{} of {} do not match (expected: {}, actual: {})")
|
||||
"{} of {} do not match (expected: '{}', actual: '{}')")
|
||||
|
||||
def assertKeyExists(self, interval, key, description, message):
|
||||
self.assertTrue(key in interval, message.format(description))
|
||||
|
@ -86,7 +86,7 @@ class TestCase(BaseTestCase):
|
|||
key,
|
||||
expected,
|
||||
description,
|
||||
"{} time of {} does not match (expected: {}, actual: {})")
|
||||
"{} time of {} does not match (expected: '{}', actual: '{}')")
|
||||
|
||||
def assertIntervalValue(self, interval, key, expected, description, message):
|
||||
actual = interval[key]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue