generated from rohberg/volto-addon-template
-
Notifications
You must be signed in to change notification settings - Fork 1
77 lines (66 loc) · 2.01 KB
/
acceptance.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
name: Acceptance tests
on: [push]
env:
ADDON_NAME: "@rohberg/volto-searchkit-block"
ADDON_PATH: volto-searchkit-block
VOLTO_VERSION: 17
PLONE_VERSION: 6.0
# DEBUG INDEX_SERVER
# INDEX_SERVER: opensearch:9200
INDEX_OPENSEARCH: 1
INDEX_USE_SSL: 1
INDEX_LOGIN: admin
INDEX_PASSWORD: "oxczBG).3xWyapLn"
CELERY_BROKER: redis://redis:6379/0
CELERY_LOG_LEVEL: info
PLONE_SERVICE: http://backend-acceptance:55001
PLONE_SITE_PREFIX_PATH: plone
PLONE_USER: admin
PLONE_PASSWORD: secret
MAPPINGS_FILE: /configuration/mappings.json
ANALYSIS_FILE: /configuration/analysis.json
PREPROCESSINGS_FILE: /configuration/preprocessings.json
jobs:
acceptance:
runs-on: ubuntu-latest
timeout-minutes: 45
strategy:
fail-fast: false
matrix:
index_server: ["opensearch:9200", "localhost:9200"]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Install Cypress
run: |
cd acceptance
yarn
- name: "Cypress: Acceptance tests"
uses: cypress-io/github-action@v6
env:
BABEL_ENV: production
CYPRESS_RETRIES: 2
INDEX_SERVER: "${{ matrix.index_server }}"
with:
parallel: false
browser: chrome
working-directory: acceptance
spec: cypress/tests/*.cy.js
install: false
start: |
docker compose -f ci.yml --profile prod up
wait-on: 'npx wait-on --httpTimeout 20000 http-get://localhost:55001/plone http://localhost:3000 http://localhost:9200'
# Upload Cypress screenshots
- uses: actions/upload-artifact@v4
if: failure()
with:
name: cypress-screenshots-acceptance
path: acceptance/cypress/screenshots
# Upload Cypress videos
- uses: actions/upload-artifact@v4
if: failure()
with:
name: cypress-videos-acceptance
path: acceptance/cypress/videos