FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Backport PR #16735 on branch v3.2.x (Make test_stem less flaky.) by meeseeksmachine · Pull Request #16760 · matplotlib/matplotlib · GitHub

Repository navigation

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension .py  (1) All 1 file type selected
Viewed files
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Unified
Split
Hide whitespace
Diff view
Unified
Split
Hide whitespace
13 changes: 9 additions & 4 deletions lib/matplotlib/tests/test_axes.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
Expand Up @@ -3227,10 +3227,15 @@ def test_hist_stacked_weighted():
ax.hist((d1, d2), weights=(w1, w2), histtype="stepfilled", stacked=True)


@pytest.mark.parametrize("use_line_collection", [True, False],
ids=['w/ line collection', 'w/o line collection'])
@image_comparison(['stem.png'], style='mpl20', remove_text=True)
def test_stem(use_line_collection):
@image_comparison(['stem.png', 'stem.png'], style='mpl20', remove_text=True)
def test_stem():
# Note, we don't use @pytest.mark.parametrize, because in parallel this
# might cause one process result to overwrite another's.
for use_line_collection in [True, False]:
_test_stem(use_line_collection)


def _test_stem(use_line_collection):
x = np.linspace(0.1, 2 * np.pi, 100)
args = (x, np.cos(x))
# Label is a single space to force a legend to be drawn, but to avoid any
Expand Down

Back | FazBrowse Home | New Git URL