From d275e2f824b322bae18b50f6aae38795b1f267c7 Mon Sep 17 00:00:00 2001 From: Kaituo Li Date: Tue, 30 Apr 2024 11:26:38 -0700 Subject: [PATCH] Remove unnecessary sleep between test runs The introduction of `sleep` between test runs in `dashboard_spec.js` and `detector_list_spec.js` was initially implemented to handle timing issues. However, these tests were actually failing due to a recent URL change, as detailed in https://github.com/opensearch-project/opensearch-dashboards-functional-test/pull/1257. With the root cause of the failures addressed, the delays introduced by `sleep` commands are now redundant and can potentially slow down the testing process without providing any benefit. This PR removes these unnecessary sleep intervals between test executions. **Testing Done:** - Confirmed that all remote Cypress tests pass without the sleep intervals. Signed-off-by: Kaituo Li --- .../workflows/remote-integ-tests-workflow.yml | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) diff --git a/.github/workflows/remote-integ-tests-workflow.yml b/.github/workflows/remote-integ-tests-workflow.yml index 129bafda..c0ee017b 100644 --- a/.github/workflows/remote-integ-tests-workflow.yml +++ b/.github/workflows/remote-integ-tests-workflow.yml @@ -142,21 +142,16 @@ jobs: - name: Finding spec files and store to output id: finding-files run: | - echo "::set-output name=FILELIST::$(find cypress/integration/plugins/anomaly-detection-dashboards-plugin -name '*.js' -print)" - working-directory: opensearch-dashboards-functional-test - - - name: Print spec files from output - run: | - IFS="," read -a myarray <<< ${{ steps.finding-files.outputs.FILELIST }} - for i in "${myarray[@]}"; do - echo "${i}" - done + { + echo 'FILELIST<> "$GITHUB_ENV" working-directory: opensearch-dashboards-functional-test - name: Run spec files from output run: | - IFS="," read -a myarray <<< ${{ steps.finding-files.outputs.FILELIST }} - for i in "${myarray[@]}"; do + for i in $FILELIST; do yarn cypress:run-without-security --browser electron --spec "${i}" sleep 60 done