diff options
| author | Thomi Richards <thomi.richards@canonical.com> | 2013-11-19 12:34:53 +1300 |
|---|---|---|
| committer | Thomi Richards <thomi.richards@canonical.com> | 2013-11-19 12:34:53 +1300 |
| commit | 78a8d097a53203d717a653fe3184874bc988660f (patch) | |
| tree | 53127250ee8c529ca87ba7e78111a36f350a901e /python/subunit/tests | |
| parent | e30001daaf6ce2ee233ce856a87df4d16b389062 (diff) | |
| download | subunit-git-78a8d097a53203d717a653fe3184874bc988660f.tar.gz | |
Add support for tags.
Diffstat (limited to 'python/subunit/tests')
| -rw-r--r-- | python/subunit/tests/test_output_filter.py | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/python/subunit/tests/test_output_filter.py b/python/subunit/tests/test_output_filter.py index bddcc99..8b2f54b 100644 --- a/python/subunit/tests/test_output_filter.py +++ b/python/subunit/tests/test_output_filter.py @@ -89,6 +89,13 @@ class OutputFilterArgumentParserTests(TestCase): ) self.assertThat(args.mimetype, Equals("text/plain")) + def test_all_commands_accept_tags_argument(self): + for command in self._all_supported_commands: + args = safe_parse_arguments( + args=[command, 'foo', '--tags', "foo,bar,baz"] + ) + self.assertThat(args.tags, Equals(["foo","bar","baz"])) + class ByteStreamCompatibilityTests(TestCase): @@ -196,6 +203,20 @@ class ByteStreamCompatibilityTests(TestCase): ) ) + def test_tags_are_generated(self): + result = self._get_result_for( + ['exists', 'foo', '--tags', 'hello,world'] + ) + self.assertThat( + result._events[0], + MatchesCall( + call='status', + test_id='foo', + test_tags=set(['hello','world']), + timestamp=self._dummy_timestamp, + ) + ) + class FileChunkingTests(TestCase): |
