Skip to content

Commit

Permalink
Move js linting in own task (#6680)
Browse files Browse the repository at this point in the history
* Move js linting in own task

* Split into separate tasks
  • Loading branch information
alexander-schranz committed Jul 11, 2022
1 parent e17c478 commit 2ceca9c
Showing 1 changed file with 42 additions and 10 deletions.
52 changes: 42 additions & 10 deletions .github/workflows/test-application.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,9 @@ jobs:
matrix:
include:
- node-version: '12'
styleguide: false
- node-version: '14'
styleguide: true

env:
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -44,19 +46,9 @@ jobs:
with:
useLockFile: false

- name: Lint JavaScript and CSS code
run: |
npm run lint:js
npm run lint:scss
npm run flow -- check
npm run depcruise
- name: Test JavaScript code
run: npm test -- --maxWorkers=4

- name: Test Styleguidist build
run: npm run styleguide:build

- name: Install and configure PHP
uses: shivammathur/setup-php@v2
with:
Expand All @@ -69,6 +61,46 @@ jobs:
- name: Test application build
run: npm run build

- name: Test Styleguidist build
if: ${{ matrix.styleguide }}
run: npm run styleguide:build

js-lint:
name: "Node Lint"
runs-on: ubuntu-latest

env:
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}

steps:
- name: Checkout project
uses: actions/checkout@v2

- name: Install and configure Node
uses: actions/setup-node@v2-beta
with:
node-version: '14'

- name: Assert error when using yarn
run: tests/js/check-yarn-warning.sh

- name: Install npm dependencies
uses: bahmutov/npm-install@v1
with:
useLockFile: false

- name: Lint JavaScript
run: npm run lint:js

- name: Lint SCSS
run: npm run lint:scss

- name: Flow
run: npm run flow -- check

- name: Depcruise
run: npm run depcruise

php:
name: "PHP ${{ matrix.php-version }} (${{ matrix.database }}, ${{ matrix.phpcr-transport }}, ${{ matrix.dependency-versions }})"
runs-on: ubuntu-latest
Expand Down

0 comments on commit 2ceca9c

Please sign in to comment.