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

ci: add oe-selftest gcc test job


Signed-off-by: default avatarChase Qi <chase.qi@linaro.org>
parent 34200c6a
No related branches found
No related tags found
No related merge requests found
This commit is part of merge request !139. Comments created here will be created in the context of that merge request.
...@@ -550,3 +550,28 @@ build-npm-cspell: ...@@ -550,3 +550,28 @@ build-npm-cspell:
extends: .build-with-kaniko extends: .build-with-kaniko
variables: variables:
CONTAINER_PATH: npm-cspell CONTAINER_PATH: npm-cspell
.oe-selftest:
rules:
- if: '$CI_PIPELINE_SOURCE == "schedule"'
variables:
CI_ONIRO_MANIFEST_URL: "$CI_PROJECT_URL"
CI_ONIRO_MANIFEST_BRANCH: "$CI_COMMIT_REF_NAME"
- if: '$CI_PIPELINE_SOURCE == "merge_request_event" && $CI_MERGE_REQUEST_TITLE =~ /^(wip|draft):.*/i'
when: manual
variables:
CI_ONIRO_MANIFEST_URL: "$CI_MERGE_REQUEST_SOURCE_PROJECT_URL"
CI_ONIRO_MANIFEST_BRANCH: "$CI_COMMIT_REF_NAME"
- if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
# TODO(Chase): only trigger the test when manifests changed.
# changes:
# - manifests/*.xml
variables:
CI_ONIRO_MANIFEST_URL: "$CI_MERGE_REQUEST_SOURCE_PROJECT_URL"
CI_ONIRO_MANIFEST_BRANCH: "$CI_COMMIT_REF_NAME"
oe-selftest-gcc:
extends: .oe-selftest
timeout: 10h
variables:
CI_ONIRO_OE_SEFLTESTS: gcc
...@@ -451,3 +451,27 @@ ...@@ -451,3 +451,27 @@
# Run this job in case the pipeline changes. # Run this job in case the pipeline changes.
- .oniro-ci/*.yml - .oniro-ci/*.yml
- .gitlab-ci.yml - .gitlab-ci.yml
# This job is documented in docs/ci/hidden-jobs/oe-selftest.rst
.oe-selftest:
image:
# TODO(Chase): move to registry.ostc-eu.org/ostc/oniro/oe-selftest:latest
# once it is available.
name: chaseqi/bitbake-builder:v1.3
tags: [qemu-friendly, large-disk, $CI_ONIRO_RUNNER_TAG, $CI_ONIRO_INSTANCE_SIZE]
stage: test
extends: .bitbake-workspace
variables:
MACHINE: qemux86-64
CI_ONIRO_BUILD_FLAVOUR: linux
CI_ONIRO_BB_LOCAL_CONF_SANITY_TESTED_DISTROS: ""
CI_ONIRO_OE_SEFLTESTS: ""
CI_ONIRO_OE_SEFLTEST_SKIPS: ""
script:
- test -n "$CI_ONIRO_OE_SEFLTESTS" || (
echo "nothing to test - CI_ONIRO_OE_SEFLTESTS is empty"
&& exit 1 )
- !reference [.bitbake-workspace, script]
# The USER variable is required by oe-selftest but missing in env.
- export USER=builder
- time oe-selftest -vvv -r $CI_ONIRO_OE_SEFLTESTS
...@@ -30,3 +30,4 @@ implementation details. ...@@ -30,3 +30,4 @@ implementation details.
lava-report lava-report
aggregate-docs aggregate-docs
publish-rauc-bundle-to-hawkbit publish-rauc-bundle-to-hawkbit
oe-selftest
.. SPDX-FileCopyrightText: Huawei Inc.
..
.. SPDX-License-Identifier: CC-BY-4.0
============
.oe-selftest
============
The ``.oe-selftest`` job extends the :doc:`bitbake-workspace` job to configure
OpenEmbedded Self test environment. The job does not run any tests by itself,
actual tests should be run in the downstream test jobs.
Job Variables
=============
Oe-selftest is based on Python unitest. Tests are orgnazied by module, class
and method. The ``.oe-selftest`` job defines two variables as a way to
customize what tests to run.
CI_ONIRO_OE_SEFLTESTS
---------------------
The specific tests to run. The default value is empty. The order the tests are
running is alphabetical.
CI_ONIRO_OE_SEFLTEST_SKIPS
--------------------------
The specific tests to skip. The default value is empty.
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