Skip to content

Commit

Permalink
fixes bug and formatting in test
Browse files Browse the repository at this point in the history
  • Loading branch information
john-veillette committed Sep 16, 2024
1 parent c43e967 commit b957cea
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions tests/test_find_noisy_channels.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,12 +79,13 @@ def test_bad_by_manual(raw_tmp):
n_chans = raw_tmp.get_data().shape[0]
nan_idx = int(rng.integers(0, n_chans, 1)[0])
raw_tmp._data[nan_idx, 3] = np.nan
raw_tmp.info["bads"] = [raw.ch_names[0]]
raw_tmp.info["bads"] = [raw_tmp.ch_names[0]]

# Test record of a priori bad channels on NoisyChannels init
nd = NoisyChannels(raw_tmp, do_detrend=False)
assert nd.bad_by_manual == [raw.ch_names[0]]
assert raw.ch_names[0] in nd.get_bads(as_dict = False)
assert nd.bad_by_manual == [raw_tmp.ch_names[0]]
assert raw_tmp.ch_names[0] in nd.get_bads(as_dict=False)
raw_tmp.info["bads"] = []


def test_bad_by_flat(raw_tmp):
Expand Down

0 comments on commit b957cea

Please sign in to comment.