Skip to content

Commit fac519b

Browse files
committed
Fixed issue #4345.
1 parent 6ae36e4 commit fac519b

File tree

3 files changed

+9
-1
lines changed

3 files changed

+9
-1
lines changed

doc/source/release.rst

+2
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,8 @@ pandas 0.13
7474
(:issue:`4102`, :issue:`4014`) in ``*.hist`` plotting methods
7575
- Fixed bug in ``PeriodIndex.map`` where using ``str`` would return the str
7676
representation of the index (:issue:`4136`)
77+
- Fixed test failure ``test_time_series_plot_color_with_empty_kwargs`` when
78+
using custom matplotlib default colors (:issue:`4345`)
7779
- Fix running of stata IO tests. Now uses temporary files to write
7880
(:issue:`4353`)
7981
- Fixed an issue where ``DataFrame.sum`` was slower than ``DataFrame.mean``

doc/source/v0.13.0.txt

+3
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,9 @@ Bug Fixes
5151
- Fixed bug in ``PeriodIndex.map`` where using ``str`` would return the str
5252
representation of the index (:issue:`4136`)
5353

54+
- Fixed test failure ``test_time_series_plot_color_with_empty_kwargs`` when
55+
using custom matplotlib default colors (:issue:`4345`)
56+
5457
- Fix running of stata IO tests. Now uses temporary files to write
5558
(:issue:`4353`)
5659

pandas/tests/test_graphics.py

+4-1
Original file line numberDiff line numberDiff line change
@@ -917,15 +917,18 @@ def test_time_series_plot_color_kwargs(self):
917917
self.assert_(line.get_color() == 'green')
918918

919919
def test_time_series_plot_color_with_empty_kwargs(self):
920+
import matplotlib as mpl
920921
import matplotlib.pyplot as plt
922+
923+
def_colors = mpl.rcParams['axes.color_cycle']
921924

922925
plt.close('all')
923926
for i in range(3):
924927
ax = Series(np.arange(12) + 1, index=date_range('1/1/2000',
925928
periods=12)).plot()
926929

927930
line_colors = [l.get_color() for l in ax.get_lines()]
928-
self.assert_(line_colors == ['b', 'g', 'r'])
931+
self.assertEqual(line_colors, def_colors[:3])
929932

930933
@slow
931934
def test_grouped_hist(self):

0 commit comments

Comments
 (0)