Source code for brainstat.tests.conftest

import git


# This hook will run by pytest one time before execution all the particular.
# tests. It does checkout the needed 'extern/test-data' directory from the
# separate branch 'test-data'.
[docs]def pytest_configure(config): repo = git.Repo(search_parent_directories=True) origin = repo.remote() cli = origin.repo.git cli.checkout("origin/test-data", "--", "extern/test-data") # we have to reset the test-data, as checkout is staging it to the git index cli.reset("--", "extern/test-data")