From 2964410590250705ce7043cb597851558b70bee0 Mon Sep 17 00:00:00 2001 From: epolon Date: Mon, 23 Dec 2024 12:40:01 +0200 Subject: [PATCH] mid work --- .github/workflows/codecov.yml | 10 ++++++++-- codecov.yml | 7 +++++-- packages/aws-cdk-lib/jest.config.js | 2 ++ 3 files changed, 15 insertions(+), 4 deletions(-) diff --git a/.github/workflows/codecov.yml b/.github/workflows/codecov.yml index 0920cc4e5515f..2ed84470298db 100644 --- a/.github/workflows/codecov.yml +++ b/.github/workflows/codecov.yml @@ -21,16 +21,22 @@ jobs: - name: Install dependencies run: yarn install + - name: Build Library + run: npx lerna run build --scope=aws-cdk-lib + - name: Build CLI run: npx lerna run build --scope=aws-cdk - - name: Run tests + - name: Run Core tests + run: cd packages/aws-cdk-lib && yarn test core + + - name: Run CLI tests run: cd packages/aws-cdk && yarn test - name: Upload results to Codecov uses: codecov/codecov-action@v4 with: - directory: packages/aws-cdk/coverage + files: packages/aws-cdk/coverage/cobertura-coverage.xml,packages/aws-cdk-lib/coverage/cobertura-coverage.xml fail_ci_if_error: true flags: suite.unit token: ${{ secrets.CODECOV_TOKEN }} diff --git a/codecov.yml b/codecov.yml index 1ab1a7e41c8f6..e21d3c0ecbf7d 100644 --- a/codecov.yml +++ b/codecov.yml @@ -9,7 +9,6 @@ coverage: default: # require the overall patch coverage to be at least 95% target: 95 - # https://docs.codecov.com/docs/codecovyml-reference#comment comment: @@ -26,10 +25,14 @@ component_management: - type: patch target: 95 individual_components: - - component_id: packages_aws_cdk # identifier that should not be changed + - component_id: packages_aws_cdk # identifier that should not be changed name: packages/aws-cdk # display name that can change freely paths: - packages/aws-cdk/** + - component_id: packages_aws_cdk_lib_core # identifier that should not be changed + name: packages/aws-cdk-lib/core # display name that can change freely + paths: + - packages/aws-cdk-lib/core/** # https://docs.codecov.com/docs/ignoring-paths ignore: diff --git a/packages/aws-cdk-lib/jest.config.js b/packages/aws-cdk-lib/jest.config.js index 8df1f8a34a56d..ff2f907fa96ec 100644 --- a/packages/aws-cdk-lib/jest.config.js +++ b/packages/aws-cdk-lib/jest.config.js @@ -8,6 +8,8 @@ module.exports = { testMatch: [ '/**/test/**/?(*.)+(test).ts', ], + coveragePathIgnorePatterns: ['\\.generated\\.[jt]s$', '/.*/test/', '.warnings.jsii.js$', '/node_modules/'], + // Massive parallellism leads to common timeouts testTimeout: 60_000,