Skip to content

Commit

Permalink
chore: add aws-cdk-lib/core to codecov (#32641)
Browse files Browse the repository at this point in the history
  • Loading branch information
iliapolo authored Dec 30, 2024
1 parent fe3af93 commit 2355d1c
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 4 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/codecov.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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 }}
7 changes: 5 additions & 2 deletions codecov.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand All @@ -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:
Expand Down
2 changes: 2 additions & 0 deletions packages/aws-cdk-lib/jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ module.exports = {
testMatch: [
'<rootDir>/**/test/**/?(*.)+(test).ts',
],
coveragePathIgnorePatterns: ['\\.generated\\.[jt]s$', '<rootDir>/.*/test/', '.warnings.jsii.js$', '/node_modules/'],

// Massive parallellism leads to common timeouts
testTimeout: 60_000,

Expand Down

0 comments on commit 2355d1c

Please sign in to comment.