Commit 64c13410 authored by Jérome Perrin's avatar Jérome Perrin

plantuml/test: python3 compatibility

parent bc90aa81
......@@ -37,6 +37,7 @@ import plantuml
from slapos.recipe.librecipe import generateHashFromFiles
from slapos.testing.testcase import makeModuleSetUpAndTestCaseClass
from six.moves import zip
setUpModule, PlantUMLTestCase = makeModuleSetUpAndTestCaseClass(
......@@ -56,7 +57,7 @@ class TestSimpleDiagram(PlantUMLTestCase):
"""Assert images difference between images is less than `tolerance` %.
taken from https://rosettacode.org/wiki/Percentage_difference_between_images
"""
pairs = zip(i1.getdata(), i2.getdata())
pairs = list(zip(i1.getdata(), i2.getdata()))
if len(i1.getbands()) == 1:
# for gray-scale jpegs
dif = sum(abs(p1-p2) for p1,p2 in pairs)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment