mirror of
https://github.com/espressif/esp-idf.git
synced 2026-10-02 03:00:34 +03:00
ci: move integration-test to ci/actions
This commit is contained in:
+3
-1
@@ -18,6 +18,9 @@ workflow:
|
|||||||
# Place the default settings in `.gitlab/ci/common.yml` instead
|
# Place the default settings in `.gitlab/ci/common.yml` instead
|
||||||
|
|
||||||
include:
|
include:
|
||||||
|
- project: "ci/actions/common"
|
||||||
|
file:
|
||||||
|
- "templates/idf/integration-test.yml"
|
||||||
- '.gitlab/ci/danger.yml'
|
- '.gitlab/ci/danger.yml'
|
||||||
- '.gitlab/ci/common.yml'
|
- '.gitlab/ci/common.yml'
|
||||||
- '.gitlab/ci/rules.yml'
|
- '.gitlab/ci/rules.yml'
|
||||||
@@ -28,7 +31,6 @@ include:
|
|||||||
- '.gitlab/ci/pre_commit.yml'
|
- '.gitlab/ci/pre_commit.yml'
|
||||||
- '.gitlab/ci/pre_check.yml'
|
- '.gitlab/ci/pre_check.yml'
|
||||||
- '.gitlab/ci/build.yml'
|
- '.gitlab/ci/build.yml'
|
||||||
- '.gitlab/ci/integration_test.yml'
|
|
||||||
- '.gitlab/ci/host-test.yml'
|
- '.gitlab/ci/host-test.yml'
|
||||||
- '.gitlab/ci/deploy.yml'
|
- '.gitlab/ci/deploy.yml'
|
||||||
- '.gitlab/ci/test-win.yml'
|
- '.gitlab/ci/test-win.yml'
|
||||||
|
|||||||
@@ -1,71 +0,0 @@
|
|||||||
# generate dynamic integration pipeline by `idf-integration-ci` project
|
|
||||||
|
|
||||||
.patterns-integration_test: &patterns-integration_test
|
|
||||||
# add all possible patterns to make sure `gen_integration_pipeline` can be triggered.
|
|
||||||
# fine-grained control will be done while generating the pipeline
|
|
||||||
# find `patterns` in `idf-integration-ci` project
|
|
||||||
- "components/**/*"
|
|
||||||
- "tools/**/*"
|
|
||||||
- ".gitlab-ci.yml"
|
|
||||||
- ".gitlab/ci/common.yml"
|
|
||||||
- ".gitlab/ci/integration_test.yml"
|
|
||||||
- ".gitmodules"
|
|
||||||
- "CMakeLists.txt"
|
|
||||||
- "install.sh"
|
|
||||||
- "export.sh"
|
|
||||||
- "Kconfig"
|
|
||||||
- "sdkconfig.rename"
|
|
||||||
|
|
||||||
# Simplify the rules
|
|
||||||
.integration_test_rules:
|
|
||||||
rules:
|
|
||||||
- if: '$CI_PIPELINE_SOURCE != "merge_request_event"'
|
|
||||||
- if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
|
|
||||||
changes: *patterns-integration_test
|
|
||||||
# support trigger by ci labels
|
|
||||||
- if: '$CI_MERGE_REQUEST_LABELS =~ /^(?:[^,\n\r]+,)*target_test(?:,[^,\n\r]+)*$/i'
|
|
||||||
- if: '$CI_MERGE_REQUEST_LABELS =~ /^(?:[^,\n\r]+,)*integration_test(?:,[^,\n\r]+)*$/i'
|
|
||||||
- if: '$CI_MERGE_REQUEST_LABELS =~ /^(?:[^,\n\r]+,)*build(?:,[^,\n\r]+)*$/i'
|
|
||||||
|
|
||||||
gen_integration_pipeline:
|
|
||||||
extends:
|
|
||||||
- .before_script:minimal
|
|
||||||
- .integration_test_rules
|
|
||||||
image: ${CI_INTEGRATION_ASSIGN_ENV}
|
|
||||||
stage: assign_test
|
|
||||||
cache: []
|
|
||||||
tags: [fast_run, shiny]
|
|
||||||
variables:
|
|
||||||
SUBMODULES_TO_FETCH: "none"
|
|
||||||
GIT_LFS_SKIP_SMUDGE: 1
|
|
||||||
needs:
|
|
||||||
- job: manual_gate
|
|
||||||
optional: true
|
|
||||||
- job: fast_template_app
|
|
||||||
artifacts: false
|
|
||||||
optional: true
|
|
||||||
artifacts:
|
|
||||||
paths:
|
|
||||||
- idf-integration-ci/child_pipeline/
|
|
||||||
expire_in: 2 weeks
|
|
||||||
when: always
|
|
||||||
script:
|
|
||||||
- add_gitlab_ssh_keys
|
|
||||||
- retry_failed git clone ${CI_GEN_INTEGRATION_PIPELINE_REPO} idf-integration-ci
|
|
||||||
- python $CHECKOUT_REF_SCRIPT idf-integration-ci idf-integration-ci
|
|
||||||
- cd idf-integration-ci
|
|
||||||
- python tools/generate_child_pipeline.py -o child_pipeline/
|
|
||||||
|
|
||||||
child_integration_test_pipeline:
|
|
||||||
extends:
|
|
||||||
- .integration_test_rules
|
|
||||||
stage: assign_test
|
|
||||||
needs:
|
|
||||||
- gen_integration_pipeline
|
|
||||||
trigger:
|
|
||||||
include:
|
|
||||||
- artifact: idf-integration-ci/child_pipeline/pipeline.yml
|
|
||||||
job: gen_integration_pipeline
|
|
||||||
forward:
|
|
||||||
yaml_variables: false
|
|
||||||
strategy: depend
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
# SPDX-FileCopyrightText: 2020-2024 Espressif Systems (Shanghai) CO LTD
|
# SPDX-FileCopyrightText: 2020-2026 Espressif Systems (Shanghai) CO LTD
|
||||||
# SPDX-License-Identifier: Apache-2.0
|
# SPDX-License-Identifier: Apache-2.0
|
||||||
# internal use only for CI
|
# internal use only for CI
|
||||||
# some CI related util functions
|
# some CI related util functions
|
||||||
@@ -128,6 +128,13 @@ class GitlabYmlConfig:
|
|||||||
|
|
||||||
# expanding "include"
|
# expanding "include"
|
||||||
for item in root_yml.pop('include', []) or []:
|
for item in root_yml.pop('include', []) or []:
|
||||||
|
if isinstance(item, dict):
|
||||||
|
if 'project' in item:
|
||||||
|
continue
|
||||||
|
elif 'local' in item:
|
||||||
|
item = item['local']
|
||||||
|
else:
|
||||||
|
continue
|
||||||
all_config.update(yaml.load(open(os.path.join(IDF_PATH, item)), Loader=yaml.FullLoader))
|
all_config.update(yaml.load(open(os.path.join(IDF_PATH, item)), Loader=yaml.FullLoader))
|
||||||
|
|
||||||
if 'default' in all_config:
|
if 'default' in all_config:
|
||||||
|
|||||||
Reference in New Issue
Block a user