def test_constant(): data = [1, 1, 1, 1, 1] is_bad = _is_bad_data(data, 100) assert is_bad
def test_valid(): data = [1, 0, 0, 2, 1] is_bad = _is_bad_data(data, 100) assert not is_bad
def test_sudden_jump(): data = [0, 0, 0, 1000, 0] is_bad = _is_bad_data(data, 100) assert is_bad
def test_nan(): data = [np.nan, 0, 0, 2, np.nan] is_bad = _is_bad_data(data, 100) assert is_bad