Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Add test for empty hexbin with log scaling.
  • Loading branch information
erykoff committed Sep 19, 2022
commit 281b09d62f43e1e64a16c76747d70d402ad52f92
8 changes: 8 additions & 0 deletions lib/matplotlib/tests/test_axes.py
Original file line number Diff line number Diff line change
Expand Up @@ -901,6 +901,14 @@ def test_hexbin_empty():
ax.hexbin([], [])


@image_comparison(['hexbin_empty.png'], remove_text=True)
def test_hexbin_log_empty():
# From #23922: creating hexbin with log scaling from empty
# dataset raises ValueError
ax = plt.gca()
ax.hexbin([], [], bins='log')


def test_hexbin_pickable():
# From #1973: Test that picking a hexbin collection works
fig, ax = plt.subplots()
Expand Down