diff --git a/.github/workflows/test_admin_interface.yml b/.github/workflows/test_admin_interface.yml index 7108bd0b1..a2d1fe5ef 100644 --- a/.github/workflows/test_admin_interface.yml +++ b/.github/workflows/test_admin_interface.yml @@ -52,19 +52,16 @@ jobs: - name: Checkout code uses: actions/checkout@v3 - - name: Install turbo - run: yarn global add turbo@^2 - - - name: Prune admin with turbos help - run: turbo prune admin + - name: install bun + uses: oven-sh/setup-bun@v2 - name: install dependencies - run: cd out && yarn install --frozen-lockfile --production=false + run: bun install --frozen-lockfile - name: Admin Interface | Unit tests id: test run: | - cd out && turbo admin#test admin#lint + bun turbo admin#test admin#lint echo "success=$([ $? -eq 0 ] && echo true || echo false)" >> $GITHUB_OUTPUT lint: diff --git a/.github/workflows/test_backend.yml b/.github/workflows/test_backend.yml index 0dd68d762..5eaaf58d1 100644 --- a/.github/workflows/test_backend.yml +++ b/.github/workflows/test_backend.yml @@ -59,7 +59,7 @@ jobs: run: bun install --frozen-lockfile - 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;' + run: until nc -z localhost 3306; do echo waiting for db; sleep 1; done; - name: Backend | Unit tests run: bun turbo backend#test diff --git a/.github/workflows/test_dht_node.yml b/.github/workflows/test_dht_node.yml index 1fd2045bf..95d0d5af4 100644 --- a/.github/workflows/test_dht_node.yml +++ b/.github/workflows/test_dht_node.yml @@ -61,8 +61,8 @@ jobs: run: cd out && yarn install --frozen-lockfile --production=false - 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;' + run: until nc -z localhost 3306; do echo waiting for db; sleep 1; done; - - name: run unit test & lint & build & typecheck - run: cd out && turbo dht-node#lint dht-node#test dht-node#build dht-node#typecheck + - name: run unit test & build & typecheck + run: cd out && turbo dht-node#test dht-node#build dht-node#typecheck diff --git a/.github/workflows/test_federation.yml b/.github/workflows/test_federation.yml index bd670912c..25f8eaab5 100644 --- a/.github/workflows/test_federation.yml +++ b/.github/workflows/test_federation.yml @@ -61,8 +61,8 @@ jobs: run: cd out && yarn install --frozen-lockfile --production=false - 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;' + run: until nc -z localhost 3306; do echo waiting for db; sleep 1; done; - name: Federation | Unit tests id: test - run: cd out && turbo federation#lint federation#test federation#build federation#typecheck \ No newline at end of file + run: cd out && turbo federation#test federation#build federation#typecheck \ No newline at end of file diff --git a/.github/workflows/test_frontend.yml b/.github/workflows/test_frontend.yml index dd376427e..4853ec0d7 100644 --- a/.github/workflows/test_frontend.yml +++ b/.github/workflows/test_frontend.yml @@ -41,8 +41,6 @@ jobs: name: Unit Tests - Frontend 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 @@ -50,40 +48,53 @@ jobs: node-version: '18.20.7' - name: Checkout code - uses: actions/checkout@v3 - - - name: Install turbo - run: yarn global add turbo@^2 - - - name: Prune frontend with turbos help - run: turbo prune frontend + uses: actions/checkout@v4 + + - name: install bun + uses: oven-sh/setup-bun@v2 - name: install dependencies - run: cd out && yarn install --frozen-lockfile --production=false + run: bun install --frozen-lockfile - name: Frontend | Unit tests - id: test - run: | - cd out && turbo frontend#test frontend#lint - echo "success=$([ $? -eq 0 ] && echo true || echo false)" >> $GITHUB_OUTPUT + run: bun turbo frontend#test lint: - if: needs.files-changed.outputs.frontend == 'true' + if: needs.files-changed.outputs.config == 'true' || needs.files-changed.outputs.frontend == 'true' name: Lint - Frontend - needs: [files-changed, unit_test] + needs: files-changed runs-on: ubuntu-latest + outputs: + success: ${{ steps.lint.outputs.success }} steps: - - name: Check result from previous step - run: if [ "${{ needs.unit_test.outputs.test-success }}" != "true" ]; then exit 1; fi + - name: Set Node.js version + uses: actions/setup-node@v4 + with: + node-version: '18.20.7' + + - name: Checkout code + uses: actions/checkout@v4 + + - name: install bun + uses: oven-sh/setup-bun@v2 + + - name: install dependencies + run: bun install --frozen-lockfile + + - name: Frontend | Lint + id: lint + run: | + bun turbo frontend#lint + echo "success=$([ $? -eq 0 ] && echo true || echo false)" >> $GITHUB_OUTPUT stylelint: if: needs.files-changed.outputs.frontend == 'true' name: Stylelint - Frontend - needs: [files-changed, unit_test] + needs: [files-changed, lint] 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: if [ "${{ needs.lint.outputs.success }}" != "true" ]; then exit 1; fi locales: if: needs.files-changed.outputs.frontend == 'true'