Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tweaking CI #82

Merged
merged 3 commits into from
Apr 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/release-drafter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
pull-requests: write
runs-on: ubuntu-latest
steps:
- name: Checkout
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
Expand Down
10 changes: 7 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,15 @@ jobs:
name: Prepare release asset
runs-on: ubuntu-latest
steps:
- name: Check out repository
- name: Checkout repository
uses: actions/checkout@v4
- name: "Set manifest version number"
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Set manifest version number
run: |
python3 ${{ github.workspace }}/.github/scripts/update_hacs_manifest.py --version ${{ github.ref_name }}
python ${{ github.workspace }}/.github/scripts/update_hacs_manifest.py --version ${{ github.ref_name }}
- name: Create zip
run: |
cd custom_components/tech
Expand Down
16 changes: 9 additions & 7 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Run Tech API tests
on:
push:
schedule:
- cron: '0 4 * * *'
- cron: "0 4 * * *"
workflow_dispatch:

jobs:
Expand All @@ -12,14 +12,15 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.11"]
python-version: ["3.12"]

steps:
- uses: MathRobin/[email protected]
with:
timezoneLinux: "Europe/Berlin"
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
Expand All @@ -30,11 +31,12 @@ jobs:
pip install -r requirements_test_api.txt
- name: Install dependencies
run: pip install pytest pytest-md pytest-emoji
- uses: pavelzw/pytest-action@v2
- name: Run tests
uses: pavelzw/pytest-action@v2
with:
emoji: true
verbose: true
job-summary: true
custom-arguments: 'tests/tests_api --cov-report=term-missing --cov=custom_components.tech.tech tests/'
custom-arguments: "tests/tests_api --cov-report=term-missing --cov=custom_components.tech.tech tests/"
click-to-expand: true
report-title: 'Tech API test report'
report-title: "Tech API test report"
16 changes: 12 additions & 4 deletions .github/workflows/validate.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,25 @@ on:
- cron: "0 0 * * *"
workflow_dispatch:

permissions:
contents: read

jobs:
validate-hassfest:
name: Validate Hassfest
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v4"
- uses: home-assistant/actions/hassfest@master
- name: Checkout repository
uses: actions/checkout@v4
- name: Hassfest validation
uses: home-assistant/actions/hassfest@master
validate-hacs:
name: Validate HACS
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v4"
- name: Checkout repository
uses: actions/checkout@v4
- name: HACS validation
uses: "hacs/action@main"
uses: hacs/action@main
with:
category: "integration"
Loading