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

Method test_stubs

pandas/tests/reshape/test_melt.py:820–828  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

818 tm.assert_frame_equal(result, expected)
819
820 def test_stubs(self):
821 # GH9204 wide_to_long call should not modify 'stubs' list
822 df = DataFrame([[0, 1, 2, 3, 8], [4, 5, 6, 7, 9]])
823 df.columns = ["id", "inc1", "inc2", "edu1", "edu2"]
824 stubs = ["inc", "edu"]
825
826 wide_to_long(df, stubs, i="id", j="age")
827
828 assert stubs == ["inc", "edu"]
829
830 def test_separating_character(self):
831 # GH14779

Callers 1

run_stubtest.pyFile · 0.80

Calls 2

DataFrameClass · 0.90
wide_to_longFunction · 0.90

Tested by

no test coverage detected