Commit 4c2fa977 authored by Jérome Perrin's avatar Jérome Perrin

Plantuml: upgrade

The version we were using did not support timing diagrams.

Update to a more recent version where it's supported.

See merge request nexedi/slapos!778
parents bd062c1d fd49f9c1
...@@ -27,8 +27,9 @@ output = ${buildout:directory}/${:_buildout_section_name_} ...@@ -27,8 +27,9 @@ output = ${buildout:directory}/${:_buildout_section_name_}
[plantuml.war] [plantuml.war]
recipe = slapos.recipe.build:download recipe = slapos.recipe.build:download
url = https://downloads.sourceforge.net/project/plantuml/1.2018.13/plantuml.1.2018.13.war url = https://sourceforge.net/projects/plantuml/files/1.2020.15/plantuml.1.2020.15.war
md5sum = cda05c8163237de039d777c197b3d282 md5sum = ed203cb3b90df8f77492fa36ea6490a5
[versions] [versions]
slapos.recipe.template = 4.4 slapos.recipe.template = 4.4
...@@ -87,6 +87,27 @@ class TestSimpleDiagram(PlantUMLTestCase, ImageComparisonTestCase): ...@@ -87,6 +87,27 @@ class TestSimpleDiagram(PlantUMLTestCase, ImageComparisonTestCase):
reference = Image.open(os.path.join(os.path.dirname(__file__), "data", "test_class_diagram.png")) reference = Image.open(os.path.join(os.path.dirname(__file__), "data", "test_class_diagram.png"))
self.assertImagesSimilar(Image.open(BytesIO(png)), reference) self.assertImagesSimilar(Image.open(BytesIO(png)), reference)
def test_timing_diagram(self):
png = self.plantuml.processes(textwrap.dedent("""\
@startuml
robust "Web Browser" as WB
concise "Web User" as WU
@0
WU is Idle
WB is Idle
@100
WU is Waiting
WB is Processing
@300
WB is Waiting
@enduml
"""))
reference = Image.open(os.path.join(os.path.dirname(__file__), "data", "test_timing_diagram.png"))
self.assertImagesSimilar(Image.open(BytesIO(png)), reference)
def test_fonts(self): def test_fonts(self):
"""Test slapos provided fonts are used""" """Test slapos provided fonts are used"""
png = self.plantuml.processes(textwrap.dedent("""\ png = self.plantuml.processes(textwrap.dedent("""\
......
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