Skip to content
Snippets Groups Projects
Commit ce276374 authored by Chase Qi's avatar Chase Qi
Browse files

ci: enable pre-merge testing in LAVA on qemu devices


Signed-off-by: default avatarChase Qi <chase.qi@linaro.org>
parent 70a237c7
No related branches found
No related tags found
No related merge requests found
This commit is part of merge request !148. Comments created here will be created in the context of that merge request.
......@@ -196,20 +196,14 @@ publish-seco-intel-b68:
# Run the build for scheduled pipelines.
- if: '$CI_PIPELINE_SOURCE == "schedule"'
# Mimic the updated rules for lava-test from the bitbake-workspace.
.lava-test:
rules:
- if: '$CI_LAVA_TOKEN == null'
when: never
- if: '$CI_PIPELINE_SOURCE == "schedule"'
# Mimic the updated rules for lava-report from the bitbake-workspace.
.lava-report:
.lava-test-scheduled:
extends: .lava-test
variables:
CI_SQUAD_PROJECT_NAME: "oniro"
rules:
- if: '$CI_LAVA_TOKEN == null'
- if: '$CI_SQUAD_TOKEN == null'
when: never
- if: '$CI_PIPELINE_SOURCE == "schedule"'
when: manual
##
## Submit jobs to LAVA
......@@ -237,7 +231,7 @@ lava-qemu-x86_64:
lava-raspberrypi4-64:
needs: [linux-raspberrypi4-64]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: raspberrypi4-64
CI_BUILD_JOB_NAME: linux-raspberrypi4-64
......@@ -247,7 +241,7 @@ lava-raspberrypi4-64:
lava-seco-intel-b68:
needs: [linux-seco-intel-b68]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: seco-intel-b68
CI_BUILD_JOB_NAME: linux-seco-intel-b68
......@@ -257,7 +251,7 @@ lava-seco-intel-b68:
lava-seco-c61:
needs: [linux-seco-imx8mm-c61-4gb]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: seco-imx8mm-c61-4gb
CI_BUILD_JOB_NAME: linux-seco-imx8mm-c61-4gb
......@@ -267,7 +261,7 @@ lava-seco-c61:
lava-qemu-x86-ltp:
needs: [linux-qemu-x86]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: qemux86
CI_BUILD_JOB_NAME: linux-qemu-x86
......@@ -277,7 +271,7 @@ lava-qemu-x86-ltp:
lava-qemu-x86_64-ltp:
needs: [linux-qemu-x86_64]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: qemux86-64
CI_BUILD_JOB_NAME: linux-qemu-x86_64
......@@ -287,7 +281,7 @@ lava-qemu-x86_64-ltp:
lava-raspberrypi4-64-ltp:
needs: [linux-raspberrypi4-64]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: raspberrypi4-64
CI_BUILD_JOB_NAME: linux-raspberrypi4-64
......@@ -297,7 +291,7 @@ lava-raspberrypi4-64-ltp:
lava-seco-intel-b68-ltp:
needs: [linux-seco-intel-b68]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: seco-intel-b68
CI_BUILD_JOB_NAME: linux-seco-intel-b68
......@@ -307,7 +301,7 @@ lava-seco-intel-b68-ltp:
lava-seco-c61-ltp:
needs: [linux-seco-imx8mm-c61-4gb]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: seco-imx8mm-c61-4gb
CI_BUILD_JOB_NAME: linux-seco-imx8mm-c61-4gb
......@@ -317,7 +311,7 @@ lava-seco-c61-ltp:
lava-qemu-x86_64-kselftest:
needs: [linux-qemu-x86_64]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: qemux86-64
CI_BUILD_JOB_NAME: linux-qemu-x86_64
......@@ -327,7 +321,7 @@ lava-qemu-x86_64-kselftest:
lava-raspberrypi4-64-kselftest:
needs: [linux-raspberrypi4-64]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: raspberrypi4-64
CI_BUILD_JOB_NAME: linux-raspberrypi4-64
......@@ -337,7 +331,7 @@ lava-raspberrypi4-64-kselftest:
lava-seco-c61-kselftest:
needs: [linux-seco-imx8mm-c61-4gb]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: seco-imx8mm-c61-4gb
CI_BUILD_JOB_NAME: linux-seco-imx8mm-c61-4gb
......@@ -347,7 +341,7 @@ lava-seco-c61-kselftest:
lava-zephyr-96b-nitrogen-twister:
needs: [zephyr-96b-nitrogen-twister]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: 96b-nitrogen
CI_BUILD_JOB_NAME: zephyr-96b-nitrogen-twister
......@@ -357,7 +351,7 @@ lava-zephyr-96b-nitrogen-twister:
lava-qemu-x86-perf:
needs: [linux-qemu-x86]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: qemux86
CI_BUILD_JOB_NAME: linux-qemu-x86
......@@ -367,7 +361,7 @@ lava-qemu-x86-perf:
lava-qemu-x86_64-perf:
needs: [linux-qemu-x86_64]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: qemux86-64
CI_BUILD_JOB_NAME: linux-qemu-x86_64
......@@ -377,7 +371,7 @@ lava-qemu-x86_64-perf:
lava-raspberrypi4-64-perf:
needs: [linux-raspberrypi4-64]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: raspberrypi4-64
CI_BUILD_JOB_NAME: linux-raspberrypi4-64
......@@ -387,7 +381,7 @@ lava-raspberrypi4-64-perf:
lava-seco-intel-b68-perf:
needs: [linux-seco-intel-b68]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: seco-intel-b68
CI_BUILD_JOB_NAME: linux-seco-intel-b68
......@@ -397,7 +391,7 @@ lava-seco-intel-b68-perf:
lava-seco-c61-perf:
needs: [linux-seco-imx8mm-c61-4gb]
stage: test
extends: .lava-test
extends: .lava-test-scheduled
variables:
MACHINE: seco-imx8mm-c61-4gb
CI_BUILD_JOB_NAME: linux-seco-imx8mm-c61-4gb
......@@ -425,28 +419,6 @@ lava-zephyr-qemu-x86:
CI_REPORT_JOB_NAME: lava-report
lava-report:
needs:
- lava-qemu-x86
- lava-qemu-x86_64
- lava-raspberrypi4-64
- lava-seco-intel-b68
- lava-seco-c61
- lava-qemu-x86-ltp
- lava-qemu-x86_64-ltp
- lava-raspberrypi4-64-ltp
- lava-seco-intel-b68-ltp
- lava-seco-c61-ltp
- lava-qemu-x86-perf
- lava-qemu-x86_64-perf
- lava-raspberrypi4-64-perf
- lava-seco-intel-b68-perf
- lava-seco-c61-perf
- lava-zephyr-96b-nitrogen-twister
- lava-zephyr-qemu-cortex-m3
- lava-zephyr-qemu-x86
- lava-qemu-x86_64-kselftest
- lava-raspberrypi4-64-kselftest
- lava-seco-c61-kselftest
extends: .lava-report
lava-badge:
......
......@@ -12,6 +12,7 @@
GIT_STRATEGY: none
  • Maintainer

    Needs more context in the commit description.

    pre-merge testing of what? And why the rename of lava-test to lava-test-scheduled?

  • Author Reporter

    Hi @idlethread Thanks for looking into this MR. I will update the commit msg.

    The task #486 (closed) is planned for this sprint, but the test scope for MR testing is not defined yet. I am starting with boot and smoke test on qemu devices.

    Jobs like ltp tests that extend lava-test-scheduled job only will be added to scheduled pipeline as they are time consuming. Jobs extend the default lava-test will be added to both MR and scheduled pipelines.

  • Author Reporter

    commit msg updated. Let me know if you need more info.

  • Please register or sign in to reply
CI_LAVA_INSTANCE: "https://lava.ostc-eu.org/"
CI_SQUAD_INSTANCE: "https://squadp.svc.ostc-eu.dev"
CI_SQUAD_PROJECT_NAME: "oniro-test-mr"
# Run the same ltp test suites that using by LKFT project.
# Reference: https://qa-reports.linaro.org/lkft/linux-stable-rc-linux-5.10.y/build/v5.10.98-75-g9f5cb871ceb9/testjobs/
LTP_TST_CMDFILES: "cap_bounds cpuhotplug crypto nptl pty securebits fs controllers hugetlb mm tracing containers io dio syscalls math commands ipc fcntl-locktests filecaps fs_bind fs_perms_simple fsx sched cve"
......@@ -71,8 +72,8 @@
# Submit the jobs to SQUAD.
- |
for job_def in $(find lava_jobs/ -name "*.yaml"); do
echo $CI_SQUAD_INSTANCE/api/submitjob/oniro-core/$CI_PROJECT_NAME/$CI_PIPELINE_ID/$MACHINE --header "Auth-Token: $CI_SQUAD_TOKEN" --form "backend=oniro_lava" --form "definition=@${job_def}"
curl $CI_SQUAD_INSTANCE/api/submitjob/oniro-core/$CI_PROJECT_NAME/$CI_PIPELINE_ID/$MACHINE --header "Auth-Token: $CI_SQUAD_TOKEN" --form "backend=oniro_lava" --form "definition=@${job_def}"
echo $CI_SQUAD_INSTANCE/api/submitjob/oniro-core/$CI_SQUAD_PROJECT_NAME/$CI_PIPELINE_ID/$MACHINE --header "Auth-Token: $CI_SQUAD_TOKEN" --form "backend=oniro_lava" --form "definition=@${job_def}"
curl $CI_SQUAD_INSTANCE/api/submitjob/oniro-core/$CI_SQUAD_PROJECT_NAME/$CI_PIPELINE_ID/$MACHINE --header "Auth-Token: $CI_SQUAD_TOKEN" --form "backend=oniro_lava" --form "definition=@${job_def}"
done
# Attach a callback to this build to trigger the lava-report job
curl -X POST $CI_SQUAD_INSTANCE/api/build/$CI_PIPELINE_ID/callbacks/ -F "callback_url=$CALLBACK_URL"
......@@ -80,6 +81,8 @@
paths:
- lava_jobs/*.yaml
rules:
- if: '$CI_SQUAD_TOKEN == null'
when: never
# Run the build when it is scheduled.
- if: $CI_PIPELINE_SOURCE == "schedule"
# Do not run pipelines for draft merge requests unless manually triggered.
......@@ -115,6 +118,8 @@
fi
rules:
- if: '$CI_SQUAD_TOKEN == null'
when: never
# Run the build when it is scheduled.
- if: $CI_PIPELINE_SOURCE == "schedule"
when: manual
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment