@@ -528,7 +528,7 @@ def test_malformed(self):
528528 try :
529529 df = self .read_table (
530530 StringIO (data ), sep = ',' , header = 1 , comment = '#' )
531- self .assert_ (False )
531+ self .assertTrue (False )
532532 except Exception as inst :
533533 self .assertIn ('Expected 3 fields in line 4, saw 5' , str (inst ))
534534
@@ -551,7 +551,7 @@ def test_malformed(self):
551551 df = self .read_table (
552552 StringIO (data ), sep = ',' , header = 1 , comment = '#' ,
553553 skip_footer = 1 )
554- self .assert_ (False )
554+ self .assertTrue (False )
555555 except Exception as inst :
556556 self .assertIn ('Expected 3 fields in line 4, saw 5' , str (inst ))
557557
@@ -569,7 +569,7 @@ def test_malformed(self):
569569 header = 1 , comment = '#' , iterator = True , chunksize = 1 ,
570570 skiprows = [2 ])
571571 df = it .read (5 )
572- self .assert_ (False )
572+ self .assertTrue (False )
573573 except Exception as inst :
574574 self .assertIn ('Expected 3 fields in line 6, saw 5' , str (inst ))
575575
@@ -588,7 +588,7 @@ def test_malformed(self):
588588 skiprows = [2 ])
589589 df = it .read (1 )
590590 it .read (2 )
591- self .assert_ (False )
591+ self .assertTrue (False )
592592 except Exception as inst :
593593 self .assertIn ('Expected 3 fields in line 6, saw 5' , str (inst ))
594594
@@ -607,7 +607,7 @@ def test_malformed(self):
607607 skiprows = [2 ])
608608 df = it .read (1 )
609609 it .read ()
610- self .assert_ (False )
610+ self .assertTrue (False )
611611 except Exception as inst :
612612 self .assertIn ('Expected 3 fields in line 6, saw 5' , str (inst ))
613613
@@ -1134,7 +1134,7 @@ def test_infer_index_col(self):
11341134baz,7,8,9
11351135"""
11361136 data = self .read_csv (StringIO (data ))
1137- self .assert_ (data .index .equals (Index (['foo' , 'bar' , 'baz' ])))
1137+ self .assertTrue (data .index .equals (Index (['foo' , 'bar' , 'baz' ])))
11381138
11391139 def test_read_nrows (self ):
11401140 df = self .read_csv (StringIO (self .data1 ), nrows = 3 )
@@ -1912,7 +1912,7 @@ def convert_score(x):
19121912 result = self .read_csv (fh , converters = {'score' : convert_score ,
19131913 'days' : convert_days },
19141914 na_values = ['' , None ])
1915- self .assert_ (pd .isnull (result ['days' ][1 ]))
1915+ self .assertTrue (pd .isnull (result ['days' ][1 ]))
19161916
19171917 fh = StringIO (csv )
19181918 result2 = self .read_csv (fh , converters = {'score' : convert_score ,
@@ -2177,7 +2177,7 @@ def test_sniff_delimiter(self):
21772177baz|7|8|9
21782178"""
21792179 data = self .read_csv (StringIO (text ), index_col = 0 , sep = None )
2180- self .assert_ (data .index .equals (Index (['foo' , 'bar' , 'baz' ])))
2180+ self .assertTrue (data .index .equals (Index (['foo' , 'bar' , 'baz' ])))
21812181
21822182 data2 = self .read_csv (StringIO (text ), index_col = 0 , delimiter = '|' )
21832183 tm .assert_frame_equal (data , data2 )
@@ -2378,7 +2378,7 @@ def test_fwf_regression(self):
23782378
23792379 for c in df .columns :
23802380 res = df .loc [:,c ]
2381- self .assert_ (len (res ))
2381+ self .assertTrue (len (res ))
23822382
23832383 def test_fwf_compression (self ):
23842384 try :
@@ -2577,7 +2577,7 @@ def test_malformed(self):
25772577 try :
25782578 df = self .read_table (
25792579 StringIO (data ), sep = ',' , header = 1 , comment = '#' )
2580- self .assert_ (False )
2580+ self .assertTrue (False )
25812581 except Exception as inst :
25822582 self .assertIn ('Expected 3 fields in line 4, saw 5' , str (inst ))
25832583
@@ -2594,7 +2594,7 @@ def test_malformed(self):
25942594 df = self .read_table (
25952595 StringIO (data ), sep = ',' , header = 1 , comment = '#' ,
25962596 skip_footer = 1 )
2597- self .assert_ (False )
2597+ self .assertTrue (False )
25982598 except Exception as inst :
25992599 self .assertIn ('Expected 3 fields in line 4, saw 5' , str (inst ))
26002600
@@ -2612,7 +2612,7 @@ def test_malformed(self):
26122612 header = 1 , comment = '#' , iterator = True , chunksize = 1 ,
26132613 skiprows = [2 ])
26142614 df = it .read (5 )
2615- self .assert_ (False )
2615+ self .assertTrue (False )
26162616 except Exception as inst :
26172617 self .assertIn ('Expected 3 fields in line 6, saw 5' , str (inst ))
26182618
@@ -2631,7 +2631,7 @@ def test_malformed(self):
26312631 skiprows = [2 ])
26322632 df = it .read (1 )
26332633 it .read (2 )
2634- self .assert_ (False )
2634+ self .assertTrue (False )
26352635 except Exception as inst :
26362636 self .assertIn ('Expected 3 fields in line 6, saw 5' , str (inst ))
26372637
@@ -2650,7 +2650,7 @@ def test_malformed(self):
26502650 skiprows = [2 ])
26512651 df = it .read (1 )
26522652 it .read ()
2653- self .assert_ (False )
2653+ self .assertTrue (False )
26542654 except Exception as inst :
26552655 self .assertIn ('Expected 3 fields in line 6, saw 5' , str (inst ))
26562656
0 commit comments