()
| 1100 | |
| 1101 | |
| 1102 | def test_drop_duplicates_subset(): |
| 1103 | df = pd.DataFrame({"x": [1, 2, 3, 1, 2, 3], "y": ["a", "a", "b", "b", "c", "c"]}) |
| 1104 | ddf = dd.from_pandas(df, npartitions=2) |
| 1105 | |
| 1106 | for kwarg in [{"keep": "first"}, {"keep": "last"}]: |
| 1107 | assert_eq(df.x.drop_duplicates(**kwarg), ddf.x.drop_duplicates(**kwarg)) |
| 1108 | for ss in [["x"], "y", ["x", "y"]]: |
| 1109 | assert_eq( |
| 1110 | df.drop_duplicates(subset=ss, **kwarg), |
| 1111 | ddf.drop_duplicates(subset=ss, **kwarg), |
| 1112 | ) |
| 1113 | assert_eq(df.drop_duplicates(ss, **kwarg), ddf.drop_duplicates(ss, **kwarg)) |
| 1114 | |
| 1115 | |
| 1116 | def test_get_partition(): |
nothing calls this directly
no test coverage detected