@@ -62,13 +62,12 @@ def test_round(self):
62
62
63
63
# float input to `decimals`
64
64
non_int_round_dict = {"col1" : 1 , "col2" : 0.5 }
65
- msg = "integer argument expected, got float "
65
+ msg = "Values in decimals must be integers "
66
66
with pytest .raises (TypeError , match = msg ):
67
67
df .round (non_int_round_dict )
68
68
69
69
# String input
70
70
non_int_round_dict = {"col1" : 1 , "col2" : "foo" }
71
- msg = r"an integer is required \(got type str\)"
72
71
with pytest .raises (TypeError , match = msg ):
73
72
df .round (non_int_round_dict )
74
73
@@ -78,7 +77,6 @@ def test_round(self):
78
77
79
78
# List input
80
79
non_int_round_dict = {"col1" : 1 , "col2" : [1 , 2 ]}
81
- msg = r"an integer is required \(got type list\)"
82
80
with pytest .raises (TypeError , match = msg ):
83
81
df .round (non_int_round_dict )
84
82
@@ -106,7 +104,6 @@ def test_round(self):
106
104
# nan in Series round
107
105
nan_round_Series = Series ({"col1" : np .nan , "col2" : 1 })
108
106
109
- msg = "integer argument expected, got float"
110
107
with pytest .raises (TypeError , match = msg ):
111
108
df .round (nan_round_Series )
112
109
0 commit comments