From 0284628246f2c3a76194773825bb7941f8acfcbf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Sza=C5=82owski?= Date: Tue, 19 Mar 2024 19:45:46 +0100 Subject: [PATCH] [#512] chore: split jobs to work in parallel; add emoji to label actions --- .github/workflows/code_check_frontend.yml | 50 ++++++++++++++++++++--- 1 file changed, 44 insertions(+), 6 deletions(-) diff --git a/.github/workflows/code_check_frontend.yml b/.github/workflows/code_check_frontend.yml index 08a58a085..2a65fa195 100644 --- a/.github/workflows/code_check_frontend.yml +++ b/.github/workflows/code_check_frontend.yml @@ -11,7 +11,7 @@ defaults: working-directory: govtool/frontend jobs: - code_check: + test: runs-on: ubuntu-latest steps: - name: Checkout code @@ -28,13 +28,51 @@ jobs: with: node-version-file: "govtool/frontend/.nvmrc" - - name: Run Frontend Test + - name: ๐Ÿงช Test run: | npm install npm run test - - name: Lint - run: npm run lint + lint: + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Cache dependencies + uses: actions/cache@v2 + with: + path: govtool/frontend/node_modules + key: ${{ runner.os }}-node-${{ hashFiles('govtool/frontend/package-lock.json') }} + + - name: Set up Node.js + uses: actions/setup-node@v4 + with: + node-version-file: "govtool/frontend/.nvmrc" + + - name: ๐Ÿ‘• Lint + run: / + npm install + npm run lint - - name: Type Check - run: npm run tsc + type_check: + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Cache dependencies + uses: actions/cache@v2 + with: + path: govtool/frontend/node_modules + key: ${{ runner.os }}-node-${{ hashFiles('govtool/frontend/package-lock.json') }} + + - name: Set up Node.js + uses: actions/setup-node@v4 + with: + node-version-file: "govtool/frontend/.nvmrc" + + - name: ๐Ÿ” Type Check + run: / + npm install + npm run lint