Skip to content

feat(tests): add Docker smoke test for clean-machine scenario #5

feat(tests): add Docker smoke test for clean-machine scenario

feat(tests): add Docker smoke test for clean-machine scenario #5

Workflow file for this run

name: Test
on:
push:
branches: [master, main]
pull_request:
branches: [master, main]
jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
python-version: ["3.10", "3.11", "3.12", "3.13"]
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
pip install -e ".[dev]"
- name: Run unit tests
run: pytest tests/ -v
integration-docker:
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.12
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Build wheel
run: |
pip install build
python -m build --wheel
- name: Build Docker image
run: docker build -t opencode-py-test tests/docker/
- name: Run smoke test
run: |
docker run --rm \
-v "${{ github.workspace }}/dist:/dist" \
opencode-py-test \
bash -c "pip install --force-reinstall --no-deps /dist/*.whl && python test_smoke.py"