Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Aug 14, 2023
1 parent 860b8ab commit 9673191
Showing 1 changed file with 14 additions and 10 deletions.
24 changes: 14 additions & 10 deletions mne/tests/test_epochs.py
Original file line number Diff line number Diff line change
Expand Up @@ -1479,6 +1479,7 @@ def test_epochs_io_preload(tmp_path, preload):
@pytest.fixture(scope="session")
def epochs_factory():
"""Function to create fake Epochs object."""

def factory(n_epochs, metadata=False, concat=False):
if metadata:
pytest.importorskip("pandas")
Expand Down Expand Up @@ -1507,19 +1508,22 @@ def factory(n_epochs, metadata=False, concat=False):
epochs = concatenate_epochs([epochs[ii] for ii in range(len(epochs))])
assert len(epochs) == n_epochs
return epochs

return factory


@pytest.fixture(params=[
("1.5MB", 9, True, True, 6),
("1.5MB", 9, True, False, 6),
("1.5MB", 9, False, True, 6),
("1.5MB", 9, False, False, 6),
("3MB", 18, True, True, 3),
("3MB", 18, True, False, 3),
("3MB", 18, False, True, 3),
("3MB", 18, False, False, 3),
])
@pytest.fixture(
params=[
("1.5MB", 9, True, True, 6),
("1.5MB", 9, True, False, 6),
("1.5MB", 9, False, True, 6),
("1.5MB", 9, False, False, 6),
("3MB", 18, True, True, 3),
("3MB", 18, True, False, 3),
("3MB", 18, False, True, 3),
("3MB", 18, False, False, 3),
]
)
def epochs_to_split(request, epochs_factory):
"""Epochs tailored to produce specific number of splits when saving.
Expand Down

0 comments on commit 9673191

Please sign in to comment.