CI HW Testing Update (#7911)
* Update upload-artifact action to v3 * Fix deprecated set-output * updated path + error if no files found * update path * update path + debug ls * dbg path print * dbg path remove +added echo with buildpath * change build_dir * fix upload-artifact paths * changed build_dirs * move sketchname variable * Update touch pressed value * Run one test only for faster debuging * Revert "Run one test only for faster debuging" This reverts commit e2bf6a8551e5b4abe5bb6201d3175257bc40fe44. * fix value
This commit is contained in:
parent
30ab1c3cb5
commit
087ebe0ee6
4 changed files with 19 additions and 16 deletions
8
.github/scripts/sketch_utils.sh
vendored
8
.github/scripts/sketch_utils.sh
vendored
|
|
@ -117,12 +117,14 @@ function build_sketch(){ # build_sketch <ide_path> <user_path> <path-to-ino> [ex
|
|||
# 3. Created at the sketch level as "buildX" where X is the number
|
||||
# of configuration built in case of a multiconfiguration test.
|
||||
|
||||
sketchname=$(basename $sketchdir)
|
||||
|
||||
ARDUINO_CACHE_DIR="$HOME/.arduino/cache.tmp"
|
||||
if [ -n "$ARDUINO_BUILD_DIR" ]; then
|
||||
build_dir="$ARDUINO_BUILD_DIR"
|
||||
elif [ $len -eq 1 ]; then
|
||||
# build_dir="$sketchdir/build"
|
||||
build_dir="$HOME/.arduino/build.tmp"
|
||||
build_dir="$HOME/.arduino/tests/$sketchname/build.tmp"
|
||||
fi
|
||||
|
||||
mkdir -p "$ARDUINO_CACHE_DIR"
|
||||
|
|
@ -130,13 +132,12 @@ function build_sketch(){ # build_sketch <ide_path> <user_path> <path-to-ino> [ex
|
|||
do
|
||||
if [ $len -ne 1 ]; then
|
||||
# build_dir="$sketchdir/build$i"
|
||||
build_dir="$HOME/.arduino/build$i.tmp"
|
||||
build_dir="$HOME/.arduino/tests/$sketchname/build$i.tmp"
|
||||
fi
|
||||
rm -rf $build_dir
|
||||
mkdir -p $build_dir
|
||||
|
||||
currfqbn=`echo $fqbn | jq -r --argjson i $i '.[$i]'`
|
||||
sketchname=$(basename $sketchdir)
|
||||
|
||||
if [ -f "$ide_path/arduino-cli" ]; then
|
||||
echo "Building $sketchname with arduino-cli and FQBN=$currfqbn"
|
||||
|
|
@ -152,6 +153,7 @@ function build_sketch(){ # build_sketch <ide_path> <user_path> <path-to-ino> [ex
|
|||
$xtra_opts "${sketchdir}"
|
||||
elif [ -f "$ide_path/arduino-builder" ]; then
|
||||
echo "Building $sketchname with arduino-builder and FQBN=$currfqbn"
|
||||
echo "Build path = $build_dir"
|
||||
|
||||
$ide_path/arduino-builder -compile -logger=human -core-api-version=10810 \
|
||||
-fqbn=\"$currfqbn\" \
|
||||
|
|
|
|||
6
.github/scripts/tests_run.sh
vendored
6
.github/scripts/tests_run.sh
vendored
|
|
@ -15,7 +15,8 @@ function run_test() {
|
|||
fi
|
||||
|
||||
if [ $len -eq 1 ]; then
|
||||
build_dir="tests/$sketchname/build"
|
||||
# build_dir="tests/$sketchname/build"
|
||||
build_dir="$HOME/.arduino/tests/$sketchname/build.tmp"
|
||||
report_file="tests/$sketchname/$sketchname.xml"
|
||||
fi
|
||||
|
||||
|
|
@ -27,7 +28,8 @@ function run_test() {
|
|||
fi
|
||||
|
||||
if [ $len -ne 1 ]; then
|
||||
build_dir="tests/$sketchname/build$i"
|
||||
# build_dir="tests/$sketchname/build$i"
|
||||
build_dir="$HOME/.arduino/tests/$sketchname/build$i.tmp"
|
||||
report_file="tests/$sketchname/$sketchname$i.xml"
|
||||
fi
|
||||
|
||||
|
|
|
|||
19
.github/workflows/hil.yml
vendored
19
.github/workflows/hil.yml
vendored
|
|
@ -39,7 +39,7 @@ jobs:
|
|||
set -e
|
||||
rm sketches.txt
|
||||
CHUNKS=$(jq -c -n '$ARGS.positional' --args `seq 0 1 $((sketches - 1))`)
|
||||
echo "::set-output name=chunks::${CHUNKS}"
|
||||
echo "chunks=${CHUNKS}" >>$GITHUB_OUTPUT
|
||||
|
||||
Build:
|
||||
needs: gen_chunks
|
||||
|
|
@ -49,21 +49,20 @@ jobs:
|
|||
matrix:
|
||||
chip: ['esp32', 'esp32s2', 'esp32s3', 'esp32c3']
|
||||
chunks: ${{fromJson(needs.gen_chunks.outputs.chunks)}}
|
||||
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Build sketches
|
||||
run: |
|
||||
bash .github/scripts/tests_build.sh -c -t ${{matrix.chip}} -i ${{matrix.chunks}} -m ${{env.MAX_CHUNKS}}
|
||||
- name: Upload ${{matrix.chip}}-${{matrix.chunks}} artifacts
|
||||
uses: actions/upload-artifact@v2
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: ${{matrix.chip}}-${{matrix.chunks}}.artifacts
|
||||
path: |
|
||||
tests/*/build*/*.bin
|
||||
tests/*/build*/*.json
|
||||
~/.arduino/tests/*/build*.tmp/*.bin
|
||||
~/.arduino/tests/*/build*.tmp/*.json
|
||||
if-no-files-found: error
|
||||
Test:
|
||||
needs: [gen_chunks, Build]
|
||||
name: ${{matrix.chip}}-Test#${{matrix.chunks}}
|
||||
|
|
@ -87,10 +86,10 @@ jobs:
|
|||
uses: actions/checkout@v3
|
||||
|
||||
- name: Download ${{matrix.chip}}-${{matrix.chunks}} artifacts
|
||||
uses: actions/download-artifact@v2
|
||||
uses: actions/download-artifact@v3
|
||||
with:
|
||||
name: ${{matrix.chip}}-${{matrix.chunks}}.artifacts
|
||||
path: tests/
|
||||
path: ~/.arduino/tests/
|
||||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
|
|
@ -103,7 +102,7 @@ jobs:
|
|||
bash .github/scripts/tests_run.sh -c -t ${{matrix.chip}} -i ${{matrix.chunks}} -m ${{env.MAX_CHUNKS}} -e
|
||||
|
||||
- name: Upload test result artifacts
|
||||
uses: actions/upload-artifact@v2
|
||||
uses: actions/upload-artifact@v3
|
||||
if: always()
|
||||
with:
|
||||
name: test_results-${{matrix.chip}}-${{matrix.chunks}}
|
||||
|
|
@ -118,7 +117,7 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Upload
|
||||
uses: actions/upload-artifact@v2
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: Event File
|
||||
path: ${{github.event_path}}
|
||||
|
|
|
|||
|
|
@ -59,7 +59,7 @@ uint8_t TOUCH_GPIOS[] = {1,2,3,4,5,6,7,8,9,10,11,12/*,13,14*/};
|
|||
#define INTERRUPT_THRESHOLD 30000
|
||||
#elif CONFIG_IDF_TARGET_ESP32S3
|
||||
#define RELEASED_VALUE 25000 //25000- read value to pass test
|
||||
#define PRESSED_VALUE 100000 //150000+ read value to pass test
|
||||
#define PRESSED_VALUE 90000 //90000+ read value to pass test
|
||||
#define INTERRUPT_THRESHOLD 80000
|
||||
#else
|
||||
#error Test not currently supported on this chip. Please adjust and try again!
|
||||
|
|
|
|||
Loading…
Reference in a new issue