Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/workflows/_checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,8 @@ jobs:
- run: uv pip compile pyproject.toml --all-extras --no-deps --resolution lowest-direct -o floors.txt
- run: uv pip install -r pyproject.toml --all-extras --group dev --constraints floors.txt --no-build
- run: uv run --no-sync pytest .
env:
REQUIRE_INTEGRATIONS: "1"

links:
runs-on: ubuntu-latest
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ fastapi = [
"fastapi>=0.115.3",
]
faststream = [
"faststream>=0.5.19",
"faststream>=0.5.29",
"packaging",
]

Expand Down
9 changes: 9 additions & 0 deletions tests/integrations/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import importlib
import os
import types

import pytest


def import_or_skip(module: str) -> types.ModuleType:
return importlib.import_module(module) if os.environ.get("REQUIRE_INTEGRATIONS") else pytest.importorskip(module)
4 changes: 2 additions & 2 deletions tests/integrations/fastapi/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import pytest
from tests.integrations import import_or_skip


pytest.importorskip("fastapi")
import_or_skip("fastapi")
6 changes: 3 additions & 3 deletions tests/integrations/faststream/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import pytest
from tests.integrations import import_or_skip


pytest.importorskip("faststream")
pytest.importorskip("nats")
import_or_skip("faststream")
import_or_skip("nats")
4 changes: 2 additions & 2 deletions tests/integrations/litestar/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import pytest
from tests.integrations import import_or_skip


pytest.importorskip("litestar")
import_or_skip("litestar")
Loading