forked from asdf-format/asdf
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request asdf-format#1645 from braingram/fix_package_tests
move conftest contents to asdf/conftest
- Loading branch information
Showing
2 changed files
with
28 additions
and
27 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 |
---|---|---|
@@ -1,4 +1,32 @@ | ||
import os | ||
|
||
import pytest | ||
|
||
# We ignore these files because these modules create deprecation warnings on | ||
# import. When warnings are turned into errors this will completely prevent | ||
# test collection | ||
collect_ignore = ["asdftypes.py", "fits_embed.py", "resolver.py", "type_index.py", "types.py", "tests/helpers.py"] | ||
|
||
|
||
@pytest.fixture(scope="session", autouse=True) | ||
def _temp_cwd(tmpdir_factory): | ||
""" | ||
This fixture creates a temporary current working directory | ||
for the test session, so that docstring tests that write files | ||
don't clutter up the real cwd. | ||
""" | ||
original_cwd = os.getcwd() | ||
try: | ||
os.chdir(tmpdir_factory.mktemp("cwd")) | ||
yield | ||
finally: | ||
os.chdir(original_cwd) | ||
|
||
|
||
def pytest_addoption(parser): | ||
parser.addoption( | ||
"--jsonschema", | ||
action="store_true", | ||
default=False, | ||
help="Run jsonschema test suite tests", | ||
) |
This file was deleted.
Oops, something went wrong.