(kwargs)
| 825 | ], |
| 826 | ) |
| 827 | def test_truncate(kwargs): |
| 828 | df = DataFrame({"a": [1, 2, 3], "b": 1, "c": 2}) |
| 829 | df_orig = df.copy() |
| 830 | df2 = df.truncate(**kwargs) |
| 831 | df2._mgr._verify_integrity() |
| 832 | |
| 833 | assert np.shares_memory(get_array(df2, "a"), get_array(df, "a")) |
| 834 | |
| 835 | df2.iloc[0, 0] = 0 |
| 836 | assert not np.shares_memory(get_array(df2, "a"), get_array(df, "a")) |
| 837 | tm.assert_frame_equal(df, df_orig) |
| 838 | |
| 839 | |
| 840 | @pytest.mark.parametrize("method", ["assign", "drop_duplicates"]) |
nothing calls this directly
no test coverage detected