()
| 7 | |
| 8 | |
| 9 | def test_assign_not_modifying_array_inplace(): |
| 10 | df = pd.DataFrame({"a": [1, 2, 3], "b": 1.5}) |
| 11 | result = methods.assign(df, "a", 5) |
| 12 | assert not np.shares_memory(df["a"].values, result["a"].values) |
| 13 | assert np.shares_memory(df["b"].values, result["b"].values) |