예제 #1
0
def test_input_data_wrong_input_type(gen_array):
    with pytest.raises(TypeError) as context:
        ut.input_data(gen_array.tolist())
예제 #2
0
def test_input_data_df(gen_data_frame):
    tup = ut.input_data((gen_data_frame, 'col1'))
    assert type(tup[0]) == pd.DataFrame
    assert type(tup[1]) == pd.Series
예제 #3
0
def test_input_data_array(gen_array):
    tup = ut.input_data(gen_array)
    assert tup[0] is gen_array
    assert type(tup[1]) == pd.Series
예제 #4
0
def test_input_data_wrong_tuple():
    with pytest.raises(TypeError) as context:
        ut.input_data((gen_array, 'col1'))
        ut.input_data((gen_series, 'col1'))
        ut.input_data((gen_data_frame, 2))
예제 #5
0
def test_input_data_Series(gen_series):
    tup = ut.input_data(gen_series)
    assert tup[0] is tup[1]