summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorTim Graham <timograham@gmail.com>2014-04-10 09:43:55 -0400
committerTim Graham <timograham@gmail.com>2014-04-10 09:44:43 -0400
commitddd25b280f69ffcb5eb7ab2695c6094256090947 (patch)
tree5d423825ab9d8d77d82d9df6321d07a8ddab3213 /tests
parent32e62374506827723423471a115e6b25313ed887 (diff)
[1.7.x] Fixed #22194 -- Added --list-tags option to check command.
Thanks Elvard for the patch. Backport of 395d75ea6b from master
Diffstat (limited to 'tests')
-rw-r--r--tests/check_framework/tests.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/check_framework/tests.py b/tests/check_framework/tests.py
index c770ee517b..af407f5c7e 100644
--- a/tests/check_framework/tests.py
+++ b/tests/check_framework/tests.py
@@ -194,6 +194,16 @@ class CheckCommandTests(TestCase):
def test_invalid_tag(self):
self.assertRaises(CommandError, call_command, 'check', tags=['missingtag'])
+ @override_system_checks([simple_system_check])
+ def test_list_tags_empty(self):
+ call_command('check', list_tags=True)
+ self.assertEqual('\n', sys.stdout.getvalue())
+
+ @override_system_checks([tagged_system_check])
+ def test_list_tags(self):
+ call_command('check', list_tags=True)
+ self.assertEqual('simpletag\n', sys.stdout.getvalue())
+
def custom_error_system_check(app_configs, **kwargs):
return [