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

Sign up
Appearance settings

Commit 673c19c

Browse files
Merge pull request #4743 from plotly/update-percy-tests
Update percy tests to use maps
2 parents aef15d0 + 38f8861 commit 673c19c

File tree

1 file changed

+8
-10
lines changed

1 file changed

+8
-10
lines changed

‎test/percy/plotly-express.py‎

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -384,7 +384,7 @@
384384

385385

386386
carshare = px.data.carshare()
387-
fig = px.scatter_mapbox(
387+
fig = px.scatter_map(
388388
carshare,
389389
lat="centroid_lat",
390390
lon="centroid_lon",
@@ -394,14 +394,12 @@
394394
size_max=15,
395395
zoom=10,
396396
)
397-
fig.write_html(os.path.join(dir_name, "scatter_mapbox.html"))
397+
fig.write_html(os.path.join(dir_name, "scatter_map.html"))
398398

399399

400400
carshare = px.data.carshare()
401-
fig = px.line_mapbox(
402-
carshare, lat="centroid_lat", lon="centroid_lon", color="peak_hour"
403-
)
404-
fig.write_html(os.path.join(dir_name, "line_mapbox.html"))
401+
fig = px.line_map(carshare, lat="centroid_lat", lon="centroid_lon", color="peak_hour")
402+
fig.write_html(os.path.join(dir_name, "line_map.html"))
405403

406404

407405
sample_geojson = {
@@ -419,23 +417,23 @@
419417
}
420418
],
421419
}
422-
fig = px.choropleth_mapbox(
420+
fig = px.choropleth_map(
423421
geojson=sample_geojson,
424422
locations=["the_polygon"],
425423
color=[10],
426424
zoom=6,
427425
)
428-
fig.write_html(os.path.join(dir_name, "choropleth_mapbox.html"), auto_play=False)
426+
fig.write_html(os.path.join(dir_name, "choropleth_map.html"), auto_play=False)
429427

430428

431429
carshare = px.data.carshare()
432-
fig = px.density_mapbox(
430+
fig = px.density_map(
433431
carshare,
434432
lat="centroid_lat",
435433
lon="centroid_lon",
436434
z="peak_hour",
437435
)
438-
fig.write_html(os.path.join(dir_name, "density_mapbox.html"), auto_play=False)
436+
fig.write_html(os.path.join(dir_name, "density_map.html"), auto_play=False)
439437

440438

441439
gapminder = px.data.gapminder()

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /