Skip to content

Commit

Permalink
ci(github-workflows): add testing on MacOS and Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
tomassebestik committed Oct 1, 2024
1 parent 71b76c0 commit 4692a17
Show file tree
Hide file tree
Showing 3 changed files with 75 additions and 17 deletions.
14 changes: 8 additions & 6 deletions .github/workflows/dangerjs.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,19 @@
---
name: DangerJS Pull Request linter
name: 🎓 DangerJS Pull Request linter

on:
pull_request_target:
types: [opened, edited, reopened, synchronize]
pull_request_target: {types: [opened, edited, reopened, synchronize]}

permissions:
pull-requests: write
contents: write
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
pull-request-style-linter:
runs-on: ubuntu-latest
permissions:
pull-requests: write
contents: write
steps:
- name: Check out PR head
uses: actions/checkout@v4
Expand Down
67 changes: 61 additions & 6 deletions .github/workflows/plugin-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,43 @@ on:
pull_request:
push: {branches: master}

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
plugin-tests:
linux-tests:
runs-on: ubuntu-latest
permissions:
contents: read
strategy:
matrix:
python-version: ['3.9', '3.10', '3.11', '3.12']
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
cache: pip

- name: Install dependencies (Linux)
run: |
python -m venv venv
source venv/bin/activate
pip install --require-virtualenv --upgrade pip
pip install --require-virtualenv '.[test]'
- name: Run pytest, compare output with stored snapshots (Linux)
run: |
source venv/bin/activate
pytest -s
macos-tests:
runs-on: macos-latest
strategy:
matrix:
python-version: ['3.9', '3.10', '3.11', '3.12']
steps:
- name: Checkout repository
uses: actions/checkout@v4
Expand All @@ -24,14 +52,41 @@ jobs:
python-version: ${{ matrix.python-version }}
cache: pip

- name: Install dependencies
- name: Install dependencies (macOS)
run: |
python -m venv venv
source venv/bin/activate
pip install --require-virtualenv --upgrade pip
pip install --require-virtualenv '.[test]'
- name: Run pytest, compare output with stored snapshots
run: |-
- name: Run pytest, compare output with stored snapshots (macOS)
run: |
source venv/bin/activate
pytest -s
windows-tests:
runs-on: windows-latest
strategy:
matrix:
python-version: ['3.9', '3.10', '3.11', '3.12']
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
cache: pip

- name: Install dependencies (Windows)
run: |
python -m venv venv
venv\Scripts\python.exe -m pip install --require-virtualenv --upgrade pip
venv\Scripts\python.exe -m pip install --require-virtualenv .[test]
shell: cmd

- name: Run pytest, compare output with stored snapshots (Windows)
run: |
venv\Scripts\python.exe -m pytest -s
shell: cmd
11 changes: 6 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<img src="https://www.espressif.com/sites/all/themes/espressif/logo-black.svg" alt="Espressif logo" title="Espressif" align="right" height="20" />
</a>

# Commitizen plugin Espressif
# Commitizen plugin czEspressif

This is a plugin for Commitizen that makes it easy to create and maintain a well-organized and good-looking `CHANGELOG.md`. It also takes care of version bumping and helps you write commit messages that follow Espressif standards.

Expand All @@ -16,15 +16,16 @@ All of this with minimal config and setup, so your `pyproject.toml` file stays c
<img alt="GitHub Release" src="https://img.shields.io/github/v/release/espressif/cz-plugin-espressif? display_name=release&logo=github&logoColor=white&label=Release">
<img alt="PyPI - Python Version" src="https://img.shields.io/pypi/pyversions/czespressif?logo=pypi&logoColor=white&label=Pythons&link=https%3A%2F%2Fpypi.org%2Fproject%2Fczespressif%2F">
<img alt="Static Badge" src="https://img.shields.io/badge/pip%20install-czespressif-black?logo=python&logoColor=white">
<a href="/LICENSE"><img alt="Project License" src="https://img.shields.io/pypi/l/czespressif"/></a>
<br>
<img alt="GitHub contributors" src="https://img.shields.io/github/contributors/espressif/cz-plugin-espressif?logo=github&label=Contributors&color=purple">
<img alt="GitHub commit activity" src="https://img.shields.io/github/commit-activity/y/espressif/cz-plugin-espressif?logo=git&logoColor=white&label=Commits&color=purple">
<img alt="GitHub last commit" src="https://img.shields.io/github/last-commit/espressif/cz-plugin-espressif?logo=git&logoColor=white&label=Last%20commit">
<img alt="PyPI - Downloads" src="https://img.shields.io/pypi/dm/czespressif?logo=pypi&logoColor=white&label=PyPI%20downloads&color=blue&cacheSeconds=3600&link=https%3A%2F%2Fpypi.org%2Fproject%2Fczespressif%2F">
<a href="/LICENSE"><img alt="Project License" src="https://img.shields.io/pypi/l/czespressif"/></a>
<br>
<img alt="GitHub workflow SyncJira" src="https://img.shields.io/github/actions/workflow/status/espressif/cz-plugin-espressif/.github%2Fworkflows%2Fsync-jira.yml?branch=master&logo=jirasoftware&label=Sync with Jira">
<img alt="itHub workflow CodeQL" src="https://img.shields.io/github/actions/workflow/status/espressif/cz-plugin-espressif/.github%2Fworkflows%2Fcode-ql.yml?branch=master&label=CodeQL">
<img alt="GitHub workflow Tests Pytest" src="https://img.shields.io/github/actions/workflow/status/espressif/cz-plugin-espressif/.github%2Fworkflows%2Fplugin-tests.yml?branch=master&logo=pytest&logoColor=white&label=Tests&link=https%3A%2F%2Fgithub.com%2Fespressif%2Fcz-plugin-espressif%2Factions%2Fworkflows%2Fplugin-tests.yml">
<img alt="GitHub workflow SyncJira" src="https://img.shields.io/github/actions/workflow/status/espressif/cz-plugin-espressif/.github%2Fworkflows%2Fsync-jira.yml?branch=master&logo=jirasoftware&label=Sync with Jira&link=https%3A%2F%2Fgithub.com%2Fespressif%2Fcz-plugin-espressif%2Factions%2Fworkflows%2Fsync-jira.yml">
<img alt="GitHub workflow CodeQL" src="https://img.shields.io/github/actions/workflow/status/espressif/cz-plugin-espressif/.github%2Fworkflows%2Fcode-ql.yml?branch=master&label=CodeQL">
</p>
<small>
<b>
Expand All @@ -36,7 +37,7 @@ All of this with minimal config and setup, so your `pyproject.toml` file stays c
<hr>
</div>

- [Commitizen plugin Espressif](#commitizen-plugin-espressif)
- [Commitizen plugin czEspressif](#commitizen-plugin-czespressif)
- [Features](#features)
- [Compatibility](#compatibility)
- [Install](#install)
Expand Down

0 comments on commit 4692a17

Please sign in to comment.