File tree 1 file changed +8
-1
lines changed 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change 24
24
import matplotlib .markers as mmarkers
25
25
import matplotlib .patches as mpatches
26
26
import matplotlib .colors as mcolors
27
- from numpy .testing import assert_allclose , assert_array_equal
27
+ from numpy .testing import (
28
+ assert_allclose , assert_array_equal , assert_array_almost_equal )
28
29
from matplotlib .cbook import (
29
30
IgnoredKeywordWarning , MatplotlibDeprecationWarning )
30
31
from matplotlib .cbook ._backports import broadcast_to
@@ -4828,6 +4829,12 @@ def test_square_plot():
4828
4829
xlim , ylim = ax .get_xlim (), ax .get_ylim ()
4829
4830
assert np .diff (xlim ) == np .diff (ylim )
4830
4831
assert ax .get_aspect () == 'equal'
4832
+ assert_array_almost_equal (
4833
+ ax .get_position (original = True ).extents ,
4834
+ np .array ((0.125 , 0.1 , 0.9 , 0.9 )))
4835
+ assert_array_almost_equal (
4836
+ ax .get_position (original = False ).extents ,
4837
+ np .array ((0.2125 , 0.1 , 0.8125 , 0.9 )))
4831
4838
4832
4839
4833
4840
def test_no_None ():
You can’t perform that action at this time.
0 commit comments