We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 16027f9 commit 8e144c7Copy full SHA for 8e144c7
pandas/tests/test_frame.py
@@ -4600,6 +4600,20 @@ def test_to_csv_from_csv(self):
4600
self.assertRaises(ValueError, self.frame2.to_csv, path,
4601
header=['AA', 'X'])
4602
4603
+ with ensure_clean(pname) as path:
4604
+ import pandas as pd
4605
+ df1 = DataFrame(np.random.randn(3, 1))
4606
+ df2 = DataFrame(np.random.randn(3, 1))
4607
+
4608
+ df1.to_csv(path)
4609
+ df2.to_csv(path,mode='a',header=False)
4610
+ xp = pd.concat([df1,df2])
4611
+ rs = pd.read_csv(path,index_col=0)
4612
+ rs.columns = map(int,rs.columns)
4613
+ xp.columns = map(int,xp.columns)
4614
+ assert_frame_equal(xp,rs)
4615
4616
4617
@slow
4618
def test_to_csv_moar(self):
4619
from pandas.util.testing import makeCustomDataframe as mkdf
0 commit comments