forked from oppia/oppia
-
Notifications
You must be signed in to change notification settings - Fork 0
46 lines (45 loc) · 1.55 KB
/
eslint_tests.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
name: Custom ESLint tests
on:
push:
branches:
- develop
- release-*
pull_request:
branches:
- develop
- release-*
jobs:
run_tests:
name: Run Tests for Custom ESLint Checks
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-22.04]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v3
with:
python-version: '3.8.12'
architecture: 'x64'
- uses: ./.github/actions/merge
- name: Cache node modules
uses: actions/cache@v3
env:
cache-name: cache-node-modules
with:
path: /home/runner/work/oppia/yarn_cache
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('yarn.lock') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- uses: ./.github/actions/install-oppia-dependencies
- name: Run ESLint Tests
if: startsWith(github.head_ref, 'update-changelog-for-release') == false
run: PYTHONIOENCODING=utf-8 python -m scripts.run_custom_eslint_tests
- name: Report failure if failed on oppia/oppia develop branch
if: ${{ failure() && github.event_name == 'push' && github.repository == 'oppia/oppia' && github.ref == 'refs/heads/develop'}}
uses: ./.github/actions/send-webhook-notification
with:
message: "ESLint checks failed on the upstream develop branch."
webhook-url: ${{ secrets.BUILD_FAILURE_ROOM_WEBHOOK_URL }}