Skip to content

Commit cbbe759

Browse files
committed
added imshow visual test for percy
1 parent 3ca829c commit cbbe759

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

test/percy/plotly-express.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -341,6 +341,14 @@
341341
)
342342
fig.write_html(os.path.join(dir_name, "line_ternary.html"))
343343

344+
import plotly.express as px
345+
import numpy as np
346+
img_rgb = np.array([[[255, 0, 0], [0, 255, 0], [0, 0, 255]],
347+
[[0, 255, 0], [0, 0, 255], [255, 0, 0]]
348+
], dtype=np.uint8)
349+
fig = px.imshow(img_rgb)
350+
fig.write_html(os.path.join(dir_name, "imshow.html"))
351+
344352
# #### 3D Coordinates
345353

346354
import plotly.express as px

0 commit comments

Comments
 (0)