@@ -150,41 +150,39 @@ jobs:
150150 docker exec $DNAME /bin/bash -c "cd /dspace/bin && ./dspace healthcheck -v"
151151
152152 playwright-after-deploy8 :
153- runs-on : ubuntu-latest
153+ runs-on : dspace-test-1
154154 needs : deploy-8
155155 timeout-minutes : 45
156156 if : ' !inputs.IMPORT'
157157 steps :
158- - name : run playwright
159- run : |
160- # wait until FE stabilizes a bit
161- sleep 3m
162-
163- curl -H "Accept: application/vnd.github.everest-preview+json" \
164- -H "Authorization: token ${{ secrets.DEPLOY_DEV5_GH_ACTION_DISPATCH }}" \
165- --request POST \
166- https://api.github.com/repos/dataquest-dev/\
167- dspace-ui-tests/actions/workflows/cron-test.yml/dispatches \
168- --data "{\"ref\":\"refs/heads/master\"}" 2> /dev/null
158+ - name : Checkout Playwright tests
159+ uses : actions/checkout@v4
160+ with :
161+ repository : dataquest-dev/dspace-ui-tests
162+ path : dspace-ui-tests
163+ token : ${{ secrets.DEPLOY_DEV5_GH_ACTION_DISPATCH }}
169164
170- # wait for it to start
171- sleep 30s
165+ - name : Checkout main repository
166+ uses : actions/checkout@v4
167+ with :
168+ path : this-repository
172169
173- # get result of last job
174- RES=$(curl -H "Accept: application/vnd.github.everest-preview+json" -H "Authorization: token ${{ secrets.DEPLOY_DEV5_GH_ACTION_DISPATCH }}" https://api.github.com/repos/dataquest-dev/dspace-ui-tests/actions/workflows/cron-test.yml/runs?per_page=1 2> /dev/null | jq .workflow_runs[0].conclusion)
170+ - name : Copy customer config to UI tests repository for merging
171+ run : |
172+ cp this-repository/config/config.lindat.ui.tests.json dspace-ui-tests/customer-constants/
175173
176- # while job did not finish, sleep
177- while [[ $RES == 'null' ]]; do
178- sleep 10s
179- RES=$(curl -H "Accept: application/vnd.github.everest-preview+json" -H "Authorization: token ${{ secrets.DEPLOY_DEV5_GH_ACTION_DISPATCH }}" https://api.github.com/repos/dataquest-dev/dspace-ui-tests/actions/workflows/cron-test.yml/runs?per_page=1 2> /dev/null | jq .workflow_runs[0].conclusion)
180- done;
174+ - name : test
175+ working-directory : dspace-ui-tests/scripts
176+ env :
177+ HOME_URL : https://dev-5.pc:8443/repository/
178+ NAME : LINDAT
179+ run : |
180+ ./test.sh
181181
182- echo $RES
183- # if last result is not success, return -1 and fail
184- if [[ $RES != \"success\" ]]; then
185- echo "playwright tests have failed! check appropriate action run in the dspace-ui-tests repository"
186- exit 1
187- fi;
182+ - uses : mazoea/ga-maz/end@master
183+ with :
184+ CHOWN_DIR : ./
185+ if : ${{ always() }}
188186
189187 rest-tests-after-deploy8 :
190188 runs-on : ubuntu-latest
0 commit comments