Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 2e66fb0

Browse filesBrowse files
committed
add actual image generation step in test
1 parent bdf8f05 commit 2e66fb0
Copy full SHA for 2e66fb0

File tree

Expand file treeCollapse file tree

1 file changed

+7
-0
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+7
-0
lines changed

‎tests/test_optional/test_kaleido/test_kaleido.py

Copy file name to clipboardExpand all lines: tests/test_optional/test_kaleido/test_kaleido.py
+7Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -230,6 +230,13 @@ def test_defaults():
230230
assert pio._kaleido.scope.topojson == "path/to/topojson/files/"
231231
assert pio._kaleido.scope.plotlyjs == "https://cdn.plot.ly/plotly-3.0.0.js"
232232

233+
# Set topojson default back to None
234+
# (otherwise image generation will fail)
235+
pio.defaults.topojson = None
236+
# Generate image for real and make sure it's an SVG
237+
result = test_fig.to_image(format="svg", validate=False)
238+
assert result.startswith(b"<svg")
239+
233240
finally:
234241
# Reset defaults to original values and check that they are restored
235242
pio.defaults.default_format = "png"

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.