Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* text=auto eol=lf
Copy link
Collaborator Author

@timfish timfish Mar 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was key to fixing the Windows line endings snapshot issues.

Without this, git on Windows by default checks out all files with modified line endings!

4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,9 @@
"packages/vite-plugin",
"packages/webpack-plugin",
"packages/integration-tests-next",
"packages/integration-tests-next/fixtures/rolldown"
"packages/integration-tests-next/fixtures/rolldown",
"packages/integration-tests-next/fixtures/rollup3",
"packages/integration-tests-next/fixtures/rollup4"
],
"scripts": {
"postinstall": "patch-package",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
export const sentryConfig = {
telemetry: false,
sourcemaps: {
filesToDeleteAfterUpload: ["out/after-upload-deletion/basic.js.map"],
},
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
export const sentryConfig = {
telemetry: false,
applicationKey: "1234567890abcdef",
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
export const sentryConfig = {
telemetry: false,
release: { create: false, inject: false },
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
export const sentryConfig = {
telemetry: false,
authToken: "fake-auth",
org: "fake-org",
project: "fake-project",
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
export const sentryConfig = {
telemetry: false,
authToken: "fake-auth",
org: "fake-org",
project: "fake-project",
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
export const sentryConfig = {
telemetry: false,
release: {
name: "build-information-injection-test",
},
_experiments: { injectBuildInformation: true },
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
export const sentryConfig = {
telemetry: false,
bundleSizeOptimizations: {
excludeDebugStatements: true,
excludeTracing: true,
excludeReplayCanvas: true,
excludeReplayIframe: true,
excludeReplayShadowDom: true,
excludeReplayWorker: true,
},
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
export const sentryConfig = {
telemetry: false,
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
export const sentryConfig = {
telemetry: false,
reactComponentAnnotation: { enabled: true, _experimentalInjectIntoHtml: true },
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
export const sentryConfig = {
telemetry: false,
reactComponentAnnotation: { enabled: true },
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
export const sentryConfig = {
telemetry: false,
sourcemaps: {
disable: true,
},
release: {
inject: false,
},
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
export const sentryConfig = {
telemetry: false,
// We need to specify these so that upload is attempted. Debug IDs will be injected before then...
authToken: "fake-auth",
org: "fake-org",
project: "fake-project",
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
export const sentryConfig = {
telemetry: false,
moduleMetadata: { something: "value", another: 999 },
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
export const sentryConfig = {
telemetry: false,
release: { inject: false },
};
3 changes: 3 additions & 0 deletions packages/integration-tests-next/fixtures/configs/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"type": "module"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
export const sentryConfig = {
telemetry: false,
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
export const sentryConfig = {
telemetry: false,
authToken: "fake-auth",
org: "fake-org",
project: "fake-project",
release: { create: false },
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import type { SentryRollupPluginOptions } from "@sentry/rollup-plugin";
export declare const sentryConfig: SentryRollupPluginOptions;
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export const sentryConfig = {};
Original file line number Diff line number Diff line change
@@ -1,18 +1,12 @@
import { sentryRollupPlugin } from "@sentry/rollup-plugin";
import { defineConfig } from "rolldown";
import { sentryConfig } from "../configs/after-upload-deletion.config.js";

export default defineConfig({
input: "src/basic.js",
output: {
file: "out/after-upload-deletion/basic.js",
sourcemap: true,
},
plugins: [
sentryRollupPlugin({
telemetry: false,
sourcemaps: {
filesToDeleteAfterUpload: ["out/after-upload-deletion/basic.js.map"],
},
}),
],
plugins: [sentryRollupPlugin(sentryConfig)],
});
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { expect } from "vitest";
import { test } from "./utils";

test(import.meta.url, ({ runRolldown, readOutputFiles, runFileInNode }) => {
runRolldown();
test(import.meta.url, ({ runBundler, readOutputFiles, runFileInNode }) => {
runBundler();
expect(readOutputFiles()).toMatchInlineSnapshot(`
{
"basic.js": "//#region src/basic.js
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import { sentryRollupPlugin } from "@sentry/rollup-plugin";
import { defineConfig } from "rolldown";
import { sentryConfig } from "../configs/application-key.config.js";

export default defineConfig({
input: "src/basic.js",
output: {
file: "out/application-key/basic.js",
},
plugins: [sentryRollupPlugin({ telemetry: false, applicationKey: "1234567890abcdef" })],
plugins: [sentryRollupPlugin(sentryConfig)],
});
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { expect } from "vitest";
import { test } from "./utils";

test(import.meta.url, ({ runRolldown, readOutputFiles }) => {
runRolldown();
test(import.meta.url, ({ runBundler, readOutputFiles }) => {
runBundler();
expect(readOutputFiles()).toMatchInlineSnapshot(`
{
"basic.js": "//#region src/basic.js
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import { sentryRollupPlugin } from "@sentry/rollup-plugin";
import { defineConfig } from "rolldown";
import { sentryConfig } from "../configs/basic-release-disabled.config.js";

export default defineConfig({
input: "src/basic.js",
output: {
file: "out/basic-release-disabled/basic.js",
},
plugins: [sentryRollupPlugin({ telemetry: false, release: { create: false, inject: false } })],
plugins: [sentryRollupPlugin(sentryConfig)],
});
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { expect } from "vitest";
import { test } from "./utils";

test(import.meta.url, ({ runRolldown, readOutputFiles }) => {
runRolldown();
test(import.meta.url, ({ runBundler, readOutputFiles }) => {
runBundler();
expect(readOutputFiles()).toMatchInlineSnapshot(`
{
"basic.js": "//#region src/basic.js
Expand Down
Original file line number Diff line number Diff line change
@@ -1,18 +1,12 @@
import { sentryRollupPlugin } from "@sentry/rollup-plugin";
import { defineConfig } from "rolldown";
import { sentryConfig } from "../configs/basic-sourcemaps.config.js";

export default defineConfig({
input: "src/basic.js",
output: {
file: "out/basic-sourcemaps/basic.js",
sourcemap: true,
},
plugins: [
sentryRollupPlugin({
telemetry: false,
authToken: "fake-auth",
org: "fake-org",
project: "fake-project",
}),
],
plugins: [sentryRollupPlugin(sentryConfig)],
});
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { expect } from "vitest";
import { test } from "./utils";

test(import.meta.url, ({ runRolldown, readOutputFiles, runFileInNode }) => {
runRolldown();
test(import.meta.url, ({ runBundler, readOutputFiles, runFileInNode }) => {
runBundler();
expect(readOutputFiles()).toMatchInlineSnapshot(`
{
"basic.js": "//#region src/basic.js
Expand Down
Original file line number Diff line number Diff line change
@@ -1,17 +1,11 @@
import { sentryRollupPlugin } from "@sentry/rollup-plugin";
import { defineConfig } from "rolldown";
import { sentryConfig } from "../configs/basic.config.js";

export default defineConfig({
input: "src/basic.js",
output: {
file: "out/basic/basic.js",
},
plugins: [
sentryRollupPlugin({
telemetry: false,
authToken: "fake-auth",
org: "fake-org",
project: "fake-project",
}),
],
plugins: [sentryRollupPlugin(sentryConfig)],
});
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { expect } from "vitest";
import { test } from "./utils";

test(import.meta.url, ({ runRolldown, readOutputFiles, runFileInNode }) => {
runRolldown();
test(import.meta.url, ({ runBundler, readOutputFiles, runFileInNode }) => {
runBundler();
expect(readOutputFiles()).toMatchInlineSnapshot(`
{
"basic.js": "//#region src/basic.js
Expand Down
Original file line number Diff line number Diff line change
@@ -1,18 +1,11 @@
import { sentryRollupPlugin } from "@sentry/rollup-plugin";
import { defineConfig } from "rolldown";
import { sentryConfig } from "../configs/build-info.config.js";

export default defineConfig({
input: "src/basic.js",
output: {
file: "out/build-info/basic.js",
},
plugins: [
sentryRollupPlugin({
telemetry: false,
release: {
name: "build-information-injection-test",
},
_experiments: { injectBuildInformation: true },
}),
],
plugins: [sentryRollupPlugin(sentryConfig)],
});
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { expect } from "vitest";
import { test } from "./utils";

test(import.meta.url, ({ runRolldown, readOutputFiles }) => {
runRolldown();
test(import.meta.url, ({ runBundler, readOutputFiles }) => {
runBundler();
expect(readOutputFiles()).toMatchInlineSnapshot(`
{
"basic.js": "//#region src/basic.js
Expand Down
Original file line number Diff line number Diff line change
@@ -1,22 +1,11 @@
import { sentryRollupPlugin } from "@sentry/rollup-plugin";
import { defineConfig } from "rolldown";
import { sentryConfig } from "../configs/bundle-size-optimizations.config.js";

export default defineConfig({
input: "src/bundle.js",
output: {
file: "out/bundle-size-optimizations/bundle.js",
},
plugins: [
sentryRollupPlugin({
telemetry: false,
bundleSizeOptimizations: {
excludeDebugStatements: true,
excludeTracing: true,
excludeReplayCanvas: true,
excludeReplayIframe: true,
excludeReplayShadowDom: true,
excludeReplayWorker: true,
},
}),
],
plugins: [sentryRollupPlugin(sentryConfig)],
});
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { expect } from "vitest";
import { test } from "./utils";

test(import.meta.url, ({ runRolldown, readOutputFiles, runFileInNode }) => {
runRolldown();
test(import.meta.url, ({ runBundler, readOutputFiles, runFileInNode }) => {
runBundler();
expect(readOutputFiles()).toMatchInlineSnapshot(`
{
"bundle.js": "//#region src/bundle.js
Expand Down
Loading
Loading