diff --git a/.github/workflows/pre-commit.yml b/.github/workflows/pre-commit.yml index 11ad48f4b3ed..c9fb912abc34 100644 --- a/.github/workflows/pre-commit.yml +++ b/.github/workflows/pre-commit.yml @@ -59,15 +59,16 @@ jobs: cache: "npm" cache-dependency-path: "superset-frontend/package-lock.json" - - name: Install Frontend Dependencies - run: | - cd superset-frontend - npm ci - - - name: Install Docs Dependencies - run: | - cd docs - yarn install --immutable + - parallel: + - name: Install Frontend Dependencies + run: | + cd superset-frontend + npm ci + + - name: Install Docs Dependencies + run: | + cd docs + yarn install --immutable - name: Cache pre-commit environments uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0 diff --git a/.github/workflows/superset-frontend.yml b/.github/workflows/superset-frontend.yml index 7f411e3a8572..769081dfcbc5 100644 --- a/.github/workflows/superset-frontend.yml +++ b/.github/workflows/superset-frontend.yml @@ -143,7 +143,7 @@ jobs: files: merged-output/coverage-summary.json slug: apache/superset - lint-frontend: + lint-and-validate-frontend: needs: frontend-build if: needs.frontend-build.outputs.should-run == 'true' runs-on: ubuntu-24.04 @@ -158,35 +158,16 @@ jobs: run: | zstd -d < docker-image.tar.zst | docker load - - name: lint - run: | - docker run --rm $TAG bash -c \ - "npm i && npm run lint" - - - name: tsc - run: | - docker run --rm $TAG bash -c \ - "npm i && npm run plugins:build && npm run type" + - parallel: + - name: lint + run: | + docker run --rm $TAG bash -c \ + "npm run lint" - validate-frontend: - needs: frontend-build - if: needs.frontend-build.outputs.should-run == 'true' - runs-on: ubuntu-24.04 - timeout-minutes: 20 - steps: - - name: Download Docker Image Artifact - uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8 - with: - name: docker-image - - - name: Load Docker Image - run: | - zstd -d < docker-image.tar.zst | docker load - - - name: Build Plugins Packages - run: | - docker run --rm $TAG bash -c \ - "npm run plugins:build" + - name: build plugin and typecheck + run: | + docker run --rm $TAG bash -c \ + "npm run plugins:build && npm run type" test-storybook: needs: frontend-build @@ -206,4 +187,4 @@ jobs: - name: Build Storybook and Run Tests run: | docker run --rm $TAG bash -c \ - "npm run build-storybook && npx playwright install-deps && npx playwright install chromium && npm run test-storybook:ci" + "npm run build-storybook && npx playwright install chromium --with-deps && npm run test-storybook:ci" diff --git a/.github/workflows/superset-python-unittest.yml b/.github/workflows/superset-python-unittest.yml index 056d959802f3..6bb5f0b2ae84 100644 --- a/.github/workflows/superset-python-unittest.yml +++ b/.github/workflows/superset-python-unittest.yml @@ -69,19 +69,20 @@ jobs: uses: ./.github/actions/setup-backend/ with: python-version: ${{ matrix.python-version }} - - name: Python unit tests - env: - SUPERSET_TESTENV: true - SUPERSET_SECRET_KEY: not-a-secret - run: | - pytest --durations-min=0.5 --cov-report= --cov=superset ./tests/common ./tests/unit_tests --cache-clear --maxfail=50 - - name: Python 100% coverage unit tests - env: - SUPERSET_TESTENV: true - SUPERSET_SECRET_KEY: not-a-secret - run: | - pytest --durations-min=0.5 --cov=superset/sql/ ./tests/unit_tests/sql/ --cache-clear --cov-fail-under=100 - pytest --durations-min=0.5 --cov=superset/semantic_layers/ ./tests/unit_tests/semantic_layers/ --cache-clear --cov-fail-under=100 + - parallel: + - name: Python unit tests + env: + SUPERSET_TESTENV: true + SUPERSET_SECRET_KEY: not-a-secret + run: | + pytest --durations-min=0.5 --cov-report= --cov=superset ./tests/common ./tests/unit_tests --cache-clear --maxfail=50 + - name: Python 100% coverage unit tests + env: + SUPERSET_TESTENV: true + SUPERSET_SECRET_KEY: not-a-secret + run: | + pytest --durations-min=0.5 --cov=superset/sql/ ./tests/unit_tests/sql/ --cache-clear --cov-fail-under=100 + pytest --durations-min=0.5 --cov=superset/semantic_layers/ ./tests/unit_tests/semantic_layers/ --cache-clear --cov-fail-under=100 - name: Upload code coverage uses: codecov/codecov-action@fb8b3582c8e4def4969c97caa2f19720cb33a72f # v7.0.0 with: