Skip to content

nightly-gtest

nightly-gtest #145

Workflow file for this run

name: nightly-gtest
on:
# allow manually trigger
workflow_dispatch:
schedule:
- cron: '0 20 * * *' # Every day at 8 PM UTC
permissions:
contents: read
jobs:
run-gtest:
concurrency:
group: gtest-${{ github.workflow }}-${{ github.ref }}-${{ matrix.nic }}
cancel-in-progress: true
strategy:
matrix:
nic:
- e810
- e810-dell
- e830
fail-fast: false
runs-on: ${{ matrix.nic }}
timeout-minutes: 300
steps:
- name: 'preparation: Harden Runner'
uses: step-security/harden-runner@8d3c67de8e2fe68ef647c8db1e6a09f647780f40 # v2.19.0
with:
egress-policy: audit
- name: 'preparation: Checkout MTL'
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
ref: '${{ github.ref }}'
- uses: ./.github/actions/build
- name: 'preparation: Start MtlManager at background'
run: |
sudo MtlManager &
- name: run gtest bare metal
if: always()
timeout-minutes: 300
env:
NIGHTLY: 1
EXIT_ON_FAILURE: 0
LOG_FILE: "${{ github.workspace }}/gtest.log"
TEST_CASE_TIMEOUT: 1800
run: |
sudo -E "${{ github.workspace }}/.github/scripts/gtest.sh"
- name: 'cleanup: Kill test processes'
if: always()
run: |
sudo pkill -9 -f "gtest.sh" || true
sudo killall -SIGKILL KahawaiTest KahawaiUfdTest KahawaiUplTest || true
sudo killall -SIGINT MtlManager || true
- name: 'collect: System status report'
if: always()
run: |
./script/status_report.sh
# Rename to include NIC info
for dir in mtl_system_status_*; do
if [ -d "$dir" ]; then
mv "$dir" "system-info-${{ matrix.nic }}"
break
fi
done
- name: "upload report gtest"
if: always()
id: upload-report-gtest
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: nightly-gtest-report-${{ matrix.nic }}
path: |
gtest.log
- name: "upload system info"
if: always()
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: system-info-${{ matrix.nic }}
path: system-info-${{ matrix.nic }}/