Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 6408704

Browse files
committed
Add test for setting dashes for line collections
Conflicts: lib/matplotlib/tests/test_lines.py
1 parent 20fe9f9 commit 6408704

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

lib/matplotlib/tests/test_lines.py

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
"""
2+
Tests specific to the lines module.
3+
"""
4+
5+
from nose.tools import assert_true
6+
import numpy as np
7+
import matplotlib as mpl
8+
import matplotlib.pyplot as plt
9+
from matplotlib.testing.decorators import cleanup
10+
11+
@cleanup
12+
def test_set_line_coll_dash():
13+
fig = plt.figure()
14+
ax = fig.add_subplot(1, 1, 1)
15+
16+
np.random.seed(0)
17+
# Testing setting linestyles for line collections.
18+
# This should not produce an error.
19+
cs = ax.contour(np.random.randn(20, 30), linestyles=[(0, (3, 3))])
20+
21+
assert True

0 commit comments

Comments
 (0)