Skip to content

Commit dc7debc

Browse files
committed
Remove missing assert_less workaround from spines test
1 parent b8eb2d8 commit dc7debc

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

lib/matplotlib/tests/test_spines.py

+3-5
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
unicode_literals)
33

44
import numpy as np
5-
from nose.tools import assert_true
5+
from nose.tools import assert_true, assert_less
66
from matplotlib.externals import six
77

88
import matplotlib
@@ -71,13 +71,11 @@ def test_label_without_ticks():
7171
spine = ax.spines['left']
7272
spinebbox = spine.get_transform().transform_path(
7373
spine.get_path()).get_extents()
74-
# replace with assert_less if >python2.6
75-
assert_true(ax.yaxis.label.get_position()[0] < spinebbox.xmin,
74+
assert_less(ax.yaxis.label.get_position()[0], spinebbox.xmin,
7675
"Y-Axis label not left of the spine")
7776

7877
spine = ax.spines['bottom']
7978
spinebbox = spine.get_transform().transform_path(
8079
spine.get_path()).get_extents()
81-
# replace with assert_less if >python2.6
82-
assert_true(ax.xaxis.label.get_position()[1] < spinebbox.ymin,
80+
assert_less(ax.xaxis.label.get_position()[1], spinebbox.ymin,
8381
"X-Axis label not below the spine")

0 commit comments

Comments
 (0)