@@ -16,63 +16,65 @@ jobs:
1616 # Maps tcp port 5432 on service container to the host
1717 - 8000:8000
1818 steps :
19- - uses : actions/checkout@v3
20- - name : Use Node.js ${{ matrix.node-version }}
21- uses : actions/setup-node@v3
22- with :
23- node-version : ${{ matrix.node-version }}
24- cache : ' npm'
25- - run : npm install caniuse-lite
26- - run : npm install
27- - run : npx browserslist@latest --update-db
28- - run : npm run build:no-progress --if-present
29- env :
30- SENTRY_AUTH_TOKEN : ${{ secrets.SENTRY_AUTH_TOKEN }}
31- SENTRY_DSN : ${{ secrets.SENTRY_DSN }}
32- SENTRY_ORG : ${{ secrets.SENTRY_ORG }}
33- SENTRY_PROJECT : ${{ secrets.SENTRY_PROJECT }}
34- - run : npm run test
35- # - run: npm run e2e:cli
36- - name : Cypress install
37- uses : cypress-io/github-action@v5.0.0 # use the explicit version number
38- with :
39- # Disable running of tests within install job
40- install-command : npm install
41- runTests : true
42- start : npm run serve:build http://127.0.0.1:8080
43- record : true
44- config-file : ./cypress/config/cypress.production.config.js
45- env :
46- CYPRESS_RECORD_KEY : ${{ secrets.CYPRESS_RECORD_KEY }}
47- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
48- - uses : actions/upload-artifact@v3.1.1
49- if : failure()
50- with :
51- name : cypress-screenshots
52- path : cypress/screenshots
53- # Test run video was always captured, so this action uses "always()" condition
54- - uses : actions/upload-artifact@v3.1.1
55- if : failure()
56- with :
57- name : cypress-videos
58- path : cypress/videos
59- - name : Update gh-pages
60- if : github.ref == 'refs/heads/develop'
61- uses : Cecilapp/GitHub-Pages-deploy@v3
62- env :
63- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
64- with :
65- email : contact@sebastienbarbier.com
66- build_dir : build
67- cname : next.seven23.io
68- - name : " Predeploy"
69- if : github.ref == 'refs/heads/main'
70- run : npm run predeploy
71- - name : " Deploy with Swift"
72- if : github.ref == 'refs/heads/main'
73- env : # Set the secret as an input
74- OS_PASSWORD : ${{ secrets.OS_PASSWORD }}
75- OS_USERNAME : ${{ secrets.OS_USERNAME }}
76- OS_TENANT_ID : ${{ secrets.OS_TENANT_ID }}
77- OS_TENANT_NAME : ${{ secrets.OS_TENANT_NAME }}
78- run : npm run deploy
19+ - uses : actions/checkout@v4
20+ - name : Use Node.js ${{ matrix.node-version }}
21+ uses : actions/setup-node@v4
22+ with :
23+ node-version : ${{ matrix.node-version }}
24+ cache : " npm"
25+ - run : npm install caniuse-lite
26+ - run : npm install
27+ - run : npx browserslist@latest --update-db
28+ - run : npm run build:no-progress --if-present
29+ env :
30+ SENTRY_AUTH_TOKEN : ${{ secrets.SENTRY_AUTH_TOKEN }}
31+ SENTRY_DSN : ${{ secrets.SENTRY_DSN }}
32+ SENTRY_ORG : ${{ secrets.SENTRY_ORG }}
33+ SENTRY_PROJECT : ${{ secrets.SENTRY_PROJECT }}
34+ - run : npm run format
35+ - run : npm run lint
36+ - run : npm run test
37+ # - run: npm run e2e:cli
38+ - name : Cypress install
39+ uses : cypress-io/github-action@v5.0.0 # use the explicit version number
40+ with :
41+ # Disable running of tests within install job
42+ install-command : npm install
43+ runTests : true
44+ start : npm run serve:build http://127.0.0.1:8080
45+ record : true
46+ config-file : ./cypress/config/cypress.production.config.js
47+ env :
48+ CYPRESS_RECORD_KEY : ${{ secrets.CYPRESS_RECORD_KEY }}
49+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
50+ - uses : actions/upload-artifact@v4
51+ if : failure()
52+ with :
53+ name : cypress-screenshots
54+ path : cypress/screenshots
55+ # Test run video was always captured, so this action uses "always()" condition
56+ - uses : actions/upload-artifact@v4
57+ if : failure()
58+ with :
59+ name : cypress-videos
60+ path : cypress/videos
61+ - name : Update gh-pages
62+ if : github.ref == 'refs/heads/develop'
63+ uses : Cecilapp/GitHub-Pages-deploy@v3
64+ env :
65+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
66+ with :
67+ email : contact@sebastienbarbier.com
68+ build_dir : build
69+ cname : next.seven23.io
70+ - name : " Predeploy"
71+ if : github.ref == 'refs/heads/main'
72+ run : npm run predeploy
73+ - name : " Deploy with Swift"
74+ if : github.ref == 'refs/heads/main'
75+ env : # Set the secret as an input
76+ OS_PASSWORD : ${{ secrets.OS_PASSWORD }}
77+ OS_USERNAME : ${{ secrets.OS_USERNAME }}
78+ OS_TENANT_ID : ${{ secrets.OS_TENANT_ID }}
79+ OS_TENANT_NAME : ${{ secrets.OS_TENANT_NAME }}
80+ run : npm run deploy
0 commit comments