From 11647dd93e7e7177dadad7bcca9d50d6351ac2a9 Mon Sep 17 00:00:00 2001 From: Simon Cropp Date: Thu, 9 Jun 2022 22:31:08 +1000 Subject: [PATCH] . --- ....ProcessEnvelope_ShouldAttachClientReport.verified.txt | 6 +++--- test/Sentry.Tests/Internals/Http/HttpTransportTests.cs | 8 ++------ 2 files changed, 5 insertions(+), 9 deletions(-) diff --git a/test/Sentry.Tests/Internals/Http/HttpTransportTests.ProcessEnvelope_ShouldAttachClientReport.verified.txt b/test/Sentry.Tests/Internals/Http/HttpTransportTests.ProcessEnvelope_ShouldAttachClientReport.verified.txt index 6d79f37bd9..b43daeb50e 100644 --- a/test/Sentry.Tests/Internals/Http/HttpTransportTests.ProcessEnvelope_ShouldAttachClientReport.verified.txt +++ b/test/Sentry.Tests/Internals/Http/HttpTransportTests.ProcessEnvelope_ShouldAttachClientReport.verified.txt @@ -22,13 +22,13 @@ reason: ratelimit_backoff } ], - timestamp: Date_MaxValue + timestamp: DateTime_1 }, eventItemJson: { event_id: Guid_1, platform: csharp, sdk: {}, - sent_at: DateTime_1, - timestamp: DateTime_2 + sent_at: DateTime_2, + timestamp: DateTime_3 } } \ No newline at end of file diff --git a/test/Sentry.Tests/Internals/Http/HttpTransportTests.cs b/test/Sentry.Tests/Internals/Http/HttpTransportTests.cs index 2053ec52c4..a3fffa1187 100644 --- a/test/Sentry.Tests/Internals/Http/HttpTransportTests.cs +++ b/test/Sentry.Tests/Internals/Http/HttpTransportTests.cs @@ -774,16 +774,12 @@ public Task ProcessEnvelope_ShouldAttachClientReport() { var options = new SentryOptions(); - var expectedTimestamp = DateTimeOffset.MaxValue; - var clock = Substitute.For(); - clock.GetUtcNow().Returns(expectedTimestamp); - - var recorder = new ClientReportRecorder(options, clock); + var recorder = new ClientReportRecorder(options); options.ClientReportRecorder = recorder; var logger = Substitute.For(); - var httpTransport = Substitute.For(options, null, clock); + var httpTransport = Substitute.For(options, null, null); // add some fake discards for the report recorder.RecordDiscardedEvent(DiscardReason.NetworkError, DataCategory.Internal);