From c82adde67da90acf61e12162c7d3017f183fb211 Mon Sep 17 00:00:00 2001 From: Fu Hanxi Date: Wed, 27 Apr 2022 13:58:50 +0800 Subject: [PATCH] ci: fix missing esptool for integration tests --- .gitlab-ci.yml | 17 ++++++++++++++++- .gitlab/ci/target-test.yml | 6 +----- 2 files changed, 17 insertions(+), 6 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 79e96d5b71..2d1c692cda 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -112,7 +112,7 @@ cache: .download_test_python_contraint_file: &download_test_python_contraint_file | if [[ -n "$CI_PYTHON_CONSTRAINT_BRANCH" ]]; then - wget -O /tmp/constraint.txt --header="Authorization:Bearer ${ESPCI_TOKEN}" https://gitlab.espressif.cn:6688/api/v4/projects/2581/repository/files/${CI_PYTHON_CONSTRAINT_FILE}/raw?ref=${CI_PYTHON_CONSTRAINT_BRANCH} + wget -O /tmp/constraint.txt --header="Authorization:Bearer ${ESPCI_TOKEN}" ${GITLAB_HTTP_SERVER}/api/v4/projects/2581/repository/files/${CI_PYTHON_CONSTRAINT_FILE}/raw?ref=${CI_PYTHON_CONSTRAINT_BRANCH} mkdir -p ~/.espressif mv /tmp/constraint.txt ~/.espressif/${CI_PYTHON_CONSTRAINT_FILE} fi @@ -147,6 +147,21 @@ before_script: - source tools/ci/utils.sh - is_based_on_commits $REQUIRED_ANCESTOR_COMMITS +.before_script_integration_test: + before_script: + # need to install esptool, needn't install idf python env + - source tools/ci/utils.sh + - is_based_on_commits $REQUIRED_ANCESTOR_COMMITS + - source tools/ci/setup_python.sh + - add_gitlab_ssh_keys + - fetch_submodules + # download the constraint file manually + - mkdir -p ~/.espressif + - wget -O ~/.espressif/${CI_PYTHON_CONSTRAINT_FILE} --header="Authorization:Bearer ${ESPCI_TOKEN}" ${GITLAB_HTTP_SERVER}/api/v4/projects/2581/repository/files/${CI_PYTHON_CONSTRAINT_FILE}/raw + - *download_test_python_contraint_file + # TODO: remove this, IDFCI-1207 + - pip install esptool -c ~/.espressif/${CI_PYTHON_CONSTRAINT_FILE} + .before_script_macos: before_script: - source tools/ci/utils.sh diff --git a/.gitlab/ci/target-test.yml b/.gitlab/ci/target-test.yml index 1fd1e58061..0b3a63fdf4 100644 --- a/.gitlab/ci/target-test.yml +++ b/.gitlab/ci/target-test.yml @@ -915,7 +915,7 @@ UT_S3_FLASH: - .target_test_job_template - .rules:test:integration_test # needn't install idf python env - - .before_script_minimal + - .before_script_integration_test needs: # the assign already needs all the build jobs - assign_integration_test variables: @@ -934,10 +934,6 @@ UT_S3_FLASH: - *define_config_file_name # first test if config file exists, if not exist, exit 0 - test -e $CONFIG_FILE || exit 0 - # prepare test utilities - - source tools/ci/setup_python.sh - - add_gitlab_ssh_keys - - fetch_submodules # clone local test env configs - retry_failed git clone $TEST_ENV_CONFIG_REPO - python $CHECKOUT_REF_SCRIPT ci-test-runner-configs ci-test-runner-configs