Skip to content

feat: add support of negation config rules #16

feat: add support of negation config rules

feat: add support of negation config rules #16

name: Test Python Package
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.run_id }}
cancel-in-progress: false
on:
pull_request:
paths:
- "idf_build_apps/**"
- ".github/workflows/test-build-idf-apps.yml"
push:
branches:
- main
env:
IDF_PATH: /opt/esp/idf
defaults:
run:
shell: bash
jobs:
build-python-packages:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: '3.10'
- run: |
pip install -U pip
pip install flit
flit build
- name: Upload built python packages
uses: actions/upload-artifact@v7
with:
name: wheel
path: dist/idf_build_apps-*.whl
build-apps-on-idf-env:
if: ${{ github.ref == 'refs/heads/main' || contains(github.event.pull_request.labels.*.name, 'test-old-idf-releases') }}
needs: build-python-packages
strategy:
matrix:
idf-branch:
[release-v5.2, release-v5.3, release-v5.4, release-v5.5, release-v6.0]
runs-on: ubuntu-latest
container:
image: espressif/idf:${{ matrix.idf-branch }}
steps:
- name: Download wheel
uses: actions/download-artifact@v8
with:
name: wheel
- name: Build the Apps
run: |
bash $IDF_PATH/install.sh
. $IDF_PATH/export.sh
pip install idf_build_apps-*.whl
cd $IDF_PATH/examples/get-started/hello_world
echo 'CONFIG_IDF_TARGET="esp32"' >sdkconfig.defaults
idf-build-apps build --build-dir build_@t --size-file size_info.json
test -f build_esp32/hello_world.bin
test -f build_esp32/size_info.json
test ! -f build_esp32s2/hello_world.bin
build-apps-on-idf-master:
runs-on: ubuntu-latest
container:
image: espressif/idf:latest
env:
FLIT_ROOT_INSTALL: 1
steps:
- uses: actions/checkout@v6
- name: Build the Apps
run: |
bash $IDF_PATH/install.sh
. $IDF_PATH/export.sh
pip install flit
flit install -s
python -m idf_build_apps build -vv -t esp32 \
-p $IDF_PATH/examples/get-started/hello_world \
--size-file size_info.json
pytest --cov idf_build_apps --cov-report term-missing:skip-covered --junit-xml pytest.xml | tee pytest-coverage.txt
- name: Save PR number
if: github.event.number
run: echo ${{ github.event.number }} > pr_number.txt
- name: Upload test results
uses: actions/upload-artifact@v6
if: always() && github.event_name == 'pull_request'
with:
name: test-results
path: |
pr_number.txt
pytest-coverage.txt
pytest.xml
retention-days: 7