fix: integration tests fixes
Signed-off-by: Rafal Zielinski <sq4ind@gmail.com>
This commit is contained in:
@@ -1,3 +1,4 @@
|
|||||||
|
# .github/workflows/integration-tests.yml
|
||||||
name: 🧪 Integration Testing
|
name: 🧪 Integration Testing
|
||||||
|
|
||||||
on:
|
on:
|
||||||
@@ -12,24 +13,23 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
python-version: ['3.11', '3.12', '3.13']
|
python-version: ['3.13']
|
||||||
home-assistant-version: ['2025.9.4']
|
home-assistant-version: ['2025.9.4']
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: 📥 Checkout Code
|
- name: 📥 Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: 🐍 Set up Python ${{ matrix.python-version }}
|
- name: 🐍 Set up Python
|
||||||
uses: actions/setup-python@v5
|
uses: actions/setup-python@v5
|
||||||
with:
|
with:
|
||||||
python-version: ${{ matrix.python-version }}
|
python-version: ${{ matrix.python-version }}
|
||||||
|
|
||||||
- name: 🗂️ Get pip cache directory
|
- name: 🗂️ Cache pip
|
||||||
id: pip-cache-dir
|
id: pip-cache-dir
|
||||||
run: echo "dir=$(pip cache dir)" >> $GITHUB_OUTPUT
|
run: echo "dir=$(pip cache dir)" >> "$GITHUB_OUTPUT"
|
||||||
|
|
||||||
- name: 📦 Cache pip dependencies
|
- uses: actions/cache@v4
|
||||||
uses: actions/cache@v4
|
|
||||||
with:
|
with:
|
||||||
path: ${{ steps.pip-cache-dir.outputs.dir }}
|
path: ${{ steps.pip-cache-dir.outputs.dir }}
|
||||||
key: ${{ runner.os }}-pip-${{ matrix.python-version }}-${{ hashFiles('requirements.txt') }}
|
key: ${{ runner.os }}-pip-${{ matrix.python-version }}-${{ hashFiles('requirements.txt') }}
|
||||||
@@ -37,19 +37,20 @@ jobs:
|
|||||||
${{ runner.os }}-pip-${{ matrix.python-version }}-
|
${{ runner.os }}-pip-${{ matrix.python-version }}-
|
||||||
${{ runner.os }}-pip-
|
${{ runner.os }}-pip-
|
||||||
|
|
||||||
- name: 📦 Install Dependencies
|
- name: 📦 Install deps
|
||||||
run: |
|
run: |
|
||||||
python -m pip install --upgrade pip
|
python -m pip install -U pip
|
||||||
pip install -r requirements.txt
|
pip install -r requirements.txt
|
||||||
|
|
||||||
- name: 📁 Create custom_components directory
|
- name: 📁 Ensure custom_components package
|
||||||
run: |
|
run: |
|
||||||
mkdir -p custom_components
|
mkdir -p custom_components
|
||||||
touch custom_components/__init__.py
|
touch custom_components/__init__.py
|
||||||
|
|
||||||
- name: 🧪 Run Integration Tests
|
- name: 🧪 Pytest
|
||||||
run: python -m pytest tests/ -v \
|
run: |
|
||||||
--cov=custom_components/adguard_hub \
|
python -m pytest tests/ -v \
|
||||||
--cov-report=xml \
|
--cov=custom_components/adguard_hub \
|
||||||
--cov-report=term-missing \
|
--cov-report=xml \
|
||||||
--asyncio-mode=auto
|
--cov-report=term-missing \
|
||||||
|
--asyncio-mode=auto
|
||||||
|
Reference in New Issue
Block a user