From 487013578a10c5745da5887b6363030ac4d8cef2 Mon Sep 17 00:00:00 2001 From: Ryan May Date: Mon, 6 Feb 2017 16:52:00 -0700 Subject: [PATCH 01/10] MNT: Always run coverage on AppVeyor --- appveyor.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index 7d00b1c51f89..bed7d44a0df6 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -140,8 +140,8 @@ test_script: - if x%USE_PYTEST% == xno python tests.py %PYTEST_ARGS% # Generate a html for visual tests - python visual_tests.py - - if x%USE_PYTEST% == xyes pip install codecov - - if x%USE_PYTEST% == xyes codecov -e PYTHON_VERSION PLATFORM + - pip install codecov + - codecov -e PYTHON_VERSION PLATFORM after_test: # After the tests were a success, build packages (wheels and conda) From 2519bf230bfebe17eddb953d0a2c462c0da5ebbd Mon Sep 17 00:00:00 2001 From: Ryan May Date: Mon, 6 Feb 2017 16:52:48 -0700 Subject: [PATCH 02/10] MNT: Increase required test lines coverage Trying to ensure we don't backslide. --- ci/codecov.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/codecov.yml b/ci/codecov.yml index 500b4a9f0d63..842794a555c6 100644 --- a/ci/codecov.yml +++ b/ci/codecov.yml @@ -24,5 +24,5 @@ coverage: paths: '!lib/.*/tests/.*' tests: - target: 97.7% + target: 97.9% paths: 'lib/.*/tests/.*' From d8907b7e7e9b497ee411f4b0e1b0c045dd080c32 Mon Sep 17 00:00:00 2001 From: Ryan May Date: Mon, 6 Feb 2017 17:42:57 -0700 Subject: [PATCH 03/10] BUG: Fix duplicated test name in test_axes. This was causing the first test to not run. --- lib/matplotlib/tests/test_axes.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/matplotlib/tests/test_axes.py b/lib/matplotlib/tests/test_axes.py index 19cc9267b794..54c77e69b1c9 100644 --- a/lib/matplotlib/tests/test_axes.py +++ b/lib/matplotlib/tests/test_axes.py @@ -866,7 +866,7 @@ def test_symlog2(): ax.set_ylim(-0.1, 0.1) -def test_pcolorargs(): +def test_pcolorargs_5205(): # Smoketest to catch issue found in gh:5205 x = [-1.5, -1.0, -0.5, 0.0, 0.5, 1.0, 1.5] y = [-1.5, -1.25, -1.0, -0.75, -0.5, -0.25, 0, From 093923bae35f415a148ebfe4f9551a3c70db8389 Mon Sep 17 00:00:00 2001 From: Ryan May Date: Mon, 6 Feb 2017 17:54:46 -0700 Subject: [PATCH 04/10] BUG: Fix duplicated test name in test_contour.py Regenerate test images now that this test is actually run. --- .../test_contour/contour_manual_labels.pdf | Bin 7422 -> 7316 bytes .../test_contour/contour_manual_labels.png | Bin 13112 -> 13176 bytes .../test_contour/contour_manual_labels.svg | 178 +++++++++--------- lib/matplotlib/tests/test_contour.py | 2 +- 4 files changed, 90 insertions(+), 90 deletions(-) diff --git a/lib/matplotlib/tests/baseline_images/test_contour/contour_manual_labels.pdf b/lib/matplotlib/tests/baseline_images/test_contour/contour_manual_labels.pdf index 6404ae457352849ed2a275e888e411e9c54f9d9f..2dd02c48fb5a909a6b6664ef0e6818b5439bfd68 100644 GIT binary patch delta 2309 zcma)7dsGu=7B^CwCcKLB2KA#t2r4F-nY@rkLBhi#2oVGo>kx(zArnXf0kNjaX|c84 zvvfePh}hCyZAndO>`H>W2nt#id+3XL5W2N1+AWbsD1uscXM%1m^pBmHb7sEZz4yDn z@7_7TJ14Fc|2ZIW3o6Gn00LZ)4mevYiZQ_1h-%Ryl^jGxF)=((mAi*2BF)r0A_8zE z<=O{|8>`d8X08;3X92 zSmWFz>FloVqJ)|d>~j2xl3?xhQ6CUj_RhHFC_m4G~Y6ogIA7kBVsW!$N9bP&p zjjcTHu^}{UIz2bz#nEq)gQs6h^j!|pYzgEOGux7FOPH9{`4>wKU-nw_5qy(#!!uvk zhPewRp1p5Q;>?4%Kyvkp9lHaz4&~|Hq`&OUG8b9FCm1x!Z%@66oVHWIA{F(>dEnv50Xf^TnOl z??{Mm9RjR9bDs5;6%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z6fxJb+pxnjHpvb&t!p+pEfcBvIMNkoHQR|gc;_;|< Y7vKZ}6d}V|;Y?v5%JlLIkBwmd2NK_56#xJL diff --git a/lib/matplotlib/tests/baseline_images/test_contour/contour_manual_labels.png b/lib/matplotlib/tests/baseline_images/test_contour/contour_manual_labels.png index 86d29d3c4cd898e3a44d058307bdcf36dc0c665a..0884343cd928a51eff323309672a6c3c8b6176c8 100644 GIT binary patch literal 13176 zcmbt*WmuH&*Dau+k|NS6ASfvfQlc~h(k&n`bhmUjNH-WD(nv^mcS#K0h%hum3ce-8G}E<8LuLagT8{Cs>SLOg7A7A`IhFF85?^AZkwCv#5f zfHDF!G&(dnNeOk2EZCx_zNYKV?QJh+Wz>E8@X)oudjG<@q~ylJSuxE|x>l2Ue2Oak zKAD!|h3R^hC(c*ZG5q=U#4tm3!_A){*HtI$Z;o;%xJjB|l7pC4~rhtdC zd};wtQSTf6|9hDtjk*oDySv-_YNx1gy41w!tE<<;3Y2ppQ$-rVAt9@qn;PpvQs9nK@88o{T3X^#zf5XtdsVgm z8+(vg`%NgW@zzj!iC%4Nz@2*-pHfnKD$NGb`uh6|9a=StHMu^X{?Q$Lj@pT>;mqD2 zD&K};Ran`yjGC{H2TQbn2LAbDLF2K4-qh5jU1|CN%n>qEW>DAIs8wgEtxaZhyZLAK zrwKb#nUJHSx@R7VZT{>EVb}Nv)B1tw7$vp^|cF! zYtl%;zSDPS^lW8=t+(5%9r9{6V4&!C@7?2Z{i`1KONQ3xF#$mw_O{_aM=E43^sY5`}yMcPAfNQYvdftjCWZDN-gG`gX~W!95Gb~4)Ni#Ihhi_gii)8qw9 z==cciV@GEvy5PstA8!!x3^IpDM^6|TyP{EHye7#e(C@QQ=Qxxjni)pxo7SJmJXxZ{ zGhM1DB4mhOJHrog*Q6 zaN$&YWbT)g%#9YWb35HyI|IANMS8V%XnA>gX@m->?Fk2K^Z7H~#KZ)MZdVIsB_%96 zLBZL7pSqS&47G4dRu+|XELA_4vYeu#*>s6c69}l_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R?#NAy$Lqh|w;cwKT-QdhQ77@oSg}4vy#qg&u7}DYjVtG&W{QnOmh5K*- diff --git a/lib/matplotlib/tests/baseline_images/test_contour/contour_manual_labels.svg b/lib/matplotlib/tests/baseline_images/test_contour/contour_manual_labels.svg index b8f5be69bf98..6ce04555e1b3 100644 --- a/lib/matplotlib/tests/baseline_images/test_contour/contour_manual_labels.svg +++ b/lib/matplotlib/tests/baseline_images/test_contour/contour_manual_labels.svg @@ -27,17 +27,17 @@ z " style="fill:#ffffff;"/> - - - - - - - - +" id="m368fc901b1" style="stroke:#000000;stroke-width:0.5;"/> - + +" id="mc63e59a608" style="stroke:#000000;stroke-width:0.5;"/> - + @@ -159,7 +159,7 @@ Q 6.59375 54.828125 13.0625 64.515625 Q 19.53125 74.21875 31.78125 74.21875 " id="DejaVuSans-30"/> - + @@ -167,12 +167,12 @@ Q 19.53125 74.21875 31.78125 74.21875 - + - + @@ -192,7 +192,7 @@ L 12.40625 0 z " id="DejaVuSans-31"/> - + @@ -200,12 +200,12 @@ z - + - + @@ -235,7 +235,7 @@ Q 44.1875 33.984375 37.640625 27.21875 Q 31.109375 20.453125 19.1875 8.296875 " id="DejaVuSans-32"/> - + @@ -243,12 +243,12 @@ Q 31.109375 20.453125 19.1875 8.296875 - + - + @@ -286,7 +286,7 @@ Q 53.90625 49.265625 50.4375 45.09375 Q 46.96875 40.921875 40.578125 39.3125 " id="DejaVuSans-33"/> - + @@ -294,12 +294,12 @@ Q 46.96875 40.921875 40.578125 39.3125 - + - + @@ -323,7 +323,7 @@ L 4.890625 26.703125 z " id="DejaVuSans-34"/> - + @@ -331,12 +331,12 @@ z - + - + @@ -367,7 +367,7 @@ Q 14.890625 38.140625 10.796875 36.28125 z " id="DejaVuSans-35"/> - + @@ -375,12 +375,12 @@ z - + - + @@ -415,7 +415,7 @@ Q 40.921875 74.21875 44.703125 73.484375 Q 48.484375 72.75 52.59375 71.296875 " id="DejaVuSans-36"/> - + @@ -423,12 +423,12 @@ Q 48.484375 72.75 52.59375 71.296875 - + - + @@ -444,7 +444,7 @@ L 8.203125 64.59375 z " id="DejaVuSans-37"/> - + @@ -452,12 +452,12 @@ z - + - + @@ -500,7 +500,7 @@ Q 25.390625 66.40625 21.84375 63.234375 Q 18.3125 60.0625 18.3125 54.390625 " id="DejaVuSans-38"/> - + @@ -508,12 +508,12 @@ Q 18.3125 60.0625 18.3125 54.390625 - + - + @@ -548,7 +548,7 @@ Q 16.21875 41.5 20.09375 36.953125 Q 23.96875 32.421875 30.609375 32.421875 " id="DejaVuSans-39"/> - + @@ -560,25 +560,25 @@ Q 23.96875 32.421875 30.609375 32.421875 +" id="m556f96d829" style="stroke:#000000;stroke-width:0.5;"/> - + +" id="m27e32ca04a" style="stroke:#000000;stroke-width:0.5;"/> - + - + @@ -586,17 +586,17 @@ L -4 0 - + - + - + @@ -604,17 +604,17 @@ L -4 0 - + - + - + @@ -622,17 +622,17 @@ L -4 0 - + - + - + @@ -640,17 +640,17 @@ L -4 0 - + - + - + @@ -658,17 +658,17 @@ L -4 0 - + - + - + @@ -676,17 +676,17 @@ L -4 0 - + - + - + @@ -694,17 +694,17 @@ L -4 0 - + - + - + @@ -712,17 +712,17 @@ L -4 0 - + - + - + @@ -730,24 +730,24 @@ L -4 0 - + - + - + - + - + - - - + + + - + - + - - - + + + - + - + - - - + + + @@ -793,8 +793,8 @@ z - - + + diff --git a/lib/matplotlib/tests/test_contour.py b/lib/matplotlib/tests/test_contour.py index dd17358edeb7..e455bd4c07b8 100644 --- a/lib/matplotlib/tests/test_contour.py +++ b/lib/matplotlib/tests/test_contour.py @@ -158,7 +158,7 @@ def test_contour_manual_labels(): @image_comparison(baseline_images=['contour_labels_size_color'], extensions=['png'], remove_text=True) -def test_contour_manual_labels(): +def test_contour_labels_size_color(): x, y = np.meshgrid(np.arange(0, 10), np.arange(0, 10)) z = np.max(np.dstack([abs(x), abs(y)]), 2) From ae2381c3ff081f0612e0457ef3b9edf743d57df5 Mon Sep 17 00:00:00 2001 From: Ryan May Date: Tue, 7 Feb 2017 11:01:42 -0700 Subject: [PATCH 05/10] MNT: Remove duplicated test code. This was an exact duplicate of the code above it. --- lib/matplotlib/tests/test_mlab.py | 67 ------------------------------- 1 file changed, 67 deletions(-) diff --git a/lib/matplotlib/tests/test_mlab.py b/lib/matplotlib/tests/test_mlab.py index 565df780e86a..9f77df82e472 100644 --- a/lib/matplotlib/tests/test_mlab.py +++ b/lib/matplotlib/tests/test_mlab.py @@ -955,73 +955,6 @@ def test_detrend_mean_2D_axism1(self): assert_allclose(res, targ, atol=1e-08) - def test_detrend_mean_2D_none(self): - arri = [self.sig_off, - self.sig_base + self.sig_off] - arrt = [self.sig_zeros, - self.sig_base] - input = np.vstack(arri) - targ = np.vstack(arrt) - res = mlab.detrend_mean(input, axis=None) - assert_allclose(res, targ, - atol=1e-08) - - def test_detrend_mean_2D_none_T(self): - arri = [self.sig_off, - self.sig_base + self.sig_off] - arrt = [self.sig_zeros, - self.sig_base] - input = np.vstack(arri).T - targ = np.vstack(arrt) - res = mlab.detrend_mean(input, axis=None) - assert_allclose(res.T, targ, - atol=1e-08) - - def test_detrend_mean_2D_axis0(self): - arri = [self.sig_base, - self.sig_base + self.sig_off, - self.sig_base + self.sig_slope, - self.sig_base + self.sig_off + self.sig_slope] - arrt = [self.sig_base, - self.sig_base, - self.sig_base + self.sig_slope_mean, - self.sig_base + self.sig_slope_mean] - input = np.vstack(arri).T - targ = np.vstack(arrt).T - res = mlab.detrend_mean(input, axis=0) - assert_allclose(res, targ, - atol=1e-08) - - def test_detrend_mean_2D_axis1(self): - arri = [self.sig_base, - self.sig_base + self.sig_off, - self.sig_base + self.sig_slope, - self.sig_base + self.sig_off + self.sig_slope] - arrt = [self.sig_base, - self.sig_base, - self.sig_base + self.sig_slope_mean, - self.sig_base + self.sig_slope_mean] - input = np.vstack(arri) - targ = np.vstack(arrt) - res = mlab.detrend_mean(input, axis=1) - assert_allclose(res, targ, - atol=1e-08) - - def test_detrend_mean_2D_axism1(self): - arri = [self.sig_base, - self.sig_base + self.sig_off, - self.sig_base + self.sig_slope, - self.sig_base + self.sig_off + self.sig_slope] - arrt = [self.sig_base, - self.sig_base, - self.sig_base + self.sig_slope_mean, - self.sig_base + self.sig_slope_mean] - input = np.vstack(arri) - targ = np.vstack(arrt) - res = mlab.detrend_mean(input, axis=-1) - assert_allclose(res, targ, - atol=1e-08) - def test_detrend_2D_default(self): arri = [self.sig_off, self.sig_base + self.sig_off] From 7d0a3d340edfa5ce771ba25970fcb6313bbe4341 Mon Sep 17 00:00:00 2001 From: Ryan May Date: Tue, 7 Feb 2017 11:06:01 -0700 Subject: [PATCH 06/10] MNT: Remove unused pickling debug code. This was deflating our coverage numbers for the tests. If deemed necessary, this code should be resurrected elsewhere (outside tests). Also cleaned up the code a bit. --- lib/matplotlib/tests/test_pickle.py | 97 ++--------------------------- 1 file changed, 5 insertions(+), 92 deletions(-) diff --git a/lib/matplotlib/tests/test_pickle.py b/lib/matplotlib/tests/test_pickle.py index 4f1ab2515c35..de3b30cb5966 100644 --- a/lib/matplotlib/tests/test_pickle.py +++ b/lib/matplotlib/tests/test_pickle.py @@ -1,7 +1,6 @@ from __future__ import (absolute_import, division, print_function, unicode_literals) -import six from six.moves import cPickle as pickle from six.moves import range @@ -15,88 +14,8 @@ import matplotlib.transforms as mtransforms -def depth_getter(obj, - current_depth=0, - depth_stack=None, - nest_info='top level object'): - """ - Returns a dictionary mapping: - - id(obj): (shallowest_depth, obj, nest_info) - - for the given object (and its subordinates). - - This, in conjunction with recursive_pickle, can be used to debug - pickling issues, although finding others is sometimes a case of - trial and error. - - """ - if depth_stack is None: - depth_stack = {} - - if id(obj) in depth_stack: - stack = depth_stack[id(obj)] - if stack[0] > current_depth: - del depth_stack[id(obj)] - else: - return depth_stack - - depth_stack[id(obj)] = (current_depth, obj, nest_info) - - if isinstance(obj, (list, tuple)): - for i, item in enumerate(obj): - depth_getter(item, current_depth=current_depth + 1, - depth_stack=depth_stack, - nest_info=('list/tuple item #%s in ' - '(%s)' % (i, nest_info))) - else: - if isinstance(obj, dict): - state = obj - elif hasattr(obj, '__getstate__'): - state = obj.__getstate__() - if not isinstance(state, dict): - state = {} - elif hasattr(obj, '__dict__'): - state = obj.__dict__ - else: - state = {} - - for key, value in six.iteritems(state): - depth_getter(value, current_depth=current_depth + 1, - depth_stack=depth_stack, - nest_info=('attribute "%s" in ' - '(%s)' % (key, nest_info))) - - return depth_stack - - -def recursive_pickle(top_obj): - """ - Recursively pickle all of the given objects subordinates, starting with - the deepest first. **Very** handy for debugging pickling issues, but - also very slow (as it literally pickles each object in turn). - - Handles circular object references gracefully. - - """ - objs = depth_getter(top_obj) - # sort by depth then by nest_info - objs = sorted(six.itervalues(objs), key=lambda val: (-val[0], val[2])) - - for _, obj, location in objs: - try: - pickle.dump(obj, BytesIO(), pickle.HIGHEST_PROTOCOL) - except Exception as err: - print(obj) - print('Failed to pickle %s. \n Type: %s. Traceback ' - 'follows:' % (location, type(obj))) - raise - - def test_simple(): fig = plt.figure() - # un-comment to debug -# recursive_pickle(fig) pickle.dump(fig, BytesIO(), pickle.HIGHEST_PROTOCOL) ax = plt.subplot(121) @@ -106,13 +25,9 @@ def test_simple(): plt.plot(np.arange(10), label='foobar') plt.legend() - # Uncomment to debug any unpicklable objects. This is slow so is not - # uncommented by default. -# recursive_pickle(fig) pickle.dump(ax, BytesIO(), pickle.HIGHEST_PROTOCOL) # ax = plt.subplot(121, projection='hammer') -# recursive_pickle(ax, 'figure') # pickle.dump(ax, BytesIO(), pickle.HIGHEST_PROTOCOL) plt.figure() @@ -138,8 +53,9 @@ def test_complete(): data = u = v = np.linspace(0, 10, 80).reshape(10, 8) v = np.sin(v * -0.6) + # Ensure lists also pickle correctly. plt.subplot(3, 3, 1) - plt.plot(list(range(10))) # Ensure lists also pickle correctly. + plt.plot(list(range(10))) plt.subplot(3, 3, 2) plt.contourf(data, hatches=['//', 'ooo']) @@ -171,11 +87,9 @@ def test_complete(): plt.subplot(3, 3, 9) plt.errorbar(x, x * -0.5, xerr=0.2, yerr=0.4) - ###### plotting is done, now test its pickle-ability ######### - - # Uncomment to debug any unpicklable objects. This is slow (~200 seconds). -# recursive_pickle(fig) - + # + # plotting is done, now test its pickle-ability + # result_fh = BytesIO() pickle.dump(fig, result_fh, pickle.HIGHEST_PROTOCOL) @@ -227,7 +141,6 @@ def test_image(): def test_polar(): ax = plt.subplot(111, polar=True) fig = plt.gcf() - result = BytesIO() pf = pickle.dumps(fig) pickle.loads(pf) plt.draw() From 3227ed1f9988c67e3cd2ade7a65db5b1132c45a5 Mon Sep 17 00:00:00 2001 From: Ryan May Date: Tue, 7 Feb 2017 11:12:56 -0700 Subject: [PATCH 07/10] BUG: Duplicated test class in test_ticker.py --- lib/matplotlib/tests/test_ticker.py | 98 ++++++++++++++--------------- 1 file changed, 48 insertions(+), 50 deletions(-) diff --git a/lib/matplotlib/tests/test_ticker.py b/lib/matplotlib/tests/test_ticker.py index d6eee0d6d7bd..524ab750133e 100644 --- a/lib/matplotlib/tests/test_ticker.py +++ b/lib/matplotlib/tests/test_ticker.py @@ -239,56 +239,6 @@ def test_use_offset(self, use_offset): assert use_offset == tmp_form.get_useOffset() -class TestLogFormatter(object): - def _sub_labels(self, axis, subs=()): - "Test whether locator marks subs to be labeled" - fmt = axis.get_minor_formatter() - minor_tlocs = axis.get_minorticklocs() - fmt.set_locs(minor_tlocs) - coefs = minor_tlocs / 10**(np.floor(np.log10(minor_tlocs))) - label_expected = [np.round(c) in subs for c in coefs] - label_test = [fmt(x) != '' for x in minor_tlocs] - assert label_test == label_expected - - @pytest.mark.style('default') - def test_sublabel(self): - # test label locator - fig, ax = plt.subplots() - ax.set_xscale('log') - ax.xaxis.set_major_locator(mticker.LogLocator(base=10, subs=[])) - ax.xaxis.set_minor_locator(mticker.LogLocator(base=10, - subs=np.arange(2, 10))) - ax.xaxis.set_major_formatter(mticker.LogFormatter(labelOnlyBase=True)) - ax.xaxis.set_minor_formatter(mticker.LogFormatter(labelOnlyBase=False)) - # axis range above 3 decades, only bases are labeled - ax.set_xlim(1, 1e4) - fmt = ax.xaxis.get_major_formatter() - fmt.set_locs(ax.xaxis.get_majorticklocs()) - show_major_labels = [fmt(x) != '' - for x in ax.xaxis.get_majorticklocs()] - assert np.all(show_major_labels) - self._sub_labels(ax.xaxis, subs=[]) - - # For the next two, if the numdec threshold in LogFormatter.set_locs - # were 3, then the label sub would be 3 for 2-3 decades and (2,5) - # for 1-2 decades. With a threshold of 1, subs are not labeled. - # axis range at 2 to 3 decades - ax.set_xlim(1, 800) - self._sub_labels(ax.xaxis, subs=[]) - - # axis range at 1 to 2 decades - ax.set_xlim(1, 80) - self._sub_labels(ax.xaxis, subs=[]) - - # axis range at 0.4 to 1 decades, label subs 2, 3, 4, 6 - ax.set_xlim(1, 8) - self._sub_labels(ax.xaxis, subs=[2, 3, 4, 6]) - - # axis range at 0 to 0.4 decades, label all - ax.set_xlim(0.5, 0.9) - self._sub_labels(ax.xaxis, subs=np.arange(2, 10, dtype=int)) - - class FakeAxis(object): """Allow Formatter to be called without having a "full" plot set up.""" def __init__(self, vmin=1, vmax=10): @@ -503,6 +453,54 @@ def test_pprint(self, value, domain, expected): label = fmt.pprint_val(value, domain) assert label == expected + def _sub_labels(self, axis, subs=()): + "Test whether locator marks subs to be labeled" + fmt = axis.get_minor_formatter() + minor_tlocs = axis.get_minorticklocs() + fmt.set_locs(minor_tlocs) + coefs = minor_tlocs / 10**(np.floor(np.log10(minor_tlocs))) + label_expected = [np.round(c) in subs for c in coefs] + label_test = [fmt(x) != '' for x in minor_tlocs] + assert label_test == label_expected + + @pytest.mark.style('default') + def test_sublabel(self): + # test label locator + fig, ax = plt.subplots() + ax.set_xscale('log') + ax.xaxis.set_major_locator(mticker.LogLocator(base=10, subs=[])) + ax.xaxis.set_minor_locator(mticker.LogLocator(base=10, + subs=np.arange(2, 10))) + ax.xaxis.set_major_formatter(mticker.LogFormatter(labelOnlyBase=True)) + ax.xaxis.set_minor_formatter(mticker.LogFormatter(labelOnlyBase=False)) + # axis range above 3 decades, only bases are labeled + ax.set_xlim(1, 1e4) + fmt = ax.xaxis.get_major_formatter() + fmt.set_locs(ax.xaxis.get_majorticklocs()) + show_major_labels = [fmt(x) != '' + for x in ax.xaxis.get_majorticklocs()] + assert np.all(show_major_labels) + self._sub_labels(ax.xaxis, subs=[]) + + # For the next two, if the numdec threshold in LogFormatter.set_locs + # were 3, then the label sub would be 3 for 2-3 decades and (2,5) + # for 1-2 decades. With a threshold of 1, subs are not labeled. + # axis range at 2 to 3 decades + ax.set_xlim(1, 800) + self._sub_labels(ax.xaxis, subs=[]) + + # axis range at 1 to 2 decades + ax.set_xlim(1, 80) + self._sub_labels(ax.xaxis, subs=[]) + + # axis range at 0.4 to 1 decades, label subs 2, 3, 4, 6 + ax.set_xlim(1, 8) + self._sub_labels(ax.xaxis, subs=[2, 3, 4, 6]) + + # axis range at 0 to 0.4 decades, label all + ax.set_xlim(0.5, 0.9) + self._sub_labels(ax.xaxis, subs=np.arange(2, 10, dtype=int)) + class TestFormatStrFormatter(object): def test_basic(self): From ca858b798de44fadc2325d26943a82ffef59698c Mon Sep 17 00:00:00 2001 From: Ryan May Date: Tue, 7 Feb 2017 11:19:37 -0700 Subject: [PATCH 08/10] BUG: Fix animation test Lack of saving the animation caused it to never run the callbacks. --- lib/matplotlib/tests/test_animation.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/matplotlib/tests/test_animation.py b/lib/matplotlib/tests/test_animation.py index 7e8c2ea235df..61ad1e56ee49 100644 --- a/lib/matplotlib/tests/test_animation.py +++ b/lib/matplotlib/tests/test_animation.py @@ -162,6 +162,8 @@ def animate(i): anim = animation.FuncAnimation(fig, animate, init_func=init, frames=iter(range(5))) + writer = NullMovieWriter() + anim.save('unused.null', writer=writer) def test_movie_writer_registry(): From af56c132c534c7f44c4fafcbe9c5df1723e96d1a Mon Sep 17 00:00:00 2001 From: Ryan May Date: Tue, 7 Feb 2017 11:31:30 -0700 Subject: [PATCH 09/10] MNT: More testing cleanups for coverage. Remove unused code and restructure to eliminate uncovered lines. --- lib/matplotlib/tests/test_collections.py | 10 ---------- lib/matplotlib/tests/test_triangulation.py | 4 ++-- lib/matplotlib/tests/test_widgets.py | 4 +--- 3 files changed, 3 insertions(+), 15 deletions(-) diff --git a/lib/matplotlib/tests/test_collections.py b/lib/matplotlib/tests/test_collections.py index be1e5fce3d8b..af9dabc904c1 100644 --- a/lib/matplotlib/tests/test_collections.py +++ b/lib/matplotlib/tests/test_collections.py @@ -383,16 +383,6 @@ def check_segments(coll, positions, linelength, lineoffset, orientation): assert_equal(segment[1, pos2], positions[i]) -def check_allprop(values, target): - ''' - check to make sure all values match the given target - - note: this is not a test, it is used by tests - ''' - for value in values: - assert_equal(value, target) - - def check_allprop_array(values, target): ''' check to make sure all values match the given target if arrays diff --git a/lib/matplotlib/tests/test_triangulation.py b/lib/matplotlib/tests/test_triangulation.py index a32061801b52..14b0b6361c53 100644 --- a/lib/matplotlib/tests/test_triangulation.py +++ b/lib/matplotlib/tests/test_triangulation.py @@ -966,8 +966,8 @@ def test_triplot_return(): triang = mtri.Triangulation( [0.0, 1.0, 0.0, 1.0], [0.0, 0.0, 1.0, 1.0], triangles=[[0, 1, 3], [3, 2, 0]]) - if ax.triplot(triang, "b-") is None: - raise AssertionError("triplot should return the artist it adds") + assert ax.triplot(triang, "b-") is not None, \ + 'triplot should return the artist it adds' def test_trirefiner_fortran_contiguous_triangles(): diff --git a/lib/matplotlib/tests/test_widgets.py b/lib/matplotlib/tests/test_widgets.py index 5fb41eb26b40..e8b7d8aebc7e 100644 --- a/lib/matplotlib/tests/test_widgets.py +++ b/lib/matplotlib/tests/test_widgets.py @@ -261,9 +261,7 @@ def test_CheckButtons(): check.set_active(0) assert check.get_status() == [False, False, True] - def clicked_function(): - pass - cid = check.on_clicked(clicked_function) + cid = check.on_clicked(lambda: None) check.disconnect(cid) From 9f316f9c07daf4196f8de8227e5b6985bc37ef5a Mon Sep 17 00:00:00 2001 From: Ryan May Date: Tue, 7 Feb 2017 13:28:32 -0700 Subject: [PATCH 10/10] MNT: Pep8 a few tests Since we're here making changes anyways. --- lib/matplotlib/tests/test_axes.py | 218 ++++++++++++--------- lib/matplotlib/tests/test_triangulation.py | 29 ++- pytest.ini | 2 - 3 files changed, 146 insertions(+), 103 deletions(-) diff --git a/lib/matplotlib/tests/test_axes.py b/lib/matplotlib/tests/test_axes.py index 54c77e69b1c9..5dcb34981145 100644 --- a/lib/matplotlib/tests/test_axes.py +++ b/lib/matplotlib/tests/test_axes.py @@ -27,7 +27,6 @@ import matplotlib.colors as mcolors from numpy.testing import assert_allclose, assert_array_equal from matplotlib.cbook import IgnoredKeywordWarning -import matplotlib.colors as mcolors # Note: Some test cases are run twice: once normally and once with labeled data # These two must be defined in the same test function or need to have @@ -110,7 +109,8 @@ def test_twin_axis_locaters_formatters(): ax1.yaxis.set_major_locator(majl) ax1.yaxis.set_minor_locator(minl) ax1.yaxis.set_major_formatter(plt.FormatStrFormatter('%08.2lf')) - ax1.yaxis.set_minor_formatter(plt.FixedFormatter(['tricks', 'mind', 'jedi'])) + ax1.yaxis.set_minor_formatter(plt.FixedFormatter(['tricks', 'mind', + 'jedi'])) ax1.xaxis.set_major_locator(plt.LinearLocator()) ax1.xaxis.set_minor_locator(plt.FixedLocator([15, 35, 55, 75])) @@ -178,7 +178,8 @@ def test_twin_inherit_autoscale_setting(): assert not ax_y_off.get_autoscaley_on() -@image_comparison(baseline_images=["minorticks_on_rcParams_both"], extensions=['png']) +@image_comparison(baseline_images=["minorticks_on_rcParams_both"], + extensions=['png']) def test_minorticks_on_rcParams_both(): fig = plt.figure() matplotlib.rcParams['xtick.minor.visible'] = True @@ -244,6 +245,7 @@ def test_use_sticky_edges(): assert_allclose(ax.get_xlim(), (-0.5, 1.5)) assert_allclose(ax.get_ylim(), (-0.5, 1.5)) + @image_comparison(baseline_images=['offset_points'], remove_text=True) def test_basic_annotate(): @@ -358,20 +360,21 @@ def test_fill_units(): # Top-Right ax2 = fig.add_subplot(222) ax2.plot([t], [value], yunits='deg', color='red') - ax2.fill([t, t, t+day, t+day], - [0.0, 0.0, 90.0, 0.0], 'b') + ax2.fill([t, t, t + day, t + day], + [0.0, 0.0, 90.0, 0.0], 'b') # Bottom-Left ax3 = fig.add_subplot(223) ax3.plot([t], [value], yunits='deg', color='red') ax3.fill([733525.0, 733525.0, 733526.0, 733526.0], - [0*units.deg, 0*units.deg, 90*units.deg, 0*units.deg], 'b') + [0 * units.deg, 0 * units.deg, 90 * units.deg, 0 * units.deg], + 'b') # Bottom-Right ax4 = fig.add_subplot(224) ax4.plot([t], [value], yunits='deg', color='red') - ax4.fill([t, t, t+day, t+day], - [0*units.deg, 0*units.deg, 90*units.deg, 0*units.deg], + ax4.fill([t, t, t + day, t + day], + [0 * units.deg, 0 * units.deg, 90 * units.deg, 0 * units.deg], facecolor="blue") fig.autofmt_xdate() @@ -391,14 +394,14 @@ def test_single_point(): plt.plot([1], [1], 'o') # Reuse testcase from above for a labeled data test - data = {'a':[0], 'b':[1]} + data = {'a': [0], 'b': [1]} fig = plt.figure() plt.subplot(211) plt.plot('a', 'a', 'o', data=data) plt.subplot(212) - plt.plot('b','b', 'o', data=data) + plt.plot('b', 'b', 'o', data=data) @image_comparison(baseline_images=['single_date']) @@ -416,26 +419,36 @@ def test_single_date(): @image_comparison(baseline_images=['shaped_data']) def test_shaped_data(): - xdata = np.array([[0.53295185, 0.23052951, 0.19057629, 0.66724975, 0.96577916, - 0.73136095, 0.60823287, 0.01792100, 0.29744742, 0.27164665], - [0.27980120, 0.25814229, 0.02818193, 0.12966456, 0.57446277, - 0.58167607, 0.71028245, 0.69112737, 0.89923072, 0.99072476], - [0.81218578, 0.80464528, 0.76071809, 0.85616314, 0.12757994, - 0.94324936, 0.73078663, 0.09658102, 0.60703967, 0.77664978], - [0.28332265, 0.81479711, 0.86985333, 0.43797066, 0.32540082, - 0.43819229, 0.92230363, 0.49414252, 0.68168256, 0.05922372], - [0.10721335, 0.93904142, 0.79163075, 0.73232848, 0.90283839, - 0.68408046, 0.25502302, 0.95976614, 0.59214115, 0.13663711], - [0.28087456, 0.33127607, 0.15530412, 0.76558121, 0.83389773, - 0.03735974, 0.98717738, 0.71432229, 0.54881366, 0.86893953], - [0.77995937, 0.99555600, 0.29688434, 0.15646162, 0.05184800, - 0.37161935, 0.12998491, 0.09377296, 0.36882507, 0.36583435], - [0.37851836, 0.05315792, 0.63144617, 0.25003433, 0.69586032, - 0.11393988, 0.92362096, 0.88045438, 0.93530252, 0.68275072], - [0.86486596, 0.83236675, 0.82960664, 0.57796630, 0.25724233, - 0.84841095, 0.90862812, 0.64414887, 0.35652720, 0.71026066], - [0.01383268, 0.34060930, 0.76084285, 0.70800694, 0.87634056, - 0.08213693, 0.54655021, 0.98123181, 0.44080053, 0.86815815]]) + xdata = np.array([[0.53295185, 0.23052951, 0.19057629, 0.66724975, + 0.96577916, 0.73136095, 0.60823287, 0.01792100, + 0.29744742, 0.27164665], + [0.27980120, 0.25814229, 0.02818193, 0.12966456, + 0.57446277, 0.58167607, 0.71028245, 0.69112737, + 0.89923072, 0.99072476], + [0.81218578, 0.80464528, 0.76071809, 0.85616314, + 0.12757994, 0.94324936, 0.73078663, 0.09658102, + 0.60703967, 0.77664978], + [0.28332265, 0.81479711, 0.86985333, 0.43797066, + 0.32540082, 0.43819229, 0.92230363, 0.49414252, + 0.68168256, 0.05922372], + [0.10721335, 0.93904142, 0.79163075, 0.73232848, + 0.90283839, 0.68408046, 0.25502302, 0.95976614, + 0.59214115, 0.13663711], + [0.28087456, 0.33127607, 0.15530412, 0.76558121, + 0.83389773, 0.03735974, 0.98717738, 0.71432229, + 0.54881366, 0.86893953], + [0.77995937, 0.99555600, 0.29688434, 0.15646162, + 0.05184800, 0.37161935, 0.12998491, 0.09377296, + 0.36882507, 0.36583435], + [0.37851836, 0.05315792, 0.63144617, 0.25003433, + 0.69586032, 0.11393988, 0.92362096, 0.88045438, + 0.93530252, 0.68275072], + [0.86486596, 0.83236675, 0.82960664, 0.57796630, + 0.25724233, 0.84841095, 0.90862812, 0.64414887, + 0.35652720, 0.71026066], + [0.01383268, 0.34060930, 0.76084285, 0.70800694, + 0.87634056, 0.08213693, 0.54655021, 0.98123181, + 0.44080053, 0.86815815]]) y1 = np.arange(10).reshape((1, -1)) y2 = np.arange(10).reshape((-1, 1)) @@ -518,7 +531,8 @@ def test_polar_units(): # make sure runits and theta units work y1 = [y*km for y in y1] plt.polar(x2, y1, color="blue", thetaunits="rad", runits="km") - assert isinstance(plt.gca().get_xaxis().get_major_formatter(), units.UnitDblFormatter) + assert isinstance(plt.gca().get_xaxis().get_major_formatter(), + units.UnitDblFormatter) @image_comparison(baseline_images=['polar_rmin']) @@ -613,12 +627,13 @@ def test_hexbin_extent(): @image_comparison(baseline_images=['hexbin_empty'], remove_text=True, - extensions=['png']) + extensions=['png']) def test_hexbin_empty(): # From #3886: creating hexbin from empty dataset raises ValueError ax = plt.gca() ax.hexbin([], []) + def test_hexbin_pickable(): # From #1973: Test that picking a hexbin collection works class FauxMouseEvent: @@ -678,7 +693,8 @@ def test_inverted_limits(): @image_comparison(baseline_images=['nonfinite_limits']) def test_nonfinite_limits(): x = np.arange(0., np.e, 0.01) - olderr = np.seterr(divide='ignore') # silence divide by zero warning from log(0) + # silence divide by zero warning from log(0) + olderr = np.seterr(divide='ignore') try: y = np.log(x) finally: @@ -706,7 +722,7 @@ def test_imshow(): ax.imshow(r) # Reuse testcase from above for a labeled data test - data={"r": r} + data = {"r": r} fig = plt.figure() ax = fig.add_subplot(111) ax.imshow("r", data=data) @@ -801,8 +817,10 @@ def test_fill_between_interpolate(): fig = plt.figure() ax = fig.add_subplot(211) ax.plot(x, y1, x, y2, color='black') - ax.fill_between(x, y1, y2, where=y2 >= y1, facecolor='white', hatch='/', interpolate=True) - ax.fill_between(x, y1, y2, where=y2 <= y1, facecolor='red', interpolate=True) + ax.fill_between(x, y1, y2, where=y2 >= y1, facecolor='white', hatch='/', + interpolate=True) + ax.fill_between(x, y1, y2, where=y2 <= y1, facecolor='red', + interpolate=True) # Test support for masked arrays. y2 = np.ma.masked_greater(y2, 1.0) @@ -810,8 +828,10 @@ def test_fill_between_interpolate(): y2[0] = np.ma.masked ax1 = fig.add_subplot(212, sharex=ax) ax1.plot(x, y1, x, y2, color='black') - ax1.fill_between(x, y1, y2, where=y2 >= y1, facecolor='green', interpolate=True) - ax1.fill_between(x, y1, y2, where=y2 <= y1, facecolor='red', interpolate=True) + ax1.fill_between(x, y1, y2, where=y2 >= y1, facecolor='green', + interpolate=True) + ax1.fill_between(x, y1, y2, where=y2 <= y1, facecolor='red', + interpolate=True) @image_comparison(baseline_images=['symlog']) @@ -1006,7 +1026,8 @@ def test_arc_ellipse(): fig = plt.figure() ax = fig.add_subplot(211, aspect='auto') - ax.fill(x, y, alpha=0.2, facecolor='yellow', edgecolor='yellow', linewidth=1, zorder=1) + ax.fill(x, y, alpha=0.2, facecolor='yellow', edgecolor='yellow', + linewidth=1, zorder=1) e1 = patches.Arc((xcenter, ycenter), width, height, angle=angle, linewidth=2, fill=False, zorder=2) @@ -1221,19 +1242,21 @@ def test_hist_log(): @image_comparison(baseline_images=['hist_bar_empty'], remove_text=True, - extensions=['png']) + extensions=['png']) def test_hist_bar_empty(): # From #3886: creating hist from empty dataset raises ValueError ax = plt.gca() ax.hist([], histtype='bar') + @image_comparison(baseline_images=['hist_step_empty'], remove_text=True, - extensions=['png']) + extensions=['png']) def test_hist_step_empty(): # From #3886: creating hist from empty dataset raises ValueError ax = plt.gca() ax.hist([], histtype='step') + @image_comparison(baseline_images=['hist_steplog'], remove_text=True, tol=0.1) def test_hist_steplog(): np.random.seed(0) @@ -1253,7 +1276,8 @@ def test_hist_steplog(): plt.hist(data, 100, weights=weights, histtype='stepfilled', log=True) ax = plt.subplot(4, 1, 4) - plt.hist(data_big, 100, histtype='stepfilled', log=True, orientation='horizontal') + plt.hist(data_big, 100, histtype='stepfilled', log=True, + orientation='horizontal') @image_comparison(baseline_images=['hist_step_filled'], remove_text=True, @@ -1464,7 +1488,8 @@ def _as_mpl_axes(self): ax_via_gca = plt.gca(projection=prj2) assert ax_via_gca is not ax assert ax.get_theta_offset() == 0, ax.get_theta_offset() - assert ax_via_gca.get_theta_offset() == np.pi, ax_via_gca.get_theta_offset() + assert ax_via_gca.get_theta_offset() == np.pi, \ + ax_via_gca.get_theta_offset() # try getting the axes given an == (not is) polar projection ax_via_gca = plt.gca(projection=prj3) assert ax_via_gca is ax @@ -1501,7 +1526,7 @@ def test_stackplot(): ax.set_ylim((0, 70)) # Reuse testcase from above for a labeled data test - data={"x": x, "y1": y1, "y2": y2, "y3": y3} + data = {"x": x, "y1": y1, "y2": y2, "y3": y3} fig = plt.figure() ax = fig.add_subplot(1, 1, 1) ax.stackplot("x", "y1", "y2", "y3", data=data) @@ -1529,7 +1554,7 @@ def bump(a): return a d = layers(3, 100) - d[50,:] = 0 # test for fixed weighted wiggle (issue #6313) + d[50, :] = 0 # test for fixed weighted wiggle (issue #6313) fig = plt.figure() @@ -2005,6 +2030,7 @@ def test_boxplot_autorange_whiskers(): ax2.boxplot([x, x], bootstrap=10000, notch=1, autorange=True) ax2.set_ylim((-5, 5)) + def _rc_test_bxp_helper(ax, rc_dict): x = np.linspace(-7, 7, 140) x = np.hstack([-25, x, 25]) @@ -2012,6 +2038,7 @@ def _rc_test_bxp_helper(ax, rc_dict): ax.boxplot([x, x]) return ax + @image_comparison(baseline_images=['boxplot_rc_parameters'], savefig_kwarg={'dpi': 100}, remove_text=True, tol=1, style='default') @@ -2022,7 +2049,7 @@ def test_boxplot_rc_parameters(): fig, ax = plt.subplots(3) rc_axis0 = { - 'boxplot.notch':True, + 'boxplot.notch': True, 'boxplot.whiskers': [5, 95], 'boxplot.bootstrap': 10000, @@ -2407,7 +2434,6 @@ def test_errorbar(): fig.suptitle('Variable errorbars') - # Reuse te first testcase from above for a labeled data test data = {"x": x, "y": y} fig = plt.figure() @@ -2510,7 +2536,8 @@ def test_hist_offset(): ax.hist(d2, bottom=15) -@image_comparison(baseline_images=['hist_step'], extensions=['png'], remove_text=True) +@image_comparison(baseline_images=['hist_step'], extensions=['png'], + remove_text=True) def test_hist_step(): # make some data d1 = np.linspace(1, 3, 20) @@ -2599,7 +2626,8 @@ def test_hist_stacked_normed(): ax.hist((d1, d2), stacked=True, normed=True) -@image_comparison(baseline_images=['hist_step_bottom'], extensions=['png'], remove_text=True) +@image_comparison(baseline_images=['hist_step_bottom'], extensions=['png'], + remove_text=True) def test_hist_step_bottom(): # make some data d1 = np.linspace(1, 3, 20) @@ -2622,7 +2650,8 @@ def test_hist_stacked_bar(): labels = ['green', 'orange', ' yellow', 'magenta', 'black'] fig = plt.figure() ax = fig.add_subplot(111) - ax.hist(d, bins=10, histtype='barstacked', align='mid', color=colors, label=labels) + ax.hist(d, bins=10, histtype='barstacked', align='mid', color=colors, + label=labels) ax.legend(loc='upper right', bbox_to_anchor=(1.0, 1.0), ncol=1) @@ -2653,11 +2682,12 @@ def test_rgba_markers(): for j, rcolor in enumerate(rcolors): for k, bcolor in enumerate(bcolors): axs[i].plot(j+1, k+1, 'o', mfc=bcolor, mec=rcolor, - alpha=alpha, **kw) + alpha=alpha, **kw) axs[i].plot(j+1, k+3, 'x', mec=rcolor, alpha=alpha, **kw) for ax in axs: ax.axis([-1, 4, 0, 5]) + @image_comparison(baseline_images=['mollweide_grid'], remove_text=True) def test_mollweide_grid(): # test that both horizontal and vertical gridlines appear on the Mollweide @@ -2788,7 +2818,8 @@ def test_eventplot(): assert num_collections == num_datasets -@image_comparison(baseline_images=['test_eventplot_defaults'], extensions=['png'], remove_text=True) +@image_comparison(baseline_images=['test_eventplot_defaults'], + extensions=['png'], remove_text=True) def test_eventplot_defaults(): ''' test that eventplot produces the correct output given the default params @@ -2805,7 +2836,8 @@ def test_eventplot_defaults(): colls = axobj.eventplot(data) -@image_comparison(baseline_images=['test_eventplot_problem_kwargs'], extensions=['png'], remove_text=True) +@image_comparison(baseline_images=['test_eventplot_problem_kwargs'], + extensions=['png'], remove_text=True) def test_eventplot_problem_kwargs(): ''' test that 'singular' versions of LineCollection props raise an @@ -2842,14 +2874,15 @@ def test_empty_eventplot(): plt.draw() -@image_comparison(baseline_images=['marker_styles'], extensions=['png'], remove_text=True) +@image_comparison(baseline_images=['marker_styles'], extensions=['png'], + remove_text=True) def test_marker_styles(): fig = plt.figure() ax = fig.add_subplot(111) for y, marker in enumerate(sorted(matplotlib.markers.MarkerStyle.markers, key=lambda x: str(type(x))+str(x))): - ax.plot((y % 2)*5 + np.arange(10)*10, np.ones(10)*10*y, linestyle='', marker=marker, - markersize=10+y/5, label=marker) + ax.plot((y % 2)*5 + np.arange(10)*10, np.ones(10)*10*y, linestyle='', + marker=marker, markersize=10+y/5, label=marker) @image_comparison(baseline_images=['rc_markerfill'], extensions=['png']) @@ -2857,7 +2890,7 @@ def test_markers_fillstyle_rcparams(): fig, ax = plt.subplots() x = np.arange(7) for idx, (style, marker) in enumerate( - [('top', 's'), ('bottom', 'o'), ('none', '^')]): + [('top', 's'), ('bottom', 'o'), ('none', '^')]): matplotlib.rcParams['markers.fillstyle'] = style ax.plot(x+idx, marker=marker) @@ -3937,9 +3970,9 @@ def make_patch_spines_invisible(ax): # Offset the right spine of par2. The ticks and label have already been # placed on the right by twinx above. par2.spines["right"].set_position(("axes", 1.2)) - # Having been created by twinx, par2 has its frame off, so the line of its - # detached spine is invisible. First, activate the frame but make the patch - # and spines invisible. + # Having been created by twinx, par2 has its frame off, so the line of + # its detached spine is invisible. First, activate the frame but make + # the patch and spines invisible. make_patch_spines_invisible(par2) # Second, show the right spine. par2.spines["right"].set_visible(True) @@ -4094,8 +4127,8 @@ def test_pie_linewidth_0(): fig = plt.figure() ax = fig.gca() ax.pie("s", explode="ex", labels="l", colors="c", - autopct='%1.1f%%', shadow=True, startangle=90, - wedgeprops={'linewidth': 0}, data=data) + autopct='%1.1f%%', shadow=True, startangle=90, + wedgeprops={'linewidth': 0}, data=data) ax.axis('equal') # And again to test the pyplot functions which should also be able to be @@ -4113,13 +4146,13 @@ def test_pie_center_radius(): labels = 'Frogs', 'Hogs', 'Dogs', 'Logs' sizes = [15, 30, 45, 10] colors = ['yellowgreen', 'gold', 'lightskyblue', 'lightcoral'] - explode = (0, 0.1, 0, 0) # only "explode" the 2nd slice (i.e. 'Hogs') + explode = (0, 0.1, 0, 0) # only "explode" the 2nd slice (i.e. 'Hogs') plt.pie(sizes, explode=explode, labels=labels, colors=colors, autopct='%1.1f%%', shadow=True, startangle=90, - wedgeprops={'linewidth': 0}, center=(1,2), radius=1.5) + wedgeprops={'linewidth': 0}, center=(1, 2), radius=1.5) - plt.annotate("Center point", xy=(1,2), xytext=(1,1.5), + plt.annotate("Center point", xy=(1, 2), xytext=(1, 1.5), arrowprops=dict(arrowstyle="->", connectionstyle="arc3")) # Set aspect ratio to be equal so that pie is drawn as a circle. @@ -4199,10 +4232,10 @@ def test_set_get_ticklabels(): ax[0].set_xticklabels(('a', 'b', 'c', 'd')) ax[0].set_yticklabels(('11', '12', '13', '14')) - # set ticklabel to the other plot, expect the 2 plots have same label setting - # pass get_ticklabels return value as ticklabels argument - ax[1].set_xticklabels(ax[0].get_xticklabels() ) - ax[1].set_yticklabels(ax[0].get_yticklabels() ) + # set ticklabel to the other plot, expect the 2 plots have same label + # setting pass get_ticklabels return value as ticklabels argument + ax[1].set_xticklabels(ax[0].get_xticklabels()) + ax[1].set_yticklabels(ax[0].get_yticklabels()) @image_comparison(baseline_images=['o_marker_path_snap'], extensions=['png'], @@ -4259,7 +4292,7 @@ def test_pathological_hexbin(): def test_color_None(): # issue 3855 fig, ax = plt.subplots() - ax.plot([1,2], [1,2], color=None) + ax.plot([1, 2], [1, 2], color=None) def test_color_alias(): @@ -4298,13 +4331,13 @@ def test_move_offsetlabel(): @image_comparison(baseline_images=['rc_spines'], extensions=['png'], - savefig_kwarg={'dpi':40}) + savefig_kwarg={'dpi': 40}) def test_rc_spines(): rc_dict = { - 'axes.spines.left':False, - 'axes.spines.right':False, - 'axes.spines.top':False, - 'axes.spines.bottom':False} + 'axes.spines.left': False, + 'axes.spines.right': False, + 'axes.spines.top': False, + 'axes.spines.bottom': False} with matplotlib.rc_context(rc_dict): fig, ax = plt.subplots() @@ -4343,15 +4376,15 @@ def test_rc_tick(): xax = ax1.xaxis yax = ax1.yaxis # tick1On bottom/left - assert xax._major_tick_kw['tick1On'] == False - assert xax._major_tick_kw['tick2On'] == True - assert xax._minor_tick_kw['tick1On'] == False - assert xax._minor_tick_kw['tick2On'] == True + assert not xax._major_tick_kw['tick1On'] + assert xax._major_tick_kw['tick2On'] + assert not xax._minor_tick_kw['tick1On'] + assert xax._minor_tick_kw['tick2On'] - assert yax._major_tick_kw['tick1On'] == True - assert yax._major_tick_kw['tick2On'] == False - assert yax._minor_tick_kw['tick1On'] == True - assert yax._minor_tick_kw['tick2On'] == False + assert yax._major_tick_kw['tick1On'] + assert not yax._major_tick_kw['tick2On'] + assert yax._minor_tick_kw['tick1On'] + assert not yax._minor_tick_kw['tick2On'] def test_rc_major_minor_tick(): @@ -4366,15 +4399,15 @@ def test_rc_major_minor_tick(): xax = ax1.xaxis yax = ax1.yaxis # tick1On bottom/left - assert xax._major_tick_kw['tick1On'] == False - assert xax._major_tick_kw['tick2On'] == True - assert xax._minor_tick_kw['tick1On'] == False - assert xax._minor_tick_kw['tick2On'] == True + assert not xax._major_tick_kw['tick1On'] + assert xax._major_tick_kw['tick2On'] + assert not xax._minor_tick_kw['tick1On'] + assert xax._minor_tick_kw['tick2On'] - assert yax._major_tick_kw['tick1On'] == False - assert yax._major_tick_kw['tick2On'] == True - assert yax._minor_tick_kw['tick1On'] == False - assert yax._minor_tick_kw['tick2On'] == True + assert not yax._major_tick_kw['tick1On'] + assert yax._major_tick_kw['tick2On'] + assert not yax._minor_tick_kw['tick1On'] + assert yax._minor_tick_kw['tick2On'] def test_bar_negative_width(): @@ -4687,7 +4720,8 @@ def test_pandas_indexing_hist(): def test_axis_set_tick_params_labelsize_labelcolor(): # Tests fix for issue 4346 axis_1 = plt.subplot() - axis_1.yaxis.set_tick_params(labelsize=30, labelcolor='red', direction='out') + axis_1.yaxis.set_tick_params(labelsize=30, labelcolor='red', + direction='out') # Expected values after setting the ticks assert axis_1.yaxis.majorTicks[0]._size == 4.0 diff --git a/lib/matplotlib/tests/test_triangulation.py b/lib/matplotlib/tests/test_triangulation.py index 14b0b6361c53..831a01c97efc 100644 --- a/lib/matplotlib/tests/test_triangulation.py +++ b/lib/matplotlib/tests/test_triangulation.py @@ -1,8 +1,6 @@ from __future__ import (absolute_import, division, print_function, unicode_literals) -import six - import numpy as np import matplotlib.pyplot as plt import matplotlib.tri as mtri @@ -17,6 +15,7 @@ import sys on_win = (sys.platform == 'win32') + def test_delaunay(): # No duplicate points, regular grid. nx = 5 @@ -236,10 +235,15 @@ def test_trifinder(): tris = trifinder(xs, ys) assert_array_equal(tris, [0, 17]) + # # Test triangles with horizontal colinear points. These are not valid # triangulations, but we try to deal with the simplest violations. - delta = 0.0 # If +ve, triangulation is OK, if -ve triangulation invalid, - # if zero have colinear points but should pass tests anyway. + # + + # If +ve, triangulation is OK, if -ve triangulation invalid, + # if zero have colinear points but should pass tests anyway. + delta = 0.0 + x = [1.5, 0, 1, 2, 3, 1.5, 1.5] y = [-1, 0, 0, 0, 0, delta, 1] triangles = [[0, 2, 1], [0, 3, 2], [0, 4, 3], [1, 2, 5], [2, 3, 5], @@ -254,10 +258,15 @@ def test_trifinder(): assert_array_equal(tris, [[-1, 0, 0, 1, 1, 2, -1], [-1, 6, 6, 6, 7, 7, -1]]) + # # Test triangles with vertical colinear points. These are not valid # triangulations, but we try to deal with the simplest violations. - delta = 0.0 # If +ve, triangulation is OK, if -ve triangulation invalid, - # if zero have colinear points but should pass tests anyway. + # + + # If +ve, triangulation is OK, if -ve triangulation invalid, + # if zero have colinear points but should pass tests anyway. + delta = 0.0 + x = [-1, -delta, 0, 0, 0, 0, 1] y = [1.5, 1.5, 0, 1, 2, 3, 1.5] triangles = [[0, 1, 2], [0, 1, 5], [1, 2, 3], [1, 3, 4], [1, 4, 5], @@ -281,7 +290,7 @@ def test_trifinder(): trifinder = triang.get_trifinder() xs = [-0.2, 0.2, 0.8, 1.2] - ys = [ 0.5, 0.5, 0.5, 0.5] + ys = [0.5, 0.5, 0.5, 0.5] tris = trifinder(xs, ys) assert_array_equal(tris, [-1, 0, 1, -1]) @@ -591,8 +600,10 @@ def test_triinterp_colinear(): # We also test interpolation inside a flat triangle, by forcing # *tri_index* in a call to :meth:`_interpolate_multikeys`. - delta = 0. # If +ve, triangulation is OK, if -ve triangulation invalid, - # if zero have colinear points but should pass tests anyway. + # If +ve, triangulation is OK, if -ve triangulation invalid, + # if zero have colinear points but should pass tests anyway. + delta = 0. + x0 = np.array([1.5, 0, 1, 2, 3, 1.5, 1.5]) y0 = np.array([-1, 0, 0, 0, 0, delta, 1]) diff --git a/pytest.ini b/pytest.ini index d9132bfa6002..ee59757e96ae 100644 --- a/pytest.ini +++ b/pytest.ini @@ -44,13 +44,11 @@ pep8ignore = matplotlib/testing/jpl_units/UnitDbl.py E201 E202 E203 matplotlib/testing/jpl_units/UnitDblConverter.py E201 E202 E203 E251 E302 E501 E711 matplotlib/testing/jpl_units/UnitDblFormatter.py E201 E202 E251 E302 - matplotlib/tests/test_axes.py E101 E202 E225 E231 E261 E302 E303 E501 E712 W191 matplotlib/tests/test_image.py E225 E231 E251 E302 E303 E501 E502 matplotlib/tests/test_lines.py E231 E261 matplotlib/tests/test_mathtext.py E261 E302 E501 matplotlib/tests/test_rcparams.py E231 E501 matplotlib/tests/test_tightlayout.py E302 - matplotlib/tests/test_triangulation.py E201 E302 matplotlib/tri/triinterpolate.py E201 E221 matplotlib/_cm.py E101 E202 E203 W191 matplotlib/_mathtext_data.py E203 E231 E261 E501