pylint reports
tests/test_includehandler.py:343:0: C0330: Wrong hanging indentation before block (add 4 spaces).
'x.yml': header.format(''' includes: ["y.yml", "z.yml"]
^ | (bad-continuation)
tests/test_includehandler.py:345:0: C0330: Wrong hanging indentation before block (add 4 spaces).
os.path.abspath('y.yml'): header.format(''' includes: ["z.yml"]
^ | (bad-continuation)
tests/test_includehandler.py:347:0: C0330: Wrong hanging indentation before block (add 4 spaces).
os.path.abspath('z.yml'): header.format('''
^ | (bad-continuation)
tests/test_includehandler.py | 12 +++++++-----
1 file changed, 7 insertions(+), 5 deletions(-)
diff --git a/tests/test_includehandler.py b/tests/test_includehandler.py
index ed1fe31d9742..82c61e437074 100644
--- a/tests/test_includehandler.py
+++ b/tests/test_includehandler.py
@@ -339,13 +339,15 @@ v2: y
# disable schema validation for this test:
monkeypatch.setattr(includehandler, 'CONFIGSCHEMA', {})
header = self.__class__.header
- with patch_open(includehandler, dictionary={
- 'x.yml': header.format(''' includes: ["y.yml", "z.yml"]
+ data = {'x.yml':
+ header.format(''' includes: ["y.yml", "z.yml"]
v: {v1: x, v2: x}'''),
- os.path.abspath('y.yml'): header.format(''' includes: ["z.yml"]
+ os.path.abspath('y.yml'):
+ header.format(''' includes: ["z.yml"]
v: {v2: y, v3: y, v5: y}'''),
- os.path.abspath('z.yml'): header.format('''
-v: {v3: z, v4: z}''')}):
+ os.path.abspath('z.yml'): header.format('''
+v: {v3: z, v4: z}''')}
+ with patch_open(includehandler, dictionary=data):
ginc = includehandler.GlobalIncludes('x.yml')
config, _ = ginc.get_config()
keys = list(config['v'].keys())
--
2.17.1