summaryrefslogtreecommitdiff
path: root/python/subunit/tests
diff options
context:
space:
mode:
authorMatthew Treinish <mtreinish@kortar.org>2021-06-15 12:48:42 -0400
committerMatthew Treinish <mtreinish@kortar.org>2021-06-15 12:48:42 -0400
commitcf5ee567bedec28a6951c18098a5c3b96f192837 (patch)
treeafc2d0216bd852011b291b10f1af0eeafbcc8186 /python/subunit/tests
parent1dafb884e47f5fc26232672b01c2a9574577e7be (diff)
downloadsubunit-git-cf5ee567bedec28a6951c18098a5c3b96f192837.tar.gz
Revert "Merge pull request #17 from mtreinish/timestamp-output"
This reverts commit 1dafb884e47f5fc26232672b01c2a9574577e7be, reversing changes made to 7583ce28db20a0b2ad229a69175949e5a30586fe. This PR had completely broken tests, while I think the feature works it's blocking CI and preventing any merges. I'll rework the PR and resubmit after I get the unittests working.
Diffstat (limited to 'python/subunit/tests')
-rw-r--r--python/subunit/tests/test_output_filter.py63
1 files changed, 0 insertions, 63 deletions
diff --git a/python/subunit/tests/test_output_filter.py b/python/subunit/tests/test_output_filter.py
index 587fd06..0f61ac5 100644
--- a/python/subunit/tests/test_output_filter.py
+++ b/python/subunit/tests/test_output_filter.py
@@ -472,69 +472,6 @@ class StatusStreamResultTests(TestCase):
])
)
-class TimeStampTests(TestCase):
- scenarios = [
- (s, dict(status=s, option='--' + s)) for s in _FINAL_ACTIONS
- ]
-
- _dummy_timestamp = datetime.datetime(1914, 6, 28, 10, 45, 2, 0, UTC)
-
- def setUp(self):
- super(TimeStampTests, self).setUp()
- self.patch(_o, 'create_timestamp', lambda: self._dummy_timestamp)
- self.test_id = self.getUniqueString()
-
- def test_no_timestamps(self):
- result = get_result_for([self.option, self.test_id, f.name])
- self.assertThat(
- result._events,
- MatchesListwise([
- MatchesStatusCall(call='startTestRun'),
- MatchesStatusCall(test_id=self.test_id, timestamp=self._dummy_timestamp),
- MatchesStatusCall(test_id=self.test_id, timestamp=None),
- MatchesStatusCall(call='stopTestRun'),
- ]))
-
- def test_only_start_timestamp(self):
- timestamp = datetime.datetime.utcnow()
- result = get_result_for([self.option, self.test_id, f.name,
- '--start-time', timestamp.isoformat()])
- self.assertThat(
- result._events,
- MatchesListwise([
- MatchesStatusCall(call='startTestRun'),
- MatchesStatusCall(test_id=self.test_id, timestamp=timestamp),
- MatchesStatusCall(test_id=self.test_id, timestamp=None),
- MatchesStatusCall(call='stopTestRun'),
- ]))
-
- def test_only_stop_timestamp(self):
- timestamp = datetime.datetime.utcnow()
- result = get_result_for([self.option, self.test_id, f.name,
- '--stop-time', timestamp.isoformat()])
- self.assertThat(
- result._events,
- MatchesListwise([
- MatchesStatusCall(call='startTestRun'),
- MatchesStatusCall(test_id=self.test_id, timestamp=self._dummy_timestamp),
- MatchesStatusCall(test_id=self.test_id, timestamp=timestamp),
- MatchesStatusCall(call='stopTestRun'),
- ]))
-
- def test_start_and_stop_timestamp(self):
- timestamp_start = datetime.datetime.utcnow()
- timestamp_stop = timestamp_start + datetime.timedelta(minutes=5)
- result = get_result_for([self.option, self.test_id, f.name,
- '--start-time', timestamp_start.isoformat(),
- '--stop-time', timestamp_stop.isoformat()])
- self.assertThat(
- result._events,
- MatchesListwise([
- MatchesStatusCall(call='startTestRun'),
- MatchesStatusCall(test_id=self.test_id, timestamp=timestamp_start),
- MatchesStatusCall(test_id=self.test_id, timestamp=timestamp_stop),
- MatchesStatusCall(call='stopTestRun'),
- ]))
class FileDataTests(TestCase):