]> granicus.if.org Git - esp-idf/blob - .gitlab-ci.yml
Merge branch 'bugfix/fix_esp_pthread_h_compatible_with_cpp' into 'master'
[esp-idf] / .gitlab-ci.yml
1 stages:
2   - build
3   - assign_test
4   - host_test
5   - unit_test
6   - integration_test
7   - deploy
8
9 variables:
10 # System environment
11
12   # Common parameters for the 'make' during CI tests
13   MAKEFLAGS: "-j5 --no-keep-going"
14
15 # GitLab-CI environment
16
17   # more attempts for more robust
18   GET_SOURCES_ATTEMPTS: "10"
19   ARTIFACT_DOWNLOAD_ATTEMPTS: "10"
20
21   # We use get_sources.sh script to fetch the submodules and/or re-fetch the repo
22   # if it was corrupted (if submodule update fails this can happen)
23   GIT_STRATEGY: fetch
24   GIT_SUBMODULE_STRATEGY: none
25
26 # IDF environment
27
28   IDF_PATH: "$CI_PROJECT_DIR"
29   BATCH_BUILD: "1"
30   V: "0"
31   APPLY_BOT_FILTER_SCRIPT: "$CI_PROJECT_DIR/tools/ci/apply_bot_filter.py"
32   CHECKOUT_REF_SCRIPT: "$CI_PROJECT_DIR/tools/ci/checkout_project_ref.py"
33
34 # When 'fetch' strategy is used, Gitlab removes untracked files before checking out
35 # new revision. However if the new revision doesn't include some of the submodules
36 # which were present in the old revision, such submodule directories would not be
37 # removed by the checkout. This extra step ensures that these stale submodules
38 # are removed.
39 .git_clean_stale_submodules:  &git_clean_stale_submodules >
40   find . -name '.git' -not -path './.git' -printf '%P\n'
41   | sed 's|/.git||' 
42   | xargs -I {} sh -c '
43   grep -q {} .gitmodules 
44   ||  (echo "Removing {}, has .git directory but not in .gitmodules file" 
45   && rm -rf {});'
46
47 # before each job, we need to check if this job is filtered by bot stage/job filter
48 .apply_bot_filter: &apply_bot_filter
49   python $APPLY_BOT_FILTER_SCRIPT || exit 0
50
51 before_script:
52   - *git_clean_stale_submodules
53   # apply bot filter in before script
54   - *apply_bot_filter
55   # add gitlab ssh key
56   - mkdir -p ~/.ssh
57   - chmod 700 ~/.ssh
58   - echo -n $GITLAB_KEY > ~/.ssh/id_rsa_base64
59   - base64 --decode --ignore-garbage ~/.ssh/id_rsa_base64 > ~/.ssh/id_rsa
60   - chmod 600 ~/.ssh/id_rsa
61   - echo -e "Host gitlab.espressif.cn\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
62
63   # Set IS_PRIVATE or IS_PUBLIC depending on if our branch is public or not
64   #
65   # (the same regular expressions are used to set these are used in 'only:' sections below
66   - source tools/ci/configure_ci_environment.sh
67
68   # fetch the submodules (& if necessary re-fetch repo) from gitlab
69   - time ./tools/ci/get-full-sources.sh
70
71 .do_nothing_before:
72   before_script: &do_nothing_before
73     - *git_clean_stale_submodules
74     # apply bot filter in before script
75     - *apply_bot_filter
76     - echo "Not setting up GitLab key, not fetching submodules"
77     - source tools/ci/configure_ci_environment.sh
78
79 .add_gitlab_key_before:
80   before_script: &add_gitlab_key_before
81     - *git_clean_stale_submodules
82     # apply bot filter in before script
83     - *apply_bot_filter
84     - echo "Not fetching submodules"
85     - source tools/ci/configure_ci_environment.sh
86     # add gitlab ssh key
87     - mkdir -p ~/.ssh
88     - chmod 700 ~/.ssh
89     - echo -n $GITLAB_KEY > ~/.ssh/id_rsa_base64
90     - base64 --decode --ignore-garbage ~/.ssh/id_rsa_base64 > ~/.ssh/id_rsa
91     - chmod 600 ~/.ssh/id_rsa
92     - echo -e "Host gitlab.espressif.cn\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
93
94 build_template_app:
95   stage: build
96   image: $CI_DOCKER_REGISTRY/esp32-ci-env$BOT_DOCKER_IMAGE_TAG
97   tags:
98     - build
99   variables:
100     BATCH_BUILD: "1"
101     IDF_CI_BUILD: "1"
102   script:
103     - git clone https://github.com/espressif/esp-idf-template.git
104     - cd esp-idf-template
105     # Try to use the same branch name for esp-idf-template that we're
106     # using on esp-idf. If it doesn't exist then just stick to the default
107     # branch
108     - python $CHECKOUT_REF_SCRIPT esp-idf-template
109     # Test debug build (default)
110     - make all V=1
111     # Now test release build
112     - make clean
113     - sed -i.bak -e's/CONFIG_OPTIMIZATION_LEVEL_DEBUG\=y/CONFIG_OPTIMIZATION_LEVEL_RELEASE=y/' sdkconfig
114     - make all V=1
115     # Check if there are any stray printf/ets_printf references in WiFi libs
116     - cd ../components/esp32/lib
117     - test $(xtensa-esp32-elf-nm *.a | grep -w printf | wc -l) -eq 0
118     - test $(xtensa-esp32-elf-nm *.a | grep -w ets_printf | wc -l) -eq 0
119
120
121 .build_template: &build_template
122   stage: build
123   image: $CI_DOCKER_REGISTRY/esp32-ci-env$BOT_DOCKER_IMAGE_TAG
124   tags:
125     - build
126   variables:
127     BATCH_BUILD: "1"
128     V: "0"
129
130 .build_ssc_template: &build_ssc_template
131   <<: *build_template
132   artifacts:
133     paths:
134       - SSC/ssc_bin
135     expire_in: 1 mos
136   variables:
137     SSC_CONFIG_FOLDER: "$CI_PROJECT_DIR/SSC/configs/ESP32_IDF"
138   script:
139     - git clone $SSC_REPOSITORY
140     - cd SSC
141     - python $CHECKOUT_REF_SCRIPT SSC
142     - MAKEFLAGS= ./ci_build_ssc.sh "${CI_JOB_NAME}" "${IDF_PATH}/.gitlab-ci.yml"
143
144 # don't forget to add to dependency to test_template when adding new build_ssc jobs
145 build_ssc_00:
146   <<: *build_ssc_template
147
148 build_ssc_01:
149   <<: *build_ssc_template
150
151 build_ssc_02:
152   <<: *build_ssc_template
153
154 # If you want to add new build ssc jobs, please add it into dependencies of `assign_test` and `.test_template`
155
156 build_esp_idf_tests:
157   <<: *build_template
158   artifacts:
159     paths:
160       - tools/unit-test-app/output
161       - components/idf_test/unit_test/TestCaseAll.yml
162       - components/idf_test/unit_test/CIConfigs/*.yml
163     expire_in: 1 mos
164   script:
165     - cd tools/unit-test-app
166     - MAKEFLAGS= make help # make sure kconfig tools are built in single process
167     - make ut-clean-all-configs
168     - export EXTRA_CFLAGS="-Werror -Werror=deprecated-declarations"
169     - export EXTRA_CXXFLAGS=${EXTRA_CFLAGS}
170     - make ut-build-all-configs
171     - python tools/UnitTestParser.py
172
173 .build_examples_template: &build_examples_template
174   <<: *build_template
175   retry: 1
176   artifacts:
177     when: always
178     paths:
179       - build_examples/*/*/*/build/*.bin
180       - build_examples/*/*/*/build/*.elf
181       - build_examples/*/*/*/build/*.map
182       - build_examples/*/*/*/build/download.config
183       - build_examples/*/*/*/build/bootloader/*.bin
184       - $LOG_PATH
185     expire_in: 1 week
186   variables:
187     IDF_CI_BUILD: "1"
188     LOG_PATH: "$CI_PROJECT_DIR/log_examples"
189   script:
190     # it's not possible to build 100% out-of-tree and have the "artifacts"
191     # mechanism work, but this is the next best thing
192     - rm -rf build_examples
193     - mkdir build_examples
194     - cd build_examples
195     # build some of examples
196     - mkdir -p ${LOG_PATH}
197     - ${IDF_PATH}/tools/ci/build_examples.sh "${CI_JOB_NAME}"
198
199 build_examples_00:
200   <<: *build_examples_template
201
202 build_examples_01:
203   <<: *build_examples_template
204
205 build_examples_02:
206   <<: *build_examples_template
207
208 build_examples_03:
209   <<: *build_examples_template
210
211 build_examples_04:
212   <<: *build_examples_template
213
214 build_examples_05:
215   <<: *build_examples_template
216
217 build_examples_06:
218   <<: *build_examples_template
219
220 build_examples_07:
221   <<: *build_examples_template
222
223 # If you want to add new build example jobs, please add it into dependencies of `.example_test_template`
224
225 build_docs:
226   stage: build
227   image: $CI_DOCKER_REGISTRY/esp32-ci-env$BOT_DOCKER_IMAGE_TAG
228   tags:
229     - build_docs
230   artifacts:
231     when: always
232     paths:
233       # English version of documentation
234       - docs/en/doxygen-warning-log.txt
235       - docs/en/sphinx-warning-log.txt
236       - docs/en/sphinx-warning-log-sanitized.txt
237       - docs/en/_build/html
238       # Chinese version of documentation
239       - docs/zh_CN/doxygen-warning-log.txt
240       - docs/zh_CN/sphinx-warning-log.txt
241       - docs/zh_CN/sphinx-warning-log-sanitized.txt
242       - docs/zh_CN/_build/html
243     expire_in: 1 mos
244   script:
245     - cd docs
246     - ./check_lang_folder_sync.sh
247     - cd en
248     - make gh-linkcheck
249     - make html
250     - ../check_doc_warnings.sh
251     - cd ../zh_CN
252     - make gh-linkcheck
253     - make html
254     - ../check_doc_warnings.sh
255
256 .host_test_template: &host_test_template
257   stage: host_test
258   image: $CI_DOCKER_REGISTRY/esp32-ci-env$BOT_DOCKER_IMAGE_TAG
259   tags:
260     - host_test
261   dependencies: []
262     
263 test_nvs_on_host:
264   <<: *host_test_template
265   script:
266     - cd components/nvs_flash/test_nvs_host
267     - make test
268
269 test_nvs_coverage:
270   <<: *host_test_template
271   artifacts:
272     paths:
273       - components/nvs_flash/test_nvs_host/coverage_report
274   only:
275     - triggers
276   # This job takes a few hours to finish, so only run it on demand
277   variables:
278     BOT_NEEDS_TRIGGER_BY_NAME: 1
279   script:
280     - cd components/nvs_flash/test_nvs_host
281     - make coverage_report
282
283 test_partition_table_on_host:
284   <<: *host_test_template
285   tags:
286     - build
287   script:
288     - cd components/partition_table/test_gen_esp32part_host
289     - ./gen_esp32part_tests.py
290
291 test_wl_on_host:
292   <<: *host_test_template
293   artifacts:
294     paths:
295       - components/wear_levelling/test_wl_host/coverage_report.zip
296   script:
297     - cd components/wear_levelling/test_wl_host
298     - make test
299
300 test_fatfs_on_host:
301   <<: *host_test_template
302   tags:
303     - wl_host_test
304   script:
305     - cd components/fatfs/test_fatfs_host/
306     - make test
307
308 test_spiffs_on_host:
309   <<: *host_test_template
310   tags:
311     - wl_host_test
312   script:
313     - cd components/spiffs/test_spiffs_host/
314     - make test
315
316 test_multi_heap_on_host:
317   <<: *host_test_template
318   script:
319     - cd components/heap/test_multi_heap_host
320     - ./test_all_configs.sh
321
322 test_build_system:
323   <<: *host_test_template
324   script:
325     - ${IDF_PATH}/tools/ci/test_configure_ci_environment.sh
326     - rm -rf test_build_system
327     - mkdir test_build_system
328     - cd test_build_system
329     - ${IDF_PATH}/tools/ci/test_build_system.sh
330
331 test_idf_monitor:
332   <<: *host_test_template
333   artifacts:
334     when: on_failure
335     paths:
336       - tools/test_idf_monitor/outputs/*
337     expire_in: 1 week
338   script:
339     - cd ${IDF_PATH}/tools/test_idf_monitor
340     - ./run_test_idf_monitor.py
341
342 test_esp_err_to_name_on_host:
343   <<: *host_test_template
344   script:
345     - cd tools/
346     - ./gen_esp_err_to_name.py
347     - git diff --exit-code -- ../components/esp32/esp_err_to_name.c || (echo 'Differences found. Please run gen_esp_err_to_name.py and commit the changes.'; exit 1)
348
349 push_master_to_github:
350   stage: deploy
351   image: $CI_DOCKER_REGISTRY/esp32-ci-env$BOT_DOCKER_IMAGE_TAG
352   tags:
353     - deploy
354   only:
355     - master
356     - /^release\/v/
357     - /^v\d+\.\d+(\.\d+)?($|-)/
358   when: on_success
359   dependencies: []
360   variables:
361     GITHUB_PUSH_REFS: refs/remotes/origin/release refs/remotes/origin/master
362   before_script: *do_nothing_before
363   script:
364     - mkdir -p ~/.ssh
365     - chmod 700 ~/.ssh
366     - echo -n $GH_PUSH_KEY > ~/.ssh/id_rsa_base64
367     - base64 --decode --ignore-garbage ~/.ssh/id_rsa_base64 > ~/.ssh/id_rsa
368     - chmod 600 ~/.ssh/id_rsa
369     - echo -e "Host github.com\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
370     - git remote remove github &>/dev/null || true
371     - git remote add github git@github.com:espressif/esp-idf.git
372     # What the next line of script does: goes through the list of refs for all branches we push to github,
373     # generates a snippet of shell which is evaluated. The snippet checks CI_COMMIT_SHA against the SHA
374     # (aka objectname) at tip of each branch, and if any SHAs match then it checks out the local branch
375     # and then pushes that ref to a corresponding github branch
376     - eval $(git for-each-ref --shell bash --format 'if [ $CI_COMMIT_SHA == %(objectname) ]; then git checkout -B %(refname:strip=3); git push --follow-tags github %(refname:strip=3); fi;' $GITHUB_PUSH_REFS)
377
378
379 deploy_docs:
380   stage: host_test
381   image: $CI_DOCKER_REGISTRY/esp32-ci-env$BOT_DOCKER_IMAGE_TAG
382   tags:
383     - deploy
384   only:
385    - master
386    - /^release\/v/
387    - /^v\d+\.\d+(\.\d+)?($|-)/
388    - triggers
389   dependencies:
390     - build_docs
391   before_script: *do_nothing_before
392   script:
393     - mkdir -p ~/.ssh
394     - chmod 700 ~/.ssh
395     - echo -n $DOCS_DEPLOY_KEY > ~/.ssh/id_rsa_base64
396     - base64 --decode --ignore-garbage ~/.ssh/id_rsa_base64 > ~/.ssh/id_rsa
397     - chmod 600 ~/.ssh/id_rsa
398     - echo -e "Host $DOCS_SERVER\n\tStrictHostKeyChecking no\n\tUser $DOCS_SERVER_USER\n" >> ~/.ssh/config
399     - export GIT_VER=$(git describe --always)
400     - cd docs/en/_build/
401     - mv html $GIT_VER
402     - tar czvf $GIT_VER.tar.gz $GIT_VER
403     - scp $GIT_VER.tar.gz $DOCS_SERVER:$DOCS_PATH/en
404     - ssh $DOCS_SERVER -x "cd $DOCS_PATH/en && tar xzvf $GIT_VER.tar.gz && rm -f latest && ln -s $GIT_VER latest"
405     - cd ../../zh_CN/_build/
406     - mv html $GIT_VER
407     - tar czvf $GIT_VER.tar.gz $GIT_VER
408     - scp $GIT_VER.tar.gz $DOCS_SERVER:$DOCS_PATH/zh_CN
409     - ssh $DOCS_SERVER -x "cd $DOCS_PATH/zh_CN && tar xzvf $GIT_VER.tar.gz && rm -f latest && ln -s $GIT_VER latest"
410     # add link to preview doc
411     - echo "[document preview][en] $CI_DOCKER_REGISTRY/docs/esp-idf/en/${GIT_VER}/index.html"
412     - echo "[document preview][zh_CN] $CI_DOCKER_REGISTRY/docs/esp-idf/zh_CN/${GIT_VER}/index.html"
413
414 check_doc_links:
415   stage: host_test
416   image: $CI_DOCKER_REGISTRY/esp32-ci-env$BOT_DOCKER_IMAGE_TAG
417   tags:
418     - check_doc_links
419   only:
420     # can only be triggered
421     - triggers
422   artifacts:
423     paths:
424       - docs/_build/linkcheck
425     expire_in: 1 mos
426   script:
427     # must be triggered with CHECK_LINKS=Yes, otherwise exit without test
428     - test "$CHECK_LINKS" = "Yes" || exit 0
429     # can only run on master branch (otherwise the commit is not on Github yet)
430     - test "${CI_COMMIT_REF_NAME}" = "master" || exit 0
431     - cd docs
432     - make linkcheck
433
434 check_commit_msg:
435   stage: deploy
436   image: $CI_DOCKER_REGISTRY/esp32-ci-env$BOT_DOCKER_IMAGE_TAG
437   tags:
438     - build
439   except:
440     - master
441     - /^release\/v/
442     - /^v\d+\.\d+(\.\d+)?($|-)/
443   dependencies: []
444   before_script: *do_nothing_before
445   script:
446     - git status
447     - git log -n10 --oneline
448     # commit start with "WIP: " need to be squashed before merge
449     - 'git log --pretty=%s master.. -- | grep "^WIP: " && exit 1 || exit 0'
450
451 check_permissions:
452   stage: deploy
453   image: $CI_DOCKER_REGISTRY/esp32-ci-env$BOT_DOCKER_IMAGE_TAG
454   tags:
455     - build
456   except:
457     - master
458     - /^release\/v/
459     - /^v\d+\.\d+(\.\d+)?($|-)/
460   dependencies: []
461   before_script: *do_nothing_before
462   script:
463     - tools/ci/check-executable.sh
464
465 check_submodule_sync:
466   stage: deploy
467   image: $CI_DOCKER_REGISTRY/esp32-ci-env$BOT_DOCKER_IMAGE_TAG
468   tags:
469     - build
470   except:
471     - master
472     - /^release\/v/
473     - /^v\d+\.\d+(\.\d+)?($|-)/
474   dependencies: []
475   variables:
476     GIT_STRATEGY: clone
477   before_script: *do_nothing_before
478   script:
479     # check if all submodules are correctly synced to public repostory
480     - git submodule update --init --recursive
481
482 assign_test:
483   tags:
484     - assign_test
485   image: $CI_DOCKER_REGISTRY/ubuntu-test-env$BOT_DOCKER_IMAGE_TAG
486   stage: assign_test
487   # gitlab ci do not support match job with RegEx or wildcard now in dependencies.
488   # we have a lot build example jobs. now we don't use dependencies, just download all artificats of build stage.
489   dependencies:
490     - build_ssc_00
491     - build_ssc_01
492     - build_ssc_02
493     - build_esp_idf_tests
494   variables:
495     TEST_FW_PATH: "$CI_PROJECT_DIR/tools/tiny-test-fw"
496     EXAMPLE_CONFIG_OUTPUT_PATH: "$CI_PROJECT_DIR/examples/test_configs"
497   artifacts:
498     paths:
499       - components/idf_test/*/CIConfigs
500       - components/idf_test/*/TC.sqlite
501       - $EXAMPLE_CONFIG_OUTPUT_PATH
502     expire_in: 1 mos
503   before_script: *add_gitlab_key_before
504   script:
505     # assign example tests
506     - python $TEST_FW_PATH/CIAssignExampleTest.py $IDF_PATH/examples $IDF_PATH/.gitlab-ci.yml $EXAMPLE_CONFIG_OUTPUT_PATH
507     # assign unit test cases
508     - python $TEST_FW_PATH/CIAssignUnitTest.py $IDF_PATH/components/idf_test/unit_test/TestCaseAll.yml $IDF_PATH/.gitlab-ci.yml $IDF_PATH/components/idf_test/unit_test/CIConfigs
509     # clone test script to assign tests
510     - git clone $TEST_SCRIPT_REPOSITORY
511     - cd auto_test_script
512     - python $CHECKOUT_REF_SCRIPT auto_test_script
513     # assgin integration test cases
514     - python CIAssignTestCases.py -t $IDF_PATH/components/idf_test/integration_test -c $IDF_PATH/.gitlab-ci.yml -b $IDF_PATH/SSC/ssc_bin
515
516 .example_test_template: &example_test_template
517   stage: integration_test
518   when: on_success
519   only:
520     - master
521     - /^release\/v/
522     - /^v\d+\.\d+(\.\d+)?($|-)/
523     - triggers
524     - schedules
525   dependencies:
526     - assign_test
527     - build_examples_00
528     - build_examples_01
529     - build_examples_02
530     - build_examples_03
531     - build_examples_04
532     - build_examples_05
533     - build_examples_06
534     - build_examples_07
535   artifacts:
536     when: always
537     paths:
538       - $LOG_PATH
539     expire_in: 1 mos
540   variables:
541     TEST_FW_PATH: "$CI_PROJECT_DIR/tools/tiny-test-fw"
542     TEST_CASE_PATH: "$CI_PROJECT_DIR/examples"
543     CONFIG_FILE: "$CI_PROJECT_DIR/examples/test_configs/$CI_JOB_NAME.yml"
544     LOG_PATH: "$CI_PROJECT_DIR/TEST_LOGS"
545     ENV_FILE: "$CI_PROJECT_DIR/ci-test-runner-configs/$CI_RUNNER_DESCRIPTION/EnvConfig.yml"
546   script:
547     # first test if config file exists, if not exist, exit 0
548     - test -e $CONFIG_FILE || exit 0
549     # clone test env configs
550     - git clone $TEST_ENV_CONFIG_REPOSITORY
551     - cd ci-test-runner-configs
552     - python $CHECKOUT_REF_SCRIPT ci-test-runner-configs
553     - cd $TEST_FW_PATH
554     # run test
555     - python Runner.py $TEST_CASE_PATH -c $CONFIG_FILE -e $ENV_FILE
556
557 .unit_test_template: &unit_test_template
558   <<: *example_test_template
559   stage: unit_test
560   dependencies:
561     - assign_test
562     - build_esp_idf_tests
563   variables:
564     TEST_FW_PATH: "$CI_PROJECT_DIR/tools/tiny-test-fw"
565     TEST_CASE_PATH: "$CI_PROJECT_DIR/tools/unit-test-app"
566     CONFIG_FILE: "$CI_PROJECT_DIR/components/idf_test/unit_test/CIConfigs/$CI_JOB_NAME.yml"
567     LOG_PATH: "$CI_PROJECT_DIR/TEST_LOGS"
568     ENV_FILE: "$CI_PROJECT_DIR/ci-test-runner-configs/$CI_RUNNER_DESCRIPTION/EnvConfig.yml"
569
570 .test_template: &test_template
571   stage: integration_test
572   when: on_success
573   only:
574     - master
575     - /^release\/v/
576     - /^v\d+\.\d+(\.\d+)?($|-)/
577     - triggers
578     - schedules
579   dependencies:
580     - assign_test
581     - build_ssc_00
582     - build_ssc_01
583     - build_ssc_02
584   artifacts:
585     when: always
586     paths:
587       - $LOG_PATH
588     expire_in: 1 mos
589   variables:
590     LOCAL_ENV_CONFIG_PATH: "$CI_PROJECT_DIR/ci-test-runner-configs/$CI_RUNNER_DESCRIPTION/ESP32_IDF"
591     LOG_PATH: "$CI_PROJECT_DIR/$CI_COMMIT_SHA"
592     TEST_CASE_FILE_PATH: "$CI_PROJECT_DIR/components/idf_test/integration_test"
593     MODULE_UPDATE_FILE: "$CI_PROJECT_DIR/components/idf_test/ModuleDefinition.yml"
594     CONFIG_FILE: "$CI_PROJECT_DIR/components/idf_test/integration_test/CIConfigs/$CI_JOB_NAME.yml"
595   before_script: *add_gitlab_key_before
596   script:
597     # first test if config file exists, if not exist, exit 0
598     - test -e $CONFIG_FILE || exit 0
599     # clone local test env configs
600     - git clone $TEST_ENV_CONFIG_REPOSITORY
601     - cd ci-test-runner-configs
602     - python $CHECKOUT_REF_SCRIPT ci-test-runner-configs
603     # clone test bench
604     - git clone $TEST_SCRIPT_REPOSITORY
605     - cd auto_test_script
606     - python $CHECKOUT_REF_SCRIPT auto_test_script
607     # run test
608     - python CIRunner.py -l "$LOG_PATH/$CI_JOB_NAME" -c $CONFIG_FILE -e $LOCAL_ENV_CONFIG_PATH -t $TEST_CASE_FILE_PATH -m $MODULE_UPDATE_FILE
609
610 nvs_compatible_test:
611   <<: *test_template
612   artifacts:
613     when: always
614     paths:
615       - $LOG_PATH
616       - nvs_wifi.bin
617     expire_in: 1 mos
618   tags:
619     - ESP32_IDF
620     - NVS_Compatible
621   script:
622     # clone local test env configs
623     - git clone $TEST_ENV_CONFIG_REPOSITORY
624     - cd ci-test-runner-configs
625     - python $CHECKOUT_REF_SCRIPT ci-test-runner-configs
626     # clone test bench
627     - git clone $TEST_SCRIPT_REPOSITORY
628     - cd auto_test_script
629     - git checkout ${CI_COMMIT_REF_NAME} || echo "Using default branch..."
630     # prepare nvs bins
631     - ./Tools/prepare_nvs_bin.sh
632     # run test
633     - python CIRunner.py -l "$LOG_PATH/$CI_JOB_NAME" -c $CONFIG_FILE -e $LOCAL_ENV_CONFIG_PATH -t $TEST_CASE_FILE_PATH -m $MODULE_UPDATE_FILE
634
635 example_test_001_01:
636   <<: *example_test_template
637   tags:
638     - ESP32
639     - Example_WIFI
640
641 example_test_002_01:
642   <<: *example_test_template
643   tags:
644     - ESP32
645     - Example_ShieldBox
646
647 example_test_003_01:
648   <<: *example_test_template
649   tags:
650     - ESP32
651     - Example_SDIO
652
653 example_test_004_01:
654   <<: *example_test_template
655   tags:
656     - ESP32
657     - Example_CAN
658
659 UT_001_01:
660   <<: *unit_test_template
661   tags:
662     - ESP32_IDF
663     - UT_T1_1
664
665 UT_001_02:
666   <<: *unit_test_template
667   tags:
668     - ESP32_IDF
669     - UT_T1_1
670
671 UT_001_03:
672   <<: *unit_test_template
673   tags:
674     - ESP32_IDF
675     - UT_T1_1
676
677 UT_001_04:
678   <<: *unit_test_template
679   tags:
680     - ESP32_IDF
681     - UT_T1_1
682
683 UT_001_05:
684   <<: *unit_test_template
685   tags:
686     - ESP32_IDF
687     - UT_T1_1
688
689 UT_001_06:
690   <<: *unit_test_template
691   tags:
692     - ESP32_IDF
693     - UT_T1_1
694
695 UT_001_07:
696   <<: *unit_test_template
697   tags:
698     - ESP32_IDF
699     - UT_T1_1
700
701 UT_001_08:
702   <<: *unit_test_template
703   tags:
704     - ESP32_IDF
705     - UT_T1_1
706
707 UT_001_09:
708   <<: *unit_test_template
709   tags:
710     - ESP32_IDF
711     - UT_T1_1
712
713 UT_001_10:
714   <<: *unit_test_template
715   tags:
716     - ESP32_IDF
717     - UT_T1_1
718
719 UT_001_11:
720   <<: *unit_test_template
721   tags:
722     - ESP32_IDF
723     - UT_T1_1
724
725 UT_001_12:
726   <<: *unit_test_template
727   tags:
728     - ESP32_IDF
729     - UT_T1_1
730
731 UT_001_13:
732   <<: *unit_test_template
733   tags:
734     - ESP32_IDF
735     - UT_T1_1
736
737 UT_001_14:
738   <<: *unit_test_template
739   tags:
740     - ESP32_IDF
741     - UT_T1_1
742
743 UT_001_15:
744   <<: *unit_test_template
745   tags:
746     - ESP32_IDF
747     - UT_T1_1
748
749 UT_001_16:
750   <<: *unit_test_template
751   tags:
752     - ESP32_IDF
753     - UT_T1_1
754
755 UT_001_17:
756   <<: *unit_test_template
757   tags:
758     - ESP32_IDF
759     - UT_T1_1
760
761 UT_001_18:
762   <<: *unit_test_template
763   tags:
764     - ESP32_IDF
765     - UT_T1_1
766
767 UT_001_19:
768   <<: *unit_test_template
769   tags:
770     - ESP32_IDF
771     - UT_T1_1
772
773 UT_001_20:
774   <<: *unit_test_template
775   tags:
776     - ESP32_IDF
777     - UT_T1_1
778
779 UT_001_21:
780   <<: *unit_test_template
781   tags:
782     - ESP32_IDF
783     - UT_T1_1
784
785 UT_001_22:
786   <<: *unit_test_template
787   tags:
788     - ESP32_IDF
789     - UT_T1_1
790
791 UT_001_23:
792   <<: *unit_test_template
793   tags:
794     - ESP32_IDF
795     - UT_T1_1
796
797 UT_001_24:
798   <<: *unit_test_template
799   tags:
800     - ESP32_IDF
801     - UT_T1_1
802
803 UT_001_25:
804   <<: *unit_test_template
805   tags:
806     - ESP32_IDF
807     - UT_T1_1
808     
809 UT_001_26:
810   <<: *unit_test_template
811   tags:
812     - ESP32_IDF
813     - UT_T1_1
814
815 UT_001_27:
816   <<: *unit_test_template
817   tags:
818     - ESP32_IDF
819     - UT_T1_1
820
821 UT_001_28:
822   <<: *unit_test_template
823   tags:
824     - ESP32_IDF
825     - UT_T1_1
826
827 UT_001_29:
828   <<: *unit_test_template
829   tags:
830     - ESP32_IDF
831     - UT_T1_1
832
833 UT_001_30:
834   <<: *unit_test_template
835   tags:
836     - ESP32_IDF
837     - UT_T1_1
838
839 UT_001_31:
840   <<: *unit_test_template
841   tags:
842     - ESP32_IDF
843     - UT_T1_1
844     
845 UT_001_32:
846   <<: *unit_test_template
847   tags:
848     - ESP32_IDF
849     - UT_T1_1
850
851 UT_001_33:
852   <<: *unit_test_template
853   tags:
854     - ESP32_IDF
855     - UT_T1_1
856     
857 UT_001_34:
858   <<: *unit_test_template
859   tags:
860     - ESP32_IDF
861     - UT_T1_1
862
863 UT_002_01:
864   <<: *unit_test_template
865   tags:
866     - ESP32_IDF
867     - UT_T1_SDMODE
868
869 UT_002_02:
870   <<: *unit_test_template
871   tags:
872     - ESP32_IDF
873     - UT_T1_SDMODE
874
875 UT_002_03:
876   <<: *unit_test_template
877   tags:
878     - ESP32_IDF
879     - UT_T1_SDMODE
880
881 UT_003_01:
882   <<: *unit_test_template
883   tags:
884     - ESP32_IDF
885     - UT_T1_SPIMODE
886
887 UT_003_02:
888   <<: *unit_test_template
889   tags:
890     - ESP32_IDF
891     - UT_T1_SPIMODE
892
893 UT_003_03:
894   <<: *unit_test_template
895   tags:
896     - ESP32_IDF
897     - UT_T1_SPIMODE
898
899 UT_004_01:
900   <<: *unit_test_template
901   tags:
902     - ESP32_IDF
903     - UT_T1_1
904     - psram
905
906 UT_004_02:
907   <<: *unit_test_template
908   tags:
909     - ESP32_IDF
910     - UT_T1_1
911     - psram
912
913 UT_004_03:
914   <<: *unit_test_template
915   tags:
916     - ESP32_IDF
917     - UT_T1_1
918     - psram
919
920 UT_004_04:
921   <<: *unit_test_template
922   tags:
923     - ESP32_IDF
924     - UT_T1_1
925     - psram
926
927 UT_004_05:
928   <<: *unit_test_template
929   tags:
930     - ESP32_IDF
931     - UT_T1_1
932     - psram
933
934 UT_004_06:
935   <<: *unit_test_template
936   tags:
937     - ESP32_IDF
938     - UT_T1_1
939     - psram
940
941 UT_004_07:
942   <<: *unit_test_template
943   tags:
944     - ESP32_IDF
945     - UT_T1_1
946     - psram
947
948 UT_004_08:
949   <<: *unit_test_template
950   tags:
951     - ESP32_IDF
952     - UT_T1_1
953     - psram
954
955 UT_004_09:
956   <<: *unit_test_template
957   tags:
958     - ESP32_IDF
959     - UT_T1_1
960     - psram
961
962 UT_004_10:
963   <<: *unit_test_template
964   tags:
965     - ESP32_IDF
966     - UT_T1_1
967     - psram
968     
969 UT_004_11:
970   <<: *unit_test_template
971   tags:
972     - ESP32_IDF
973     - UT_T1_1
974     - psram
975     
976 UT_005_01:
977   <<: *unit_test_template
978   tags:
979     - ESP32_IDF
980     - UT_T1_SDMODE
981     - psram
982
983 UT_005_02:
984   <<: *unit_test_template
985   tags:
986     - ESP32_IDF
987     - UT_T1_SPIMODE
988     - psram
989
990 UT_006_01:
991   <<: *unit_test_template
992   tags:
993     - ESP32_IDF
994     - UT_T1_GPIO
995
996 UT_006_02:
997   <<: *unit_test_template
998   tags:
999     - ESP32_IDF
1000     - UT_T1_GPIO
1001
1002 UT_006_03:
1003   <<: *unit_test_template
1004   tags:
1005     - ESP32_IDF
1006     - UT_T1_GPIO
1007
1008 UT_006_04:
1009   <<: *unit_test_template
1010   tags:
1011     - ESP32_IDF
1012     - UT_T1_GPIO
1013     - psram
1014
1015 UT_007_01:
1016   <<: *unit_test_template
1017   tags:
1018     - ESP32_IDF
1019     - UT_T1_PCNT
1020
1021 UT_007_02:
1022   <<: *unit_test_template
1023   tags:
1024     - ESP32_IDF
1025     - UT_T1_PCNT
1026
1027 UT_007_03:
1028   <<: *unit_test_template
1029   tags:
1030     - ESP32_IDF
1031     - UT_T1_PCNT
1032
1033 UT_007_04:
1034   <<: *unit_test_template
1035   tags:
1036     - ESP32_IDF
1037     - UT_T1_PCNT
1038     - psram
1039
1040 UT_008_01:
1041   <<: *unit_test_template
1042   tags:
1043     - ESP32_IDF
1044     - UT_T1_LEDC
1045
1046 UT_008_02:
1047   <<: *unit_test_template
1048   tags:
1049     - ESP32_IDF
1050     - UT_T1_LEDC
1051
1052 UT_008_03:
1053   <<: *unit_test_template
1054   tags:
1055     - ESP32_IDF
1056     - UT_T1_LEDC
1057
1058 UT_008_04:
1059   <<: *unit_test_template
1060   tags:
1061     - ESP32_IDF
1062     - UT_T1_LEDC
1063     - psram
1064
1065 UT_010_01:
1066   <<: *unit_test_template
1067   tags:
1068     - ESP32_IDF
1069     - UT_T1_RMT
1070
1071 UT_010_02:
1072   <<: *unit_test_template
1073   tags:
1074     - ESP32_IDF
1075     - UT_T1_RMT
1076
1077 UT_010_03:
1078   <<: *unit_test_template
1079   tags:
1080     - ESP32_IDF
1081     - UT_T1_RMT
1082
1083 UT_010_04:
1084   <<: *unit_test_template
1085   tags:
1086     - ESP32_IDF
1087     - UT_T1_RMT
1088     - psram
1089
1090 IT_001_01:
1091   <<: *test_template
1092   tags:
1093     - ESP32_IDF
1094     - SSC_T1_1
1095
1096 IT_001_02:
1097   <<: *test_template
1098   tags:
1099     - ESP32_IDF
1100     - SSC_T1_1
1101
1102 IT_001_03:
1103   <<: *test_template
1104   tags:
1105     - ESP32_IDF
1106     - SSC_T1_1
1107
1108 IT_001_04:
1109   <<: *test_template
1110   tags:
1111     - ESP32_IDF
1112     - SSC_T1_1
1113
1114 IT_001_05:
1115   <<: *test_template
1116   tags:
1117     - ESP32_IDF
1118     - SSC_T1_1
1119
1120 IT_001_06:
1121   <<: *test_template
1122   tags:
1123     - ESP32_IDF
1124     - SSC_T1_1
1125
1126 IT_001_07:
1127   <<: *test_template
1128   tags:
1129     - ESP32_IDF
1130     - SSC_T1_1
1131
1132 IT_001_08:
1133   <<: *test_template
1134   tags:
1135     - ESP32_IDF
1136     - SSC_T1_1
1137
1138 IT_001_09:
1139   <<: *test_template
1140   tags:
1141     - ESP32_IDF
1142     - SSC_T1_1
1143
1144 IT_002_01:
1145   <<: *test_template
1146   tags:
1147     - ESP32_IDF
1148     - SSC_T1_2
1149
1150 IT_003_01:
1151   <<: *test_template
1152   tags:
1153     - ESP32_IDF
1154     - SSC_T2_1
1155
1156 IT_003_02:
1157   <<: *test_template
1158   tags:
1159     - ESP32_IDF
1160     - SSC_T2_1
1161
1162 IT_003_03:
1163   <<: *test_template
1164   tags:
1165     - ESP32_IDF
1166     - SSC_T2_1
1167
1168 IT_003_04:
1169   <<: *test_template
1170   tags:
1171     - ESP32_IDF
1172     - SSC_T2_1
1173
1174 IT_003_05:
1175   <<: *test_template
1176   tags:
1177     - ESP32_IDF
1178     - SSC_T2_1
1179
1180 IT_003_06:
1181   <<: *test_template
1182   tags:
1183     - ESP32_IDF
1184     - SSC_T2_1
1185
1186 IT_003_07:
1187   <<: *test_template
1188   tags:
1189     - ESP32_IDF
1190     - SSC_T2_1
1191
1192 IT_003_08:
1193   <<: *test_template
1194   tags:
1195     - ESP32_IDF
1196     - SSC_T2_1
1197
1198 IT_003_09:
1199   <<: *test_template
1200   tags:
1201     - ESP32_IDF
1202     - SSC_T2_1
1203
1204 IT_003_10:
1205   <<: *test_template
1206   tags:
1207     - ESP32_IDF
1208     - SSC_T2_1
1209
1210 IT_003_11:
1211   <<: *test_template
1212   tags:
1213     - ESP32_IDF
1214     - SSC_T2_1
1215
1216 IT_003_12:
1217   <<: *test_template
1218   tags:
1219     - ESP32_IDF
1220     - SSC_T2_1
1221
1222 IT_003_13:
1223   <<: *test_template
1224   tags:
1225     - ESP32_IDF
1226     - SSC_T2_1
1227
1228 IT_003_14:
1229   <<: *test_template
1230   tags:
1231     - ESP32_IDF
1232     - SSC_T2_1
1233
1234 IT_004_01:
1235   <<: *test_template
1236   tags:
1237     - ESP32_IDF
1238     - SSC_T1_APC
1239
1240 IT_005_01:
1241   <<: *test_template
1242   tags:
1243     - ESP32_IDF
1244     - SSC_T1_WEP
1245
1246 IT_009_01:
1247   <<: *test_template
1248   tags:
1249     - ESP32_IDF
1250     - SSC_T1_3
1251
1252 IT_010_01:
1253   <<: *test_template
1254   tags:
1255     - ESP32_IDF
1256     - SSC_T5_1
1257
1258 IT_011_01:
1259   <<: *test_template
1260   tags:
1261     - ESP32_IDF
1262     - SSC_T50_1
1263
1264 IT_501_01:
1265   <<: *test_template
1266   tags:
1267     - ESP32_IDF
1268     - SSC_T1_1
1269     - stress_test
1270
1271 IT_501_02:
1272   <<: *test_template
1273   tags:
1274     - ESP32_IDF
1275     - SSC_T1_1
1276     - stress_test
1277
1278 IT_501_03:
1279   <<: *test_template
1280   tags:
1281     - ESP32_IDF
1282     - SSC_T1_1
1283     - stress_test
1284
1285 IT_502_01:
1286   <<: *test_template
1287   tags:
1288     - ESP32_IDF
1289     - SSC_T2_1
1290     - stress_test
1291
1292 IT_502_02:
1293   <<: *test_template
1294   tags:
1295     - ESP32_IDF
1296     - SSC_T2_1
1297     - stress_test
1298
1299 IT_503_01:
1300   <<: *test_template
1301   tags:
1302     - ESP32_IDF
1303     - SSC_T5_1
1304     - stress_test
1305
1306 IT_503_02:
1307   <<: *test_template
1308   tags:
1309     - ESP32_IDF
1310     - SSC_T5_1
1311     - stress_test
1312
1313 IT_503_03:
1314   <<: *test_template
1315   tags:
1316     - ESP32_IDF
1317     - SSC_T5_1
1318     - stress_test