#21 Add implicit @1 to command 'untag'

- Extend interval assertions
- Add interval assertions to tests for command 'tag'
- Add interval assertions to tests for command 'untag'
This commit is contained in:
Thomas Lauf 2018-05-13 15:28:18 +02:00 committed by lauft
parent c595132a9c
commit 10dfa64cfa
5 changed files with 184 additions and 64 deletions

View file

@ -116,12 +116,11 @@ class TestDelete(TestCase):
j = self.t.export()
print(j)
self.assertEqual(len(j), 1)
self.assertInterval(
j[0],
'{:%Y%m%dT%H}0000Z'.format(now_utc-timedelta(hours=5)),
'{:%Y%m%dT%H}0000Z'.format(now_utc-timedelta(hours=4)),
['foo'],
'remaining interval')
self.assertClosedInterval(j[0],
expectedStart='{:%Y%m%dT%H}0000Z'.format(now_utc-timedelta(hours=5)),
expectedEnd='{:%Y%m%dT%H}0000Z'.format(now_utc-timedelta(hours=4)),
expectedTags=['foo'],
description='remaining interval')
if __name__ == "__main__":