8000 Add a simple smoke test for bar3d colors. · matplotlib/matplotlib@680e839 · GitHub
[go: up one dir, main page]

Skip to content

Commit 680e839

Browse files
committed
Add a simple smoke test for bar3d colors.
1 parent a3a652f commit 680e839

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

lib/mpl_toolkits/tests/test_mplot3d.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,18 @@ def test_bar3d():
3636
ax.bar(xs, ys, zs=z, zdir='y', align='edge', color=cs, alpha=0.8)
3737

3838

39+
def test_bar3d_colors():
40+
fig = plt.figure()
41+
ax = fig.add_subplot(111, projection='3d')
42+
for c in ['red', 'green', 'blue', 'yellow']:
43+
xs = np.arange(len(c))
44+
ys = np.zeros_like(xs)
45+
zs = np.zeros_like(ys)
46+
# Color names with same length as xs/ys/zs should not be split into
47+
# individual letters.
48+
ax.bar3d(xs, ys, zs, 1, 1, 1, color=c)
49+
50+
3951
@mpl3d_image_comparison(['bar3d_shaded.png'])
4052
def test_bar3d_shaded():
4153
x = np.arange(4)

0 commit comments

Comments
 (0)
0