Skip to content

Commit

Permalink
faster testing on pre-built container
Browse files Browse the repository at this point in the history
  • Loading branch information
bertmelis authored Jul 15, 2024
1 parent 2a70d19 commit 0770e78
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 47 deletions.
30 changes: 9 additions & 21 deletions .github/workflows/build_platformio.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on: [push, pull_request]
jobs:
build-for-esp8266:
runs-on: ubuntu-latest
container: ghcr.io/bertmelis/pio-test-container
strategy:
matrix:
example: [
Expand All @@ -15,18 +16,13 @@ jobs:
examples/tls-esp8266/tls-esp8266.ino
]
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
- uses: actions/checkout@v4
- uses: actions/cache@v4
with:
path: |
~/.cache/pip
~/.platformio/.cache
key: ${{ runner.os }}-pio
- uses: actions/setup-python@v4
with:
python-version: '3.9'
- name: Install PlatformIO Core
run: pip install --upgrade platformio
- name: Download external libraries
run: pio pkg install --global --library me-no-dev/ESPAsyncTCP
- name: Build PlatformIO examples
Expand All @@ -36,6 +32,7 @@ jobs:

build-for-esp32:
runs-on: ubuntu-latest
container: ghcr.io/bertmelis/pio-test-container
strategy:
matrix:
example: [
Expand All @@ -45,18 +42,13 @@ jobs:
examples/tls-esp32/tls-esp32.ino
]
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
- uses: actions/checkout@v4
- uses: actions/cache@v4
with:
path: |
~/.cache/pip
~/.platformio/.cache
key: ${{ runner.os }}-pio
- uses: actions/setup-python@v4
with:
python-version: '3.9'
- name: Install PlatformIO Core
run: pip install --upgrade platformio
- name: Download external libraries
run: pio pkg install --global --library me-no-dev/AsyncTCP
- name: Build PlatformIO examples
Expand All @@ -66,24 +58,20 @@ jobs:

build-for-linux:
runs-on: ubuntu-latest
container: ghcr.io/bertmelis/pio-test-container
strategy:
matrix:
example: [
examples/simple-linux/main.cpp
]
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
- uses: actions/checkout@v4
- uses: actions/cache@v4
with:
path: |
~/.cache/pip
~/.platformio/.cache
key: ${{ runner.os }}-pio
- uses: actions/setup-python@v4
with:
python-version: '3.9'
- name: Install PlatformIO Core
run: pip install --upgrade platformio
- name: Build PlatformIO examples
run: pio ci --lib="." --project-conf="./examples/simple-linux/platformio.ini"
env:
Expand Down
13 changes: 2 additions & 11 deletions .github/workflows/cppcheck.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,10 @@ on: [push, pull_request]

jobs:
build:

runs-on: ubuntu-latest

container: ghcr.io/bertmelis/pio-test-container
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install platformio
- uses: actions/checkout@v4
- name: Cppcheck
run: |
pio check --fail-on-defect=medium --fail-on-defect=high --flags "--inline-suppr --enable=warning --enable=style --enable=performance --suppress=unusedFunction --suppress=preprocessorErrorDirective" --skip-packages
6 changes: 3 additions & 3 deletions .github/workflows/cpplint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: '3.10'
python-version: '3.11'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
Expand Down
14 changes: 2 additions & 12 deletions .github/workflows/test_platformio.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,10 @@ on: [push, pull_request]

jobs:
build:

runs-on: ubuntu-latest

container: ghcr.io/bertmelis/pio-test-container
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install dependencies
run: |
sudo apt update && sudo apt install -y valgrind
python -m pip install --upgrade pip
pip install platformio
- uses: actions/checkout@v4
- name: Start Mosquitto
uses: namoshek/mosquitto-github-action@v1
with:
Expand Down

0 comments on commit 0770e78

Please sign in to comment.