MCPcopy
hub / github.com/pandas-dev/pandas / check_round_trip

Method check_round_trip

pandas/tests/io/test_feather.py:43–55  ·  view source on GitHub ↗
(
        self, df, temp_file, expected=None, write_kwargs=None, **read_kwargs
    )

Source from the content-addressed store, hash-verified

41 to_feather(df, temp_file)
42
43 def check_round_trip(
44 self, df, temp_file, expected=None, write_kwargs=None, **read_kwargs
45 ):
46 if write_kwargs is None:
47 write_kwargs = {}
48 if expected is None:
49 expected = df.copy()
50
51 to_feather(df, temp_file, **write_kwargs)
52
53 result = read_feather(temp_file, **read_kwargs)
54
55 tm.assert_frame_equal(result, expected)
56
57 def test_error(self, temp_file):
58 msg = "feather only support IO with DataFrames"

Calls 3

to_featherFunction · 0.90
read_featherFunction · 0.90
copyMethod · 0.45

Tested by

no test coverage detected