Skip to content

Commit 6966a5d

Browse files
committed
Update payoff plot test for matplotlib 3+
1 parent 99d2c72 commit 6966a5d

File tree

1 file changed

+0
-10
lines changed

1 file changed

+0
-10
lines changed

axelrod/tests/unit/test_plot.py

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -192,23 +192,13 @@ def test_payoff_with_title(self):
192192
self.assertIsInstance(fig, matplotlib.pyplot.Figure)
193193
plt.close(fig)
194194

195-
@unittest.skipIf(matplotlib.__version__.startswith('3'),
196-
"Colorbar position differs in matplotlib versions")
197195
def test_payoff_with_passed_axes(self):
198196
plot = axelrod.Plot(self.test_result_set)
199197
fig, axarr = plt.subplots(2, 2)
200198
self.assertEqual(axarr[0, 1].get_xlim(), (0, 1))
201199

202200
plot.payoff(ax=axarr[0, 1])
203201
self.assertNotEqual(axarr[0, 1].get_xlim(), (0, 1))
204-
# Ensure color bar draw at same location as boxplot
205-
color_bar_bbox = fig.axes[-1].get_position().get_points()
206-
payoff_bbox_coord = fig.axes[1].get_position().get_points()
207-
self.assertEqual(
208-
color_bar_bbox[1, 1],
209-
payoff_bbox_coord[1, 1],
210-
msg="Color bar is not in correct location.",
211-
)
212202

213203
# Plot on another axes with a title
214204
plot.payoff(title="dummy title", ax=axarr[1, 0])

0 commit comments

Comments
 (0)