From c414ac569336aa3ad8d8850f5b4b2502439ccf32 Mon Sep 17 00:00:00 2001 From: Christophe Favergeon Date: Tue, 18 Jun 2024 13:59:50 +0200 Subject: [PATCH] Improvement to test automation. github action change for adding missing pack. License now accepted automatically. Python run script detects when being run from github action. --- .github/workflows/runtest.yaml | 2 +- Testing/cmsis_build/runall.py | 9 +++++++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/workflows/runtest.yaml b/.github/workflows/runtest.yaml index 732dbe66..6fefbc3c 100644 --- a/.github/workflows/runtest.yaml +++ b/.github/workflows/runtest.yaml @@ -62,7 +62,7 @@ jobs: csolution list packs -s test_ac6.csolution.yml -m > required_packs.txt cat required_packs.txt - cpackget add -f required_packs.txt + cpackget add -a -f required_packs.txt - name: Execute run: | diff --git a/Testing/cmsis_build/runall.py b/Testing/cmsis_build/runall.py index 114d5679..8f767846 100644 --- a/Testing/cmsis_build/runall.py +++ b/Testing/cmsis_build/runall.py @@ -5,6 +5,7 @@ import os import colorama from colorama import init,Fore, Back, Style +from os import environ parser = argparse.ArgumentParser(description='Parse test description') parser.add_argument('-avh', nargs='?',type = str, default="C:/Keil_v5/ARM/VHT", help="AVH folder") @@ -12,11 +13,15 @@ parser.add_argument('-n', action='store_true', help="No force rebuild") parser.add_argument('-r', action='store_true', help="Raw results only") parser.add_argument('-c', action='store_true', help="Display cycles (so passing test are displayed)") -parser.add_argument('-l', action='store_true', help="Local run (not github action)") args = parser.parse_args() +GHACTION = False + +if "AVH_FVP_PLUGINS" in os.environ: + GHACTION = True + DEBUG=False if args.d: DEBUG=True @@ -332,7 +337,7 @@ def runAVH(build,core): print(res.msg,file=f) print(HTMLFOOTER,file=f) -if args.l: +if not GHACTION: if ERROR_OCCURED: sys.exit("Error occurred") else: