From 3512ca3b5ffdab731da0b9ee06a2b979d1aa343e Mon Sep 17 00:00:00 2001 From: silabs-bingocth Date: Wed, 24 Jul 2024 19:15:12 +0700 Subject: [PATCH] Create manual_test.yaml --- .github/workflows/manual_test.yaml | 307 +++++++++++++++++++++++++++++ 1 file changed, 307 insertions(+) create mode 100644 .github/workflows/manual_test.yaml diff --git a/.github/workflows/manual_test.yaml b/.github/workflows/manual_test.yaml new file mode 100644 index 00000000..6bdb65d0 --- /dev/null +++ b/.github/workflows/manual_test.yaml @@ -0,0 +1,307 @@ +# This workflow will triage pull requests and apply a label based on the +# paths that are modified in the pull request. +# +# To use this workflow, you will need to set up a .github/labeler.yml +# file with configuration. For more information, see: +# https://github.com/actions/labeler + +name: Manual Regression Test +on: + workflow_dispatch: + inputs: + branch: + description: 'Branch to test' + type: string + default: 'iec_efr32' + + test_mg12: + description: 'Run test with MG12?' + type: boolean + default: 'true' + test_mg24: + description: 'Run test with MG24?' + type: boolean + default: 'true' + + mg12_serialnum: + description: 'Serial number of target board to test for GCC MG12' + type: string + default: '440111030' + mg12_hostip: + type: string + default: '192.168.1.69' + mg24_serialnum: + description: 'Serial number of target board to test for GCC MG12' + type: string + default: '440124068' + mg24_hostip: + type: string + default: '192.168.1.100' + + security: + description: 'NON_SECURE_EN= true "CRC_32=1%20NON_SECURE_EN=false%20N_CRC_DEBUG=1%20APP_SECURE=false"' + type: string + default: 'APP_SECURE=false' + task: + type: choice + options: + - gen-only + - run-only + - all + component: + type: choice + options: + - all + - cpu_registers + - programme_counter + - invariable_memory + - system_clock + - variable_memory + - watchdog + - bist + - post + - irq + - integrated +jobs: + job1: + name: Generate Documents + runs-on: [self-hosted, sqa-ds-hn-003] + permissions: + contents: read + pull-requests: write + steps: + - name: Checkout + uses: actions/checkout@v4.1.7 + with: + ref: "${{ github.event.inputs.branch }}" + - name: Remove Libraries + run: rm -rf EFR32_ICE60730_Libraries + - name: Create directory for Libraries + run: mkdir EFR32_ICE60730_Libraries + - name: Generate Documents with Doxygen + run: doxygen qat.doxygen + - name: Upload Documents + uses: actions/upload-artifact@v4.3.4 + with: + path: + Doc/html/EFR32_ICE60730_Libraries/ + warn: Output a warning but do not fail the action + retention-days: 90 + + job2: + if: (success() || failure()) && github.event.inputs.test_mg12 == 'true' + needs: [job1] + name: GCC-MG12 regression test + runs-on: [self-hosted, sqa-ds-hn-006] + permissions: + contents: read + pull-requests: write + env: + COMPILER: GCC + PLATFORM: MG12 + TOOL_DIRS: /home/sqa/SimplicityStudio-5/SimplicityStudio_v5/developer/toolchains/gnu_arm/10.3_2021.10/bin + APP_TYPE: SecureApp + steps: + - name: Checkout + uses: actions/checkout@v4.1.7 + with: + ref: "${{ github.event.inputs.branch }}" + - name: Check working directory + run: + pwd && + ls -la + - name: Prepare Test directory + run: + chmod -R 777 ./Test + - name: Testing + run: + export HOST_IP=${{ github.event.inputs.mg12_hostip }} && + export SERIAL_NUM=${{ github.event.inputs.mg12_serialnum }} && + export SECURITY=${{ github.event.inputs.security }} && + export COMMAND=${{ github.event.inputs.command }} && + export COMPONENT=${{ github.event.inputs.component }} && + cd Test/ && + ls -la && + echo "./execute_test.sh $COMMAND $COMPONENT $SERIAL_NUM $PLATFORM $COMPILER $SECURITY" + ./execute_test.sh $COMMAND $COMPONENT $SERIAL_NUM $PLATFORM $COMPILER $SECURITY + + - name: Generate test report + run: + cd Test/ && + ls -la && + python test_script/get_report.py + + - name: Upload results and logs + uses: actions/upload-artifact@v4.3.4 + with: + path: + result/ + artifact/ + log/ + warn: Output a warning but do not fail the action + retention-days: 90 + + job3: + if: (success() || failure()) && github.event.inputs.test_mg24 == 'true' + needs: [job1, job2] + name: GCC-MG24 regression test + runs-on: [self-hosted, sqa-ds-hn-006] + permissions: + contents: read + pull-requests: write + env: + COMPILER: GCC + PLATFORM: MG24 + TOOL_DIRS: /home/sqa/SimplicityStudio-5/SimplicityStudio_v5/developer/toolchains/gnu_arm/10.3_2021.10/bin + APP_TYPE: SecureApp + steps: + - name: Checkout + uses: actions/checkout@v4.1.7 + with: + ref: "${{ github.event.inputs.branch }}" + - name: Check working directory + run: + pwd && + ls -la + - name: Prepare Test directory + run: + chmod -R 777 ./Test + + - name: Testing + run: + export HOST_IP=${{ github.event.inputs.mg24_hostip }} && + export SERIAL_NUM=${{ github.event.inputs.mg24_serialnum }} && + export SECURITY=${{ github.event.inputs.security }} && + export COMMAND=${{ github.event.inputs.command }} && + export COMPONENT=${{ github.event.inputs.component }} && + cd Test/ && + ls -la && + echo "./execute_test.sh $COMMAND $COMPONENT $SERIAL_NUM $PLATFORM $COMPILER $SECURITY" && + ./execute_test.sh $COMMAND $COMPONENT $SERIAL_NUM $PLATFORM $COMPILER $SECURITY + + - name: Generate test report + run: + cd Test/ && + ls -la && + python test_script/get_report.py + + - name: Upload results and logs + uses: actions/upload-artifact@v4.3.4 + with: + path: + result/ + artifact/ + log/ + warn: Output a warning but do not fail the action + retention-days: 90 + + job4: + if: (success() || failure()) && github.event.inputs.test_mg12 == 'true' + needs: [job1, job2, job3] + name: IAR-MG12 regression test + runs-on: [self-hosted, sqa-ds-hn-006] + permissions: + contents: read + pull-requests: write + env: + COMPILER: IAR + PLATFORM: MG12 + TOOL_DIRS: /home/sqa/EmbeddedWorkbench8.4/arm/bin + APP_TYPE: SecureApp + steps: + - name: Checkout + uses: actions/checkout@v4.1.7 + with: + ref: "${{ github.event.inputs.branch }}" + - name: Check working directory + run: + pwd && + ls -la + - name: Prepare Test directory + run: + chmod -R 777 ./Test + + - name: Testing + run: + export HOST_IP=${{ github.event.inputs.mg12_hostip }} && + export SERIAL_NUM=${{ github.event.inputs.mg12_serialnum }} && + export SECURITY=${{ github.event.inputs.security }} && + export COMMAND=${{ github.event.inputs.command }} && + export COMPONENT=${{ github.event.inputs.component }} && + cd Test && + ls -la && + echo "./execute_test.sh $COMMAND $COMPONENT $SERIAL_NUM $PLATFORM $COMPILER $SECURITY" && + ./execute_test.sh $COMMAND $COMPONENT $SERIAL_NUM $PLATFORM $COMPILER $SECURITY + + - name: Generate test report + run: + cd Test/ && + ls -la && + python test_script/get_report.py + + - name: Upload results and logs + uses: actions/upload-artifact@v4.3.4 + with: + path: + result/ + artifact/ + log/ + warn: Output a warning but do not fail the action + retention-days: 90 + + job5: + if: (success() || failure()) && github.event.inputs.test_mg24 == 'true' + needs: [job1, job2, job3, job4] + name: IAR-MG24 regression test + runs-on: [self-hosted, sqa-ds-hn-006] + permissions: + contents: read + pull-requests: write + env: + COMPILER: IAR + PLATFORM: MG24 + TOOL_DIRS: /home/sqa/EmbeddedWorkbench8.4/arm/bin + APP_TYPE: SecureApp + + steps: + - name: Checkout + uses: actions/checkout@v4.1.7 + with: + ref: "${{ github.event.inputs.branch }}" + + - name: Check working directory + run: + pwd && + ls -la + - name: Prepare Test directory + run: + chmod -R 777 ./Test + + - name: Testing + run: + export HOST_IP=${{ github.event.inputs.mg24_hostip }} && + export SERIAL_NUM=${{ github.event.inputs.mg24_serialnum }} && + export SECURITY=${{ github.event.inputs.security }} && + export COMMAND=${{ github.event.inputs.command }} && + export COMPONENT=${{ github.event.inputs.component }} && + cd Test && + ls -la && + echo "./execute_test.sh $COMMAND $COMPONENT $SERIAL_NUM $PLATFORM $COMPILER $SECURITY" && + ./execute_test.sh $COMMAND $COMPONENT $SERIAL_NUM $PLATFORM $COMPILER $SECURITY + + - name: Generate test report + run: + cd Test/ && + ls -la && + python test_script/get_report.py + + - name: Upload results and logs + uses: actions/upload-artifact@v4.3.4 + with: + path: + result/ + artifact/ + log/ + warn: Output a warning but do not fail the action + retention-days: 90 +