MCPcopy Create free account
hub / github.com/holoviz/hvplot / test_interactive_pandas_function

Function test_interactive_pandas_function

hvplot/tests/testinteractive.py:151–165  ·  view source on GitHub ↗
(df)

Source from the content-addressed store, hash-verified

149
150
151def test_interactive_pandas_function(df):
152 select = pn.widgets.Select(options=list(df.columns))
153
154 def sel_col(col):
155 return df[col]
156
157 dfi = Interactive(bind(sel_col, select))
158 assert type(dfi) is Interactive
159 pd.testing.assert_series_equal(dfi._obj, df.A)
160 assert isinstance(dfi._fn, pn.param.ParamFunction)
161 assert dfi._transform == dim('*')
162 assert dfi._method is None
163
164 select.value = 'B'
165 pd.testing.assert_series_equal(dfi._obj, df.B)
166
167
168def test_interactive_xarray_function(dataset):

Callers

nothing calls this directly

Calls 2

InteractiveClass · 0.90
bindFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…