-
Notifications
You must be signed in to change notification settings - Fork 79
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
tests: add
--framework
opt to pytest
Allows us to specify which frameworks to test. This allows us to avoid some crashes when different frameworks don't interact well (e.g., Numba will fail if it's not given the primary context).
- Loading branch information
Showing
2 changed files
with
6 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
def pytest_addoption(parser): | ||
parser.addoption("--framework", action="append", default=[], help="List of frameworks") | ||
|
||
def pytest_generate_tests(metafunc): | ||
if "framework" in metafunc.fixturenames: | ||
metafunc.parametrize("framework", metafunc.config.getoption("framework")) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters