Skip to content

Commit 6799747

Browse files
committed
small tweaks post rebase
1 parent 90582e6 commit 6799747

File tree

4 files changed

+31
-8
lines changed

4 files changed

+31
-8
lines changed

packages/bundler-plugin-core/src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ function codecovUnpluginFactory({
6161
sentryHub?.captureSession();
6262

6363
let sentEndSession = false; // Just to prevent infinite loops with beforeExit, which is called whenever the event loop empties out
64-
// We also need to manually end sesisons on errors because beforeExit is not called on crashes
64+
// We also need to manually end sessions on errors because beforeExit is not called on crashes
6565
process.on("beforeExit", () => {
6666
if (!sentEndSession) {
6767
sentryHub?.endSession();

packages/bundler-plugin-core/src/utils/__tests__/normalizeOptions.test.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ const tests: Test[] = [
2424
success: true,
2525
options: {
2626
bundleName: "test-bundle",
27+
telemetry: true,
2728
apiUrl: "https://api.codecov.io",
2829
dryRun: false,
2930
retryCount: 3,
@@ -40,6 +41,7 @@ const tests: Test[] = [
4041
dryRun: true,
4142
retryCount: 1,
4243
enableBundleAnalysis: true,
44+
telemetry: false,
4345
uploadToken: "test-token",
4446
uploadOverrides: {
4547
branch: "test-branch",
@@ -58,6 +60,7 @@ const tests: Test[] = [
5860
dryRun: true,
5961
retryCount: 1,
6062
enableBundleAnalysis: true,
63+
telemetry: false,
6164
uploadToken: "test-token",
6265
uploadOverrides: {
6366
branch: "test-branch",

packages/bundler-plugin-core/src/utils/normalizeOptions.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,9 @@ const optionsSchemaFactory = (options: Options) =>
8080
.string({ invalid_type_error: "`uploadToken` must be a string." })
8181
.optional(),
8282
uploadOverrides: UploadOverridesSchema.optional(),
83+
telemetry: z
84+
.boolean({ invalid_type_error: "`telemetry` must be a boolean." })
85+
.default(true),
8386
sentry: z
8487
.object({
8588
sentryOnly: z

pnpm-lock.yaml

Lines changed: 24 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)