Skip to content

Commit

Permalink
Fixed GHA to run terrarium mypy tests
Browse files Browse the repository at this point in the history
  • Loading branch information
evilkost committed Nov 11, 2023
1 parent a739c2c commit b2b42c6
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/terrarium_check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,16 +32,17 @@ jobs:
- run: git config --global --add safe.directory /__w/${{ github.event.repository.name }}/${{ github.event.repository.name }}
- name: Setup common tools
run: pip install --no-input poetry pytest
- run: poetry config virtualenvs.create false
- name: Install dependencies
run: |
cd "terrarium/${{ matrix.value }}"
pip install --no-input .
poetry install --with mypy --without pytest
- name: Pytest
run: |
cd "terrarium/${{ matrix.value }}"
pytest .
mypu:
mypy:
runs-on: [ self-hosted, linux ]
container:
image: "python:3.11.0"
Expand All @@ -63,10 +64,11 @@ jobs:
- run: git config --global --add safe.directory /__w/${{ github.event.repository.name }}/${{ github.event.repository.name }}
- name: Setup common tools
run: pip install --no-input poetry mypy
- run: poetry config virtualenvs.create false
- name: Install dependencies
run: |
cd "terrarium/${{ matrix.value }}"
pip install --no-input .
poetry install --with mypy --without pytest
- name: Mypy
run: |
cd "terrarium/${{ matrix.value }}"
Expand Down
4 changes: 4 additions & 0 deletions terrarium/bi_ci/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,12 @@ clize = ">=5.0.0"
poetry = ">=1.5.0"
pyyaml = ">=6.0.1"

[tool.poetry.group.pytest.dependencies]
pytest = ">=7.4.3"

[tool.poetry.group.mypy.dependencies]
types_PyYAML = "*"
mypy = ">= 1.7.0"

[tool.poetry.scripts]
detect-affected-packages = "bi_ci.detect_affected_packages:main"
Expand Down

0 comments on commit b2b42c6

Please sign in to comment.