From 9c19aff7c7561e3a82978a272ecdaad40dda5c00 Mon Sep 17 00:00:00 2001 From: django-bot Date: Thu, 3 Feb 2022 20:24:19 +0100 Subject: Refs #33476 -- Reformatted code with Black. --- tests/template_tests/syntax_tests/test_debug.py | 47 ++++++++++++------------- 1 file changed, 23 insertions(+), 24 deletions(-) (limited to 'tests/template_tests/syntax_tests/test_debug.py') diff --git a/tests/template_tests/syntax_tests/test_debug.py b/tests/template_tests/syntax_tests/test_debug.py index 2f527b44ae..cbd71fa51a 100644 --- a/tests/template_tests/syntax_tests/test_debug.py +++ b/tests/template_tests/syntax_tests/test_debug.py @@ -6,41 +6,40 @@ from ..utils import setup @override_settings(DEBUG=True) class DebugTests(SimpleTestCase): - @override_settings(DEBUG=False) - @setup({'non_debug': '{% debug %}'}) + @setup({"non_debug": "{% debug %}"}) def test_non_debug(self): - output = self.engine.render_to_string('non_debug', {}) - self.assertEqual(output, '') + output = self.engine.render_to_string("non_debug", {}) + self.assertEqual(output, "") - @setup({'modules': '{% debug %}'}) + @setup({"modules": "{% debug %}"}) def test_modules(self): - output = self.engine.render_to_string('modules', {}) + output = self.engine.render_to_string("modules", {}) self.assertIn( - ''django': <module 'django' ', + "'django': <module 'django' ", output, ) - @setup({'plain': '{% debug %}'}) + @setup({"plain": "{% debug %}"}) def test_plain(self): - output = self.engine.render_to_string('plain', {'a': 1}) - self.assertTrue(output.startswith( - '{'a': 1}' - '{'False': False, 'None': None, ' - ''True': True}\n\n{' - )) + output = self.engine.render_to_string("plain", {"a": 1}) + self.assertTrue( + output.startswith( + "{'a': 1}" + "{'False': False, 'None': None, " + "'True': True}\n\n{" + ) + ) - @setup({'non_ascii': '{% debug %}'}) + @setup({"non_ascii": "{% debug %}"}) def test_non_ascii(self): group = Group(name="清風") - output = self.engine.render_to_string('non_ascii', {'group': group}) - self.assertTrue(output.startswith( - '{'group': <Group: 清風>}' - )) + output = self.engine.render_to_string("non_ascii", {"group": group}) + self.assertTrue(output.startswith("{'group': <Group: 清風>}")) - @setup({'script': '{% debug %}'}) + @setup({"script": "{% debug %}"}) def test_script(self): - output = self.engine.render_to_string('script', {'frag': '