Skip to content
Open
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
57 changes: 57 additions & 0 deletions .github/workflows/integration_tests.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: Integration Tests

permissions:
contents: read

on:
push:
branches:
- main
pull_request:
types:
- opened
- synchronize
- reopened
- ready_for_review
paths:
- "src/mistral_common/integrations/**"
- "tests/integrations/**"
- "pyproject.toml"
- "uv.lock"
- ".github/workflows/integration_tests.yaml"

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || 'no-pr' }}
cancel-in-progress: ${{ github.event.pull_request.number != null }}

jobs:
integration_tests:
if: ${{ github.event.pull_request.draft != true }}
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [
"3.10",
"3.11",
"3.12",
"3.13",
"3.14",
]
steps:
- name: Checkout
uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4

- name: Install uv
uses: astral-sh/setup-uv@d4b2f3b6ecc6e67c4457f6d3e41ec42d3d0fcb86 # v5
with:
python-version: ${{ matrix.python-version }}

- name: Install Dependencies
run: |
uv sync --frozen --all-extras --group dev --group test-integrations

# Parity tests (tests/integrations/chat_templates/transformers/) are handled
# by the chat_template_parity_tests job in lint_build_test.yaml which runs on every PR.
- name: Integration Tests
run: |
uv run --no-sync pytest tests/integrations/ --ignore=tests/integrations/chat_templates/transformers -v
6 changes: 3 additions & 3 deletions .github/workflows/lint_build_test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ jobs:
run: |
uv run mkdocs build --strict

integration_tests:
chat_template_parity_tests:
if: ${{ github.event.pull_request.draft != true }}
runs-on: ubuntu-latest
strategy:
Expand All @@ -121,6 +121,6 @@ jobs:
run: |
uv sync --frozen --all-extras --group dev --group test-integrations

- name: Integration Tests
- name: Chat Template Parity Tests (mistral-common vs transformers)
run: |
uv run --no-sync pytest tests/integrations/ -v
uv run --no-sync pytest tests/integrations/chat_templates/transformers/test_core_parity.py tests/integrations/chat_templates/transformers/test_thinking.py -v
Loading