Skip to content

Commit a7de81e

Browse files
committed
test(NODE-6891): add coverage for all test runs
1 parent 9a9e0e7 commit a7de81e

File tree

3 files changed

+39
-17
lines changed

3 files changed

+39
-17
lines changed

.evergreen/config.in.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1066,6 +1066,7 @@ task_groups:
10661066
binary: bash
10671067
args:
10681068
- ${DRIVERS_TOOLS}/.evergreen/csfle/gcpkms/teardown.sh
1069+
- func: "upload coverage report"
10691070
tasks:
10701071
- test-gcpkms-task
10711072

@@ -1093,6 +1094,7 @@ task_groups:
10931094
binary: bash
10941095
args:
10951096
- ${DRIVERS_TOOLS}/.evergreen/csfle/azurekms/teardown.sh
1097+
- func: "upload coverage report"
10961098
tasks:
10971099
- test-azurekms-task
10981100

@@ -1113,6 +1115,7 @@ task_groups:
11131115
binary: bash
11141116
args:
11151117
- ${DRIVERS_TOOLS}/.evergreen/auth_oidc/k8s/teardown.sh
1118+
- func: "upload coverage report"
11161119
setup_group_can_fail_task: true
11171120
setup_group_timeout_secs: 1800
11181121
tasks:
@@ -1135,6 +1138,7 @@ task_groups:
11351138
binary: bash
11361139
args:
11371140
- ${DRIVERS_TOOLS}/.evergreen/auth_oidc/k8s/teardown.sh
1141+
- func: "upload coverage report"
11381142
setup_group_can_fail_task: true
11391143
setup_group_timeout_secs: 1800
11401144
tasks:
@@ -1157,6 +1161,7 @@ task_groups:
11571161
binary: bash
11581162
args:
11591163
- ${DRIVERS_TOOLS}/.evergreen/auth_oidc/k8s/teardown.sh
1164+
- func: "upload coverage report"
11601165
setup_group_can_fail_task: true
11611166
setup_group_timeout_secs: 1800
11621167
tasks:
@@ -1177,6 +1182,8 @@ task_groups:
11771182
MONGODB_VERSION: "8.0"
11781183
args:
11791184
- ${DRIVERS_TOOLS}/.evergreen/auth_oidc/setup.sh
1185+
teardown_task:
1186+
- func: "upload coverage report"
11801187
setup_group_can_fail_task: true
11811188
setup_group_timeout_secs: 1800
11821189
tasks:
@@ -1200,6 +1207,7 @@ task_groups:
12001207
script: |-
12011208
${PREPARE_SHELL}
12021209
$DRIVERS_TOOLS/.evergreen/auth_oidc/azure/teardown.sh
1210+
- func: "upload coverage report"
12031211
setup_group_can_fail_task: true
12041212
setup_group_timeout_secs: 1800
12051213
tasks:
@@ -1223,6 +1231,7 @@ task_groups:
12231231
script: |-
12241232
${PREPARE_SHELL}
12251233
$DRIVERS_TOOLS/.evergreen/auth_oidc/gcp/teardown.sh
1234+
- func: "upload coverage report"
12261235
setup_group_can_fail_task: true
12271236
setup_group_timeout_secs: 1800
12281237
tasks:
@@ -1252,6 +1261,7 @@ task_groups:
12521261
binary: bash
12531262
args:
12541263
- ${DRIVERS_TOOLS}/.evergreen/atlas/teardown-atlas-cluster.sh
1264+
- func: "upload coverage report"
12551265
setup_group_can_fail_task: true
12561266
setup_group_timeout_secs: 1800
12571267
tasks:
@@ -1279,6 +1289,7 @@ task_groups:
12791289
binary: bash
12801290
args:
12811291
- ${DRIVERS_TOOLS}/.evergreen/atlas/teardown-atlas-cluster.sh
1292+
- func: "upload coverage report"
12821293
setup_group_can_fail_task: true
12831294
setup_group_timeout_secs: 1800
12841295
tasks:

.evergreen/config.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2926,6 +2926,7 @@ task_groups:
29262926
binary: bash
29272927
args:
29282928
- ${DRIVERS_TOOLS}/.evergreen/csfle/gcpkms/teardown.sh
2929+
- func: upload coverage report
29292930
tasks:
29302931
- test-gcpkms-task
29312932
- name: test_azurekms_task_group
@@ -2950,6 +2951,7 @@ task_groups:
29502951
binary: bash
29512952
args:
29522953
- ${DRIVERS_TOOLS}/.evergreen/csfle/azurekms/teardown.sh
2954+
- func: upload coverage report
29532955
tasks:
29542956
- test-azurekms-task
29552957
- name: testk8soidc_task_group_eks
@@ -2969,6 +2971,7 @@ task_groups:
29692971
binary: bash
29702972
args:
29712973
- ${DRIVERS_TOOLS}/.evergreen/auth_oidc/k8s/teardown.sh
2974+
- func: upload coverage report
29722975
setup_group_can_fail_task: true
29732976
setup_group_timeout_secs: 1800
29742977
tasks:
@@ -2990,6 +2993,7 @@ task_groups:
29902993
binary: bash
29912994
args:
29922995
- ${DRIVERS_TOOLS}/.evergreen/auth_oidc/k8s/teardown.sh
2996+
- func: upload coverage report
29932997
setup_group_can_fail_task: true
29942998
setup_group_timeout_secs: 1800
29952999
tasks:
@@ -3011,6 +3015,7 @@ task_groups:
30113015
binary: bash
30123016
args:
30133017
- ${DRIVERS_TOOLS}/.evergreen/auth_oidc/k8s/teardown.sh
3018+
- func: upload coverage report
30143019
setup_group_can_fail_task: true
30153020
setup_group_timeout_secs: 1800
30163021
tasks:
@@ -3032,6 +3037,8 @@ task_groups:
30323037
MONGODB_VERSION: '8.0'
30333038
args:
30343039
- ${DRIVERS_TOOLS}/.evergreen/auth_oidc/setup.sh
3040+
teardown_task:
3041+
- func: upload coverage report
30353042
setup_group_can_fail_task: true
30363043
setup_group_timeout_secs: 1800
30373044
tasks:
@@ -3054,6 +3061,7 @@ task_groups:
30543061
script: |-
30553062
${PREPARE_SHELL}
30563063
$DRIVERS_TOOLS/.evergreen/auth_oidc/azure/teardown.sh
3064+
- func: upload coverage report
30573065
setup_group_can_fail_task: true
30583066
setup_group_timeout_secs: 1800
30593067
tasks:
@@ -3076,6 +3084,7 @@ task_groups:
30763084
script: |-
30773085
${PREPARE_SHELL}
30783086
$DRIVERS_TOOLS/.evergreen/auth_oidc/gcp/teardown.sh
3087+
- func: upload coverage report
30793088
setup_group_can_fail_task: true
30803089
setup_group_timeout_secs: 1800
30813090
tasks:
@@ -3104,6 +3113,7 @@ task_groups:
31043113
binary: bash
31053114
args:
31063115
- ${DRIVERS_TOOLS}/.evergreen/atlas/teardown-atlas-cluster.sh
3116+
- func: upload coverage report
31073117
setup_group_can_fail_task: true
31083118
setup_group_timeout_secs: 1800
31093119
tasks:
@@ -3130,6 +3140,7 @@ task_groups:
31303140
binary: bash
31313141
args:
31323142
- ${DRIVERS_TOOLS}/.evergreen/atlas/teardown-atlas-cluster.sh
3143+
- func: upload coverage report
31333144
setup_group_can_fail_task: true
31343145
setup_group_timeout_secs: 1800
31353146
tasks:

package.json

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -131,34 +131,34 @@
131131
"check:bench": "npm --prefix test/benchmarks/driver_bench start",
132132
"check:coverage": "nyc npm run test:all",
133133
"check:integration-coverage": "nyc npm run check:test",
134-
"check:lambda": "mocha --config test/mocha_lambda.js test/integration/node-specific/examples/handler.test.js",
135-
"check:lambda:aws": "mocha --config test/mocha_lambda.js test/integration/node-specific/examples/aws_handler.test.js",
134+
"check:lambda": "nyc mocha --config test/mocha_lambda.js test/integration/node-specific/examples/handler.test.js",
135+
"check:lambda:aws": "nyc mocha --config test/mocha_lambda.js test/integration/node-specific/examples/aws_handler.test.js",
136136
"check:lint": "npm run build:dts && npm run check:dts && npm run check:eslint && npm run check:tsd",
137137
"check:eslint": "npm run build:dts && ESLINT_USE_FLAT_CONFIG=false eslint -v && ESLINT_USE_FLAT_CONFIG=false eslint --max-warnings=0 --ext '.js,.ts' src test",
138138
"check:tsd": "tsd --version && tsd",
139139
"check:dependencies": "mocha test/action/dependency.test.ts",
140140
"check:dts": "node ./node_modules/typescript/bin/tsc --noEmit mongodb.d.ts && tsd",
141141
"check:search-indexes": "nyc mocha --config test/mocha_mongodb.js test/manual/search-index-management.prose.test.ts",
142142
"check:test": "mocha --config test/mocha_mongodb.js test/integration",
143-
"check:unit": "mocha test/unit",
143+
"check:unit": "nyc mocha test/unit",
144144
"check:ts": "node ./node_modules/typescript/bin/tsc -v && node ./node_modules/typescript/bin/tsc --noEmit",
145-
"check:atlas": "mocha --config test/manual/mocharc.js test/manual/atlas_connectivity.test.ts",
146-
"check:resource-management": "mocha --config test/manual/mocharc.js test/manual/resource_management.test.ts",
147-
"check:drivers-atlas-testing": "mocha --config test/mocha_mongodb.js test/atlas/drivers_atlas_testing.test.ts",
148-
"check:adl": "mocha --config test/mocha_mongodb.js test/manual/atlas-data-lake-testing",
145+
"check:atlas": "nyc mocha --config test/manual/mocharc.js test/manual/atlas_connectivity.test.ts",
146+
"check:resource-management": "nyc mocha --config test/manual/mocharc.js test/manual/resource_management.test.ts",
147+
"check:drivers-atlas-testing": "nyc mocha --config test/mocha_mongodb.js test/atlas/drivers_atlas_testing.test.ts",
148+
"check:adl": "nyc mocha --config test/mocha_mongodb.js test/manual/atlas-data-lake-testing",
149149
"check:aws": "nyc mocha --config test/mocha_mongodb.js test/integration/auth/mongodb_aws.test.ts",
150-
"check:oidc-auth": "mocha --config test/mocha_mongodb.js test/integration/auth/auth.spec.test.ts",
151-
"check:oidc-test": "mocha --config test/mocha_mongodb.js test/integration/auth/mongodb_oidc.prose.test.ts",
152-
"check:oidc-azure": "mocha --config test/mocha_mongodb.js test/integration/auth/mongodb_oidc_azure.prose.05.test.ts",
153-
"check:oidc-gcp": "mocha --config test/mocha_mongodb.js test/integration/auth/mongodb_oidc_gcp.prose.06.test.ts",
154-
"check:oidc-k8s": "mocha --config test/mocha_mongodb.js test/integration/auth/mongodb_oidc_k8s.prose.07.test.ts",
150+
"check:oidc-auth": "nyc mocha --config test/mocha_mongodb.js test/integration/auth/auth.spec.test.ts",
151+
"check:oidc-test": "nyc mocha --config test/mocha_mongodb.js test/integration/auth/mongodb_oidc.prose.test.ts",
152+
"check:oidc-azure": "nyc mocha --config test/mocha_mongodb.js test/integration/auth/mongodb_oidc_azure.prose.05.test.ts",
153+
"check:oidc-gcp": "nyc mocha --config test/mocha_mongodb.js test/integration/auth/mongodb_oidc_gcp.prose.06.test.ts",
154+
"check:oidc-k8s": "nyc mocha --config test/mocha_mongodb.js test/integration/auth/mongodb_oidc_k8s.prose.07.test.ts",
155155
"check:kerberos": "nyc mocha --config test/manual/mocharc.js test/manual/kerberos.test.ts",
156-
"check:tls": "mocha --config test/manual/mocharc.js test/manual/tls_support.test.ts",
156+
"check:tls": "nyc mocha --config test/manual/mocharc.js test/manual/tls_support.test.ts",
157157
"check:ldap": "nyc mocha --config test/manual/mocharc.js test/manual/ldap.test.ts",
158-
"check:socks5": "mocha --config test/manual/mocharc.js test/manual/socks5.test.ts",
159-
"check:csfle": "mocha --config test/mocha_mongodb.js test/integration/client-side-encryption",
160-
"check:snappy": "mocha test/unit/assorted/snappy.test.js",
161-
"check:x509": "mocha test/manual/x509_auth.test.ts",
158+
"check:socks5": "nyc mocha --config test/manual/mocharc.js test/manual/socks5.test.ts",
159+
"check:csfle": "nyc mocha --config test/mocha_mongodb.js test/integration/client-side-encryption",
160+
"check:snappy": "nyc mocha test/unit/assorted/snappy.test.js",
161+
"check:x509": "nyc mocha test/manual/x509_auth.test.ts",
162162
"fix:eslint": "npm run check:eslint -- --fix",
163163
"prepare": "node etc/prepare.js",
164164
"preview:docs": "ts-node etc/docs/preview.ts",

0 commit comments

Comments
 (0)