File: pull_request_e2e.yml

package info (click to toggle)
openrefine 3.9.5-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 44,440 kB
  • sloc: javascript: 106,758; java: 91,946; xml: 6,634; sh: 614; makefile: 78; python: 71; sql: 59
file content (86 lines) | stat: -rw-r--r-- 2,428 bytes parent folder | download
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
78
79
80
81
82
83
84
85
86
name: E2E CI

on:
  pull_request:
    paths-ignore:
      - 'main/IDEs/**'
      - 'main/webapp/modules/core/langs/**'
      - 'extensions/database/module/langs/**'
      - 'extensions/pc-axis/module/langs/**'
      - 'extensions/phonetic/module/langs/**'
      - 'extensions/wikidata/module/langs/**'
    branches:
      - master
      - '4.0'

permissions: read-all

jobs:
  prepare_e2e_test_matrix:
    runs-on: ubuntu-latest
    outputs:
      matrix: ${{ steps.set-matrix.outputs.matrix }}
    steps:
      - uses: actions/checkout@v5
      - name: Setup Node
        uses: actions/setup-node@v4
        with:
          node-version: '20'
      - id: set-matrix
        run: npm install --save glob@8.1.0 && node main/tests/cypress/build-test-matrix.js >> $GITHUB_OUTPUT
        env:
          browsers: chrome
  e2e_test:
    name: e2e_test ${{ matrix.specs.group }}
    needs: prepare_e2e_test_matrix
    runs-on: ubuntu-latest
    strategy:
      matrix: ${{fromJSON(needs.prepare_e2e_test_matrix.outputs.matrix)}}
    steps:
      - uses: actions/checkout@v5

      - name: Set up Java 17
        uses: actions/setup-java@v5
        with:
          distribution: 'temurin'
          java-version: 17
          cache: 'maven'

      - name: Build OpenRefine
        run: ./refine build

      - name: Setup Node
        uses: actions/setup-node@v4
        with:
          node-version: '20'

      - name: Restore Tests dependency cache
        uses: actions/cache@v4
        with:
          path: |
            ~/cache
            ~/.cache
            **/node_modules
            !~/cache/exclude
          key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }}
          restore-keys: |
            ${{ runner.os }}-yarn

      - name: Install test dependencies
        run: |
          cd ./main/tests/cypress
          npm i -g yarn
          yarn install

      - name: Test with Cypress on ${{ matrix.browser }}
        run: | 
          echo REFINE_MIN_MEMORY=1400M >> ./refine.ini
          echo REFINE_MEMORY=4096M >> ./refine.ini
          ./refine e2e_tests
        env:
          CYPRESS_BROWSER: ${{ matrix.browser }}
          CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
          CYPRESS_PROJECT_ID: ${{ vars.CYPRESS_PROJECT_ID }}
          CYPRESS_CI_BUILD_ID: '${{ github.run_id }}'
          CYPRESS_SPECS: ${{ matrix.specs.paths }}
          CYPRESS_GROUP: ${{ matrix.specs.group }}