Cédric Krier pushed to branch branch/default at Tryton / Relatorio
Commits:
379c4a54 by Cédric Krier at 2022-12-27T11:16:08+01:00
Fix flake8
- - - - -
2 changed files:
- examples/common.py
- relatorio/tests/test_odt.py
Changes:
=====================================
examples/common.py
=====================================
@@ -5,7 +5,7 @@
@property
def total(self):
- return sum(l['amount'] for l in self['lines'])
+ return sum(line['amount'] for line in self['lines'])
@property
def vat(self):
=====================================
relatorio/tests/test_odt.py
=====================================
@@ -100,7 +100,7 @@
<text:a xlink:href="relatorio://foo">foo</text:a>
</text:p>
</table:table-cell>
- </xml>'''
+ </xml>''' # noqa: E501
interpolated = self.oot.insert_directives(xml)
root_interpolated = lxml.etree.parse(interpolated).getroot()
cell = root_interpolated[0]
@@ -122,7 +122,7 @@
</text:p>
<text:p>bar</text:p>
</table:table-cell>
- </xml>'''
+ </xml>''' # noqa: E501
interpolated = self.oot.insert_directives(xml)
root_interpolated = lxml.etree.parse(interpolated).getroot()
cell = root_interpolated[0]
@@ -143,7 +143,7 @@
<text:a xlink:href="relatorio://foo">foo</text:a>
</text:p>
</table:table-cell>
- </xml>'''
+ </xml>''' # noqa: E501
interpolated = self.oot.insert_directives(xml)
root_interpolated = lxml.etree.parse(interpolated).getroot()
cell = root_interpolated[0]
@@ -164,7 +164,7 @@
bar
</text:p>
</table:table-cell>
- </xml>'''
+ </xml>''' # noqa: E501
interpolated = self.oot.insert_directives(xml)
root_interpolated = lxml.etree.parse(interpolated).getroot()
cell = root_interpolated[0]
@@ -183,7 +183,7 @@
<text:placeholder><attrs
text:p="{}"></text:placeholder>
after
</text:p>
- </xml>'''
+ </xml>''' # noqa: E501
interpolated = self.oot.insert_directives(xml)
root_interpolated = lxml.etree.parse(interpolated).getroot()
paragraph = root_interpolated[0]
@@ -197,7 +197,7 @@
<text:a xlink:href="relatorio://attrs
text:a="{'{urn:xlink}href': 'foo'}"">
test
</text:a>
- </xml>'''
+ </xml>''' # noqa: E501
interpolated = self.oot.insert_directives(xml)
root_interpolated = lxml.etree.parse(interpolated).getroot()
child = root_interpolated[0]
View it on Heptapod:
https://foss.heptapod.net/tryton/relatorio/-/commit/379c4a54d2747f93295a6fa0a02ac8b10f77cf64
--
View it on Heptapod:
https://foss.heptapod.net/tryton/relatorio/-/commit/379c4a54d2747f93295a6fa0a02ac8b10f77cf64
You're receiving this email because of your account on foss.heptapod.net.