From 8238e6972c5fd740f04f83026e1a0bb64a844276 Mon Sep 17 00:00:00 2001 From: einhornimmond Date: Sun, 4 May 2025 10:54:52 +0200 Subject: [PATCH] try if status check needs to be a job or can be a step --- .github/workflows/lint.yml | 6 +----- .github/workflows/test_backend.yml | 28 ++++------------------------ .github/workflows/test_config.yml | 6 +++--- .github/workflows/test_database.yml | 4 ++-- 4 files changed, 10 insertions(+), 34 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 0a3179b26..1c6be871f 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -16,11 +16,7 @@ jobs: run: biome ci ./config-schema - name: Lint - Backend run: biome ci ./backend - - name: Lint - Frontend - run: biome ci ./frontend - - name: Lint - Admin - run: biome ci ./admin - - name: Lint - Database + - name: Lint - Database Up run: biome ci ./database - name: Lint - DHT Node run: biome ci ./dht-node diff --git a/.github/workflows/test_backend.yml b/.github/workflows/test_backend.yml index 74abd0403..33d345dc4 100644 --- a/.github/workflows/test_backend.yml +++ b/.github/workflows/test_backend.yml @@ -40,8 +40,6 @@ jobs: name: Unit tests - Backend needs: files-changed runs-on: ubuntu-latest - outputs: - test-success: ${{ steps.test.outputs.success }} steps: - name: Set Node.js version uses: actions/setup-node@v4 @@ -63,29 +61,11 @@ jobs: - name: install dependencies run: cd out && yarn install --frozen-lockfile --production=false + - name: Locales - Backend + run: cd out && yarn locales + - name: Wait for MariaDB to be ready run: docker run --rm --network gradido_internal-net busybox sh -c 'until nc -z mariadb 3306; do echo waiting for db; sleep 1; done;' - name: Backend | Unit tests - id: test - run: | - cd out && turbo backend#lint backend#test backend#build backend#typecheck - echo "success=$([ $? -eq 0 ] && echo true || echo false)" >> $GITHUB_OUTPUT - - lint: - if: needs.files-changed.outputs.backend == 'true' - name: Lint - Backend - needs: [files-changed, unit_test] - runs-on: ubuntu-latest - steps: - - name: Check result from previous step - run: if [ "${{ needs.unit_test.outputs.test-success }}" != "true" ]; then exit 1; fi - - locales: - if: needs.files-changed.outputs.backend == 'true' - name: Locales - Backend - needs: [files-changed, unit_test] - runs-on: ubuntu-latest - steps: - - name: Check result from previous step - run: if [ "${{ needs.unit_test.outputs.test-success }}" != "true" ]; then exit 1; fi + run: cd out && turbo backend#test backend#build backend#typecheck \ No newline at end of file diff --git a/.github/workflows/test_config.yml b/.github/workflows/test_config.yml index b52291694..8a681ab4c 100644 --- a/.github/workflows/test_config.yml +++ b/.github/workflows/test_config.yml @@ -21,7 +21,7 @@ jobs: list-files: shell build: - name: typecheck and lint - Config-Schema + name: typecheck - Config-Schema if: needs.files-changed.outputs.config == 'true' || needs.files-changed.outputs.docker-compose == 'true' needs: files-changed runs-on: ubuntu-latest @@ -38,6 +38,6 @@ jobs: - name: install dependencies run: cd out && yarn install --frozen-lockfile --production=false - - name: typecheck and lint - run: cd out && turbo typecheck lint + - name: typecheck + run: cd out && turbo typecheck diff --git a/.github/workflows/test_database.yml b/.github/workflows/test_database.yml index 641f7f459..4b1c4886c 100644 --- a/.github/workflows/test_database.yml +++ b/.github/workflows/test_database.yml @@ -81,5 +81,5 @@ jobs: - name: install dependencies run: cd out && yarn install --frozen-lockfile --production=false - - name: Database | Lint - run: cd out && turbo lint build typecheck \ No newline at end of file + - name: Database + run: cd out && turbo build typecheck \ No newline at end of file