Skip to content

Commit e6a8eb2

Browse files
committed
Fix more tests
1 parent a738e68 commit e6a8eb2

File tree

2 files changed

+9
-5
lines changed

2 files changed

+9
-5
lines changed

pandas/tests/frame/methods/test_drop_duplicates.py

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -411,10 +411,15 @@ def test_drop_duplicates_inplace():
411411
@pytest.mark.parametrize(
412412
"origin_dict, output_dict, ignore_index, output_index",
413413
[
414-
({"A": [2, 2, 3]}, {"A": [2, 3]}, True, [0, 1]),
415-
({"A": [2, 2, 3]}, {"A": [2, 3]}, False, [0, 2]),
416-
({"A": [2, 2, 3], "B": [2, 2, 4]}, {"A": [2, 3], "B": [2, 4]}, True, [0, 1]),
417-
({"A": [2, 2, 3], "B": [2, 2, 4]}, {"A": [2, 3], "B": [2, 4]}, False, [0, 2]),
414+
({"A": [2, 2, 3]}, {"A": [2, 3]}, True, range(2)),
415+
({"A": [2, 2, 3]}, {"A": [2, 3]}, False, range(0, 4, 2)),
416+
({"A": [2, 2, 3], "B": [2, 2, 4]}, {"A": [2, 3], "B": [2, 4]}, True, range(2)),
417+
(
418+
{"A": [2, 2, 3], "B": [2, 2, 4]},
419+
{"A": [2, 3], "B": [2, 4]},
420+
False,
421+
range(0, 4, 2),
422+
),
418423
],
419424
)
420425
def test_drop_duplicates_ignore_index(

pandas/tests/test_sorting.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,6 @@ def test_int64_overflow_how_merge(self, left_right, join_type):
221221

222222
out = merge(left, right, how="outer")
223223
out.sort_values(out.columns.tolist(), inplace=True)
224-
out.index = np.arange(len(out))
225224
tm.assert_frame_equal(out, merge(left, right, how=join_type, sort=True))
226225

227226
@pytest.mark.slow

0 commit comments

Comments
 (0)