()
| 2070 | |
| 2071 | |
| 2072 | def test_avoid_alignment(): |
| 2073 | a = pd.DataFrame({"x": range(100)}) |
| 2074 | da = from_pandas(a, npartitions=4) |
| 2075 | |
| 2076 | b = pd.DataFrame({"y": range(100)}) |
| 2077 | b["z"] = b.y * 2 |
| 2078 | db = from_pandas(b, npartitions=3) |
| 2079 | |
| 2080 | # Give correct results even when misaligned |
| 2081 | assert_eq(a.x + b.y, da.x + db.y) |
| 2082 | |
| 2083 | assert not any(isinstance(ex, OpAlignPartitions) for ex in (db.y + db.z).walk()) |
| 2084 | assert not any( |
| 2085 | isinstance(ex, OpAlignPartitions) for ex in (da.x + db.y.sum()).walk() |
| 2086 | ) |
| 2087 | |
| 2088 | |
| 2089 | def test_mixed_array_op(df, pdf): |
nothing calls this directly
no test coverage detected
searching dependent graphs…