diff --git a/test/Sentry.Profiling.Tests/ProfilingSentryOptionsExtensionsTests.cs b/test/Sentry.Profiling.Tests/ProfilingSentryOptionsExtensionsTests.cs index 3ba7bf3cf6..226e7f5e20 100644 --- a/test/Sentry.Profiling.Tests/ProfilingSentryOptionsExtensionsTests.cs +++ b/test/Sentry.Profiling.Tests/ProfilingSentryOptionsExtensionsTests.cs @@ -2,6 +2,7 @@ namespace Sentry.Profiling.Tests; #nullable enable +[Collection(nameof(ProfilingTestCollection))] public class ProfilingSentryOptionsExtensionsTests { private readonly InMemoryDiagnosticLogger _logger = new(); diff --git a/test/Sentry.Profiling.Tests/ProfilingTestCollection.cs b/test/Sentry.Profiling.Tests/ProfilingTestCollection.cs new file mode 100644 index 0000000000..8c7fdceeb2 --- /dev/null +++ b/test/Sentry.Profiling.Tests/ProfilingTestCollection.cs @@ -0,0 +1,6 @@ +namespace Sentry.Profiling.Tests; + +[CollectionDefinition(nameof(ProfilingTestCollection), DisableParallelization = true)] +public sealed class ProfilingTestCollection +{ +} diff --git a/test/Sentry.Profiling.Tests/SamplingTransactionProfilerTests.cs b/test/Sentry.Profiling.Tests/SamplingTransactionProfilerTests.cs index 1ba4e4f372..25e1841d3e 100644 --- a/test/Sentry.Profiling.Tests/SamplingTransactionProfilerTests.cs +++ b/test/Sentry.Profiling.Tests/SamplingTransactionProfilerTests.cs @@ -6,7 +6,7 @@ namespace Sentry.Profiling.Tests; // Note: we must not run tests in parallel because we only support profiling one transaction at a time. // That means setting up a test-collection with parallelization disabled and NOT using any async test functions. -[CollectionDefinition(nameof(SamplingTransactionProfilerTests), DisableParallelization = true)] +[Collection(nameof(ProfilingTestCollection))] public class SamplingTransactionProfilerTests { private readonly TestOutputDiagnosticLogger _testOutputLogger;