Skip to content

Commit ccba56d

Browse files
jhonabreulclaude
andcommitted
CI: pass tests path to pytest so --runtime option registers
The --runtime option is added by tests/conftest.py via pytest_addoption. pytest parses command-line options using only the initial conftests (rootdir + path args) before testpaths is applied, and the repo root has no conftest.py. Running bare `pytest --runtime netcore` therefore failed with "unrecognized arguments: --runtime". Pass the tests path explicitly so tests/conftest.py is loaded as an initial conftest and the option is registered before argument parsing. Apply to main.yml and both ARM.yml pytest steps. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 parent 51dc1ac commit ccba56d

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

.github/workflows/ARM.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,10 @@ jobs:
4242
run: dotnet test --logger "console;verbosity=detailed" src/embed_tests/
4343

4444
- name: Python Tests (Mono)
45-
run: python -m pytest --runtime mono
45+
run: python -m pytest --runtime mono tests
4646

4747
- name: Python Tests (.NET Core)
48-
run: python -m pytest --runtime netcore
48+
run: python -m pytest --runtime netcore tests
4949

5050
- name: Python tests run from .NET
5151
run: dotnet test src/python_tests_runner/

.github/workflows/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ jobs:
7171
# exercised from Python.
7272
- name: Python Tests (.NET Core)
7373
if: ${{ matrix.platform == 'x64' }}
74-
run: pytest --runtime netcore
74+
run: pytest --runtime netcore tests
7575

7676
- name: Python tests run from .NET
7777
run: dotnet test --runtime any-${{ matrix.platform }} src/python_tests_runner/

0 commit comments

Comments
 (0)