diff options
| author | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2022-02-08 12:27:04 +0100 |
|---|---|---|
| committer | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2022-02-08 19:25:02 +0100 |
| commit | 3278c31fa59b41d03aea167f4cf85f4ddf7f848d (patch) | |
| tree | 0c80b4868391296335580242c8e65052a4f62a6b /tests/template_tests/syntax_tests/test_load.py | |
| parent | 6a682b38e75d4c975b4c4493565a59f1bc14397c (diff) | |
[4.0.x] Refs #33476 -- Refactored code to strictly match 88 characters line length.
Backport of 7119f40c9881666b6f9b5cf7df09ee1d21cc8344 from main.
Diffstat (limited to 'tests/template_tests/syntax_tests/test_load.py')
| -rw-r--r-- | tests/template_tests/syntax_tests/test_load.py | 24 |
1 files changed, 19 insertions, 5 deletions
diff --git a/tests/template_tests/syntax_tests/test_load.py b/tests/template_tests/syntax_tests/test_load.py index ae5f1d4b48..a13871b247 100644 --- a/tests/template_tests/syntax_tests/test_load.py +++ b/tests/template_tests/syntax_tests/test_load.py @@ -12,7 +12,9 @@ class LoadTagTests(SimpleTestCase): @setup( { - "load01": '{% load testtags subpackage.echo %}{% echo test %} {% echo2 "test" %}' + "load01": ( + '{% load testtags subpackage.echo %}{% echo test %} {% echo2 "test" %}' + ) } ) def test_load01(self): @@ -64,24 +66,36 @@ class LoadTagTests(SimpleTestCase): @setup({"load08": "{% load echo other_echo bad_tag from %}"}) def test_load08(self): - msg = "'echo' is not a registered tag library. Must be one of:\nsubpackage.echo\ntesttags" + msg = ( + "'echo' is not a registered tag library. Must be one of:\n" + "subpackage.echo\ntesttags" + ) with self.assertRaisesMessage(TemplateSyntaxError, msg): self.engine.get_template("load08") @setup({"load09": "{% load from testtags %}"}) def test_load09(self): - msg = "'from' is not a registered tag library. Must be one of:\nsubpackage.echo\ntesttags" + msg = ( + "'from' is not a registered tag library. Must be one of:\n" + "subpackage.echo\ntesttags" + ) with self.assertRaisesMessage(TemplateSyntaxError, msg): self.engine.get_template("load09") @setup({"load10": "{% load echo from bad_library %}"}) def test_load10(self): - msg = "'bad_library' is not a registered tag library. Must be one of:\nsubpackage.echo\ntesttags" + msg = ( + "'bad_library' is not a registered tag library. Must be one of:\n" + "subpackage.echo\ntesttags" + ) with self.assertRaisesMessage(TemplateSyntaxError, msg): self.engine.get_template("load10") @setup({"load12": "{% load subpackage.missing %}"}) def test_load12(self): - msg = "'subpackage.missing' is not a registered tag library. Must be one of:\nsubpackage.echo\ntesttags" + msg = ( + "'subpackage.missing' is not a registered tag library. Must be one of:\n" + "subpackage.echo\ntesttags" + ) with self.assertRaisesMessage(TemplateSyntaxError, msg): self.engine.get_template("load12") |
