Skip to content

Add support for multiple config entries #302

Add support for multiple config entries

Add support for multiple config entries #302

Workflow file for this run

name: CI
on:
push:
branches:
- '*'
tags-ignore:
- 'v*'
pull_request:
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.11'
- uses: pre-commit/[email protected]
tests:
name: Run tests (${{ matrix.ha-version }})
runs-on: ubuntu-latest
strategy:
matrix:
include:
- ha-version: '2023.7'
latest: true
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.11'
cache: pip
cache-dependency-path: tests/requirements_${{ matrix.ha-version }}.txt
- name: Install dependencies
run: |
pip install -r tests/requirements_${{ matrix.ha-version }}.txt
# https://github.com/python/mypy/issues/8545
- name: Fix homeassistant type checking
run: |
python -c 'from pathlib import Path; import homeassistant; (Path(homeassistant.__file__).parent / Path("py.typed")).touch()'
- name: Type checking
run: mypy .
- name: Test with pytest
run: pytest --cov-report xml --cov
- name: Upload coverage report
uses: codecov/codecov-action@v2
if: ${{ matrix.latest == true }}
validate:
name: Validate for HACS
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v3
- name: HACS validation
uses: hacs/action@main
with:
category: integration