[6/7] CI: add basic selftest job

Message ID 20220331183117.22389-6-ross.burton@arm.com
State New
Headers show
Series [1/7] runfvp: propagate the exit code correctly | expand

Commit Message

Ross Burton March 31, 2022, 6:31 p.m. UTC
Currently this just executes the runfvp tests, but we can extend it over
time.

Signed-off-by: Ross Burton <ross.burton@arm.com>
---
 .gitlab-ci.yml  | 8 +++++++-
 ci/selftest.yml | 7 +++++++
 2 files changed, 14 insertions(+), 1 deletion(-)
 create mode 100644 ci/selftest.yml

Patch

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 6d24e0d9..21fcd43f 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -25,7 +25,7 @@  stages:
     - mkdir --verbose --parents $KAS_WORK_DIR $KAS_REPO_REF_DIR $SSTATE_DIR $DL_DIR $TOOLCHAIN_DIR $TOOLCHAIN_LINK_DIR
     # Must do this here, as it's the only way to make sure the toolchain is installed on the same builder
     - ./ci/get-binary-toolchains $DL_DIR $TOOLCHAIN_DIR $TOOLCHAIN_LINK_DIR
-    - sudo apt update && sudo apt install telnet -y
+    - sudo apt update && sudo apt install --yes telnet python3-subunit
 
 # Generalised fragment to do a Kas build
 .build:
@@ -201,6 +201,12 @@  tc1:
 toolchains:
   extends: .build
 
+selftest:
+  extends: .setup
+  script:
+    - KASFILES=./ci/qemuarm64.yml:./ci/selftest.yml
+    - kas shell --update --force-checkout $KASFILES -c 'oe-selftest --num-processes 1 --run-tests runfvp'
+
 # Validate layers are Yocto Project Compatible
 check-layers:
   extends: .setup
diff --git a/ci/selftest.yml b/ci/selftest.yml
new file mode 100644
index 00000000..9a587354
--- /dev/null
+++ b/ci/selftest.yml
@@ -0,0 +1,7 @@ 
+header:
+  version: 11
+
+local_conf_header:
+  setup: |
+    BB_LOGCONFIG = ""
+    SANITY_TESTED_DISTROS = ""