diff --git a/profiler/test/Datadog.Profiler.IntegrationTests/DebugInfo/GitMetadataTest.cs b/profiler/test/Datadog.Profiler.IntegrationTests/DebugInfo/GitMetadataTest.cs index db666708b770..f219025cc036 100644 --- a/profiler/test/Datadog.Profiler.IntegrationTests/DebugInfo/GitMetadataTest.cs +++ b/profiler/test/Datadog.Profiler.IntegrationTests/DebugInfo/GitMetadataTest.cs @@ -19,7 +19,7 @@ namespace Datadog.Profiler.IntegrationTests.DebugInfo { public class GitMetadataTest { - private const string Scenario = "--scenario 18"; + private const string Scenario = "--scenario 2"; private static readonly Regex GitRepositoryPattern = new("git.repository_url:(?[^,\"]+)", RegexOptions.Compiled | RegexOptions.Multiline | RegexOptions.IgnoreCase); private static readonly Regex GitCommitShaPattern = new("git.commit.sha:(?[^,\"]+)", RegexOptions.Compiled | RegexOptions.Multiline | RegexOptions.IgnoreCase); diff --git a/profiler/test/Datadog.Profiler.Native.Tests/SamplesCollectorTest.cpp b/profiler/test/Datadog.Profiler.Native.Tests/SamplesCollectorTest.cpp index 06db72b9e48e..650a4539a930 100644 --- a/profiler/test/Datadog.Profiler.Native.Tests/SamplesCollectorTest.cpp +++ b/profiler/test/Datadog.Profiler.Native.Tests/SamplesCollectorTest.cpp @@ -271,8 +271,8 @@ TEST(SamplesCollectorTest, MustNotFailWhenSendingProfileThrows) EXPECT_CALL(mockConfiguration, GetUploadInterval()).Times(1).WillOnce(Return(1s)); auto [exporter, mockExporter] = CreateExporter(); - EXPECT_CALL(mockExporter, Add(_)).Times(2); - EXPECT_CALL(mockExporter, Export()).Times(2).WillRepeatedly(Throw(std::exception())); + EXPECT_CALL(mockExporter, Add(_)).Times(AtLeast(1)); + EXPECT_CALL(mockExporter, Export()).Times(AtLeast(1)).WillRepeatedly(Throw(std::exception())); const std::string runtimeId = "MyRid"; FakeSamplesProvider samplesProvider(runtimeId, 1); @@ -285,7 +285,7 @@ TEST(SamplesCollectorTest, MustNotFailWhenSendingProfileThrows) collector.Register(&samplesProvider); collector.Start(); - std::this_thread::sleep_for(70ms); + std::this_thread::sleep_for(1s); collector.Export(); collector.Stop();