Skip to content

Commit 5e60314

Browse files
committed
TST: add test
1 parent 339d762 commit 5e60314

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

lib/matplotlib/tests/test_ticker.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,10 @@ def test_switch_to_autolocator(self):
183183
loc = mticker.LogLocator(subs="all")
184184
assert_array_equal(loc.tick_values(0.45, 0.55),
185185
[0.44, 0.46, 0.48, 0.5, 0.52, 0.54, 0.56])
186+
# check that we *skip* 1.0, and 10, because this is a minor locator
187+
loc = mticker.LogLocator(subs=np.arange(2, 10))
188+
assert 1.0 not in loc.tick_values(0.9, 20.)
189+
assert 10.0 not in loc.tick_values(0.9, 20.)
186190

187191
def test_set_params(self):
188192
"""

0 commit comments

Comments
 (0)