Merge branch 'development' into dev/build #6980
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: NPM Tests | |
on: | |
push: | |
branches-ignore: | |
- 'master' | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.ref }} | |
cancel-in-progress: true | |
jobs: | |
npm: | |
runs-on: ubuntu-latest | |
env: | |
CYPRESS_INSTALL_BINARY: 0 | |
strategy: | |
matrix: | |
node-version: [18.x] | |
steps: | |
- name: Checkout source code | |
uses: actions/checkout@v2 | |
- name: Setup node | |
uses: actions/setup-node@v1 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Get yarn cache directory path | |
id: yarn-cache-dir-path | |
run: echo "::set-output name=dir::$(yarn cache dir)" | |
- uses: actions/cache@v2 | |
id: yarn-cache | |
with: | |
path: ${{ steps.yarn-cache-dir-path.outputs.dir }} | |
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | |
restore-keys: | | |
${{ runner.os }}-yarn- | |
- name: Install Dependencies | |
env: | |
CYPRESS_INSTALL_BINARY: 0 | |
run: npm ci | |
- name: Install Cypress Dependencies | |
working-directory: ./e2e-tests | |
run: npm ci | |
- name: Build source | |
run: npm run build | |
- name: Run package check | |
run: npm run lint:package-json | |
- name: Run dashboard check | |
run: npm run lint:dash | |
- name: Run customizer check | |
run: npm run lint:customizer | |
- name: Run Stylelint on SCSS | |
run: npm run lint:scss | |
- name: Run global JS check | |
run: npm run lint:global | |
- name: Run size check | |
# WORKAROUND FOR SIZE-LIMIT JOB NUMBER | |
env: | |
CI_JOB_NUMBER: 1 | |
run: npm run size |