|
6 | 6 | pull_request: |
7 | 7 |
|
8 | 8 | jobs: |
| 9 | + checksecret: |
| 10 | + name: check if MY_SECRET is set in github secrets |
| 11 | + runs-on: ubuntu-latest |
| 12 | + outputs: |
| 13 | + is_MY_SECRET_set: ${{ steps.checksecret_job.outputs.is_MY_SECRET_set }} |
| 14 | + steps: |
| 15 | + - name: Check whether unity activation requests should be done |
| 16 | + id: checksecret_job |
| 17 | + env: |
| 18 | + MY_SECRET: ${{ secrets.GMAP_API_KEY }} |
| 19 | + run: | |
| 20 | + echo "is_MY_SECRET_set: ${{ env.MY_SECRET != '' }}" |
| 21 | + echo "::set-output name=is_MY_SECRET_set::${{ env.MY_SECRET != '' }}" |
9 | 22 | integration: |
10 | 23 | env: |
11 | 24 | VUE_APP_API_KEY: YOUR_GOOGLE_MAPS_API_KEY |
|
63 | 76 | name: ${{ matrix.os }}-node-v${{ matrix.node }}-build |
64 | 77 | path: dist |
65 | 78 |
|
| 79 | + |
| 80 | + cypress-chrome-firefox-simple: |
| 81 | + needs: [checksecret, integration] |
| 82 | + if: needs.checksecret.outputs.is_MY_SECRET_set == 'false' |
| 83 | + runs-on: ubuntu-16.04 |
| 84 | + name: E2E on Ubuntu |
| 85 | + strategy: |
| 86 | + fail-fast: false |
| 87 | + matrix: |
| 88 | + browsers: [chrome, firefox] |
| 89 | + steps: |
| 90 | + - uses: actions/checkout@v1 |
| 91 | + - uses: cypress-io/github-action@v2 |
| 92 | + with: |
| 93 | + start: npm run serve |
| 94 | + wait-on: 'http://localhost:8080' |
| 95 | + record: true |
| 96 | + parallel: true |
| 97 | + group: ${{matrix.browsers}} |
| 98 | + tag: ${{ github.event_name }} |
| 99 | + browser: ${{matrix.browsers}} |
| 100 | + spec: | |
| 101 | + tests/e2e/specs/homePage.test.js |
| 102 | + env: |
| 103 | + CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }} |
| 104 | + COMMIT_INFO_MESSAGE: ${{ github.event.pull_request.title }} |
| 105 | + |
| 106 | + |
| 107 | + |
66 | 108 | cypress-chrome-firefox: |
67 | | - needs: integration |
| 109 | + needs: [checksecret, integration] |
| 110 | + if: needs.checksecret.outputs.is_MY_SECRET_set == 'true' |
68 | 111 | env: |
69 | 112 | VUE_APP_API_KEY: ${{ secrets.GMAP_API_KEY }} |
70 | 113 | VUE_APP_FIREBASE_API_KEY: ${{ secrets.VUE_APP_FIREBASE_API_KEY }} |
|
0 commit comments