Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create marker for internal tests #8299

Merged
merged 6 commits into from
Apr 7, 2024
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci-cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ jobs:
PIP_USER: 1
run: >-
PATH="${HOME}/Library/Python/3.11/bin:${HOME}/.local/bin:${PATH}"
pytest
pytest -m internal
Dreamsorcerer marked this conversation as resolved.
Show resolved Hide resolved
shell: bash
- name: Re-run the failing tests with maximum verbosity
if: failure()
Expand Down
2 changes: 2 additions & 0 deletions CHANGES/8299.packaging.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Added an 'internal' pytest marker for tests which should be skipped
Dreamsorcerer marked this conversation as resolved.
Show resolved Hide resolved
Dreamsorcerer marked this conversation as resolved.
Show resolved Hide resolved
by packagers and disabled them by default -- by :user:`Dreamsorcerer`.
3 changes: 3 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,8 @@ addopts =

# run tests that are not marked with dev_mode
-m "not dev_mode"
# skip internal by default for other users (re-enabled explicitly in CI).
-m "not internal"
Dreamsorcerer marked this conversation as resolved.
Show resolved Hide resolved
filterwarnings =
error
ignore:module 'ssl' has no attribute 'OP_NO_COMPRESSION'. The Python interpreter is compiled against OpenSSL < 1.0.0. Ref. https.//docs.python.org/3/library/ssl.html#ssl.OP_NO_COMPRESSION:UserWarning
Expand Down Expand Up @@ -170,3 +172,4 @@ junit_family=xunit2
xfail_strict = true
markers =
dev_mode: mark test to run in dev mode.
internal: tests which may cause issues for packagers, but should be run in aiohttp's CI.
1 change: 1 addition & 0 deletions tests/test_imports.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ def test_web___all__(pytester: pytest.Pytester) -> None:
}


@pytest.mark.internal
@pytest.mark.skipif(
not sys.platform.startswith("linux") or platform.python_implementation() == "PyPy",
reason="Timing is more reliable on Linux",
Expand Down