mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-06-26 10:54:26 +02:00
Unit Tests
- Made test more portable.
This commit is contained in:
parent
8e31ae2075
commit
5a81fda835
1 changed files with 2 additions and 1 deletions
|
@ -3,6 +3,7 @@
|
||||||
|
|
||||||
import sys
|
import sys
|
||||||
import os
|
import os
|
||||||
|
from datetime import datetime
|
||||||
import unittest
|
import unittest
|
||||||
|
|
||||||
# Ensure python finds the local simpletap module
|
# Ensure python finds the local simpletap module
|
||||||
|
@ -19,7 +20,7 @@ class Test1445(TestCase):
|
||||||
self.t.config('alias.when', 'execute date')
|
self.t.config('alias.when', 'execute date')
|
||||||
code, out, err = self.t(('when',))
|
code, out, err = self.t(('when',))
|
||||||
self.assertEqual(0, code, "Exit code was non-zero ({0})".format(code))
|
self.assertEqual(0, code, "Exit code was non-zero ({0})".format(code))
|
||||||
self.assertRegexpMatches(out, r'... ... \d+ \d+:\d+:\d+ ... 20\d\d')
|
self.assertIn(str(datetime.now().year), out)
|
||||||
|
|
||||||
def test_alias_multi_word(self):
|
def test_alias_multi_word(self):
|
||||||
"""Verify multi-word aliases"""
|
"""Verify multi-word aliases"""
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue