-
Notifications
You must be signed in to change notification settings - Fork 138
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
8a129d8
commit 5f70ddf
Showing
14 changed files
with
162 additions
and
19,957 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
66 changes: 66 additions & 0 deletions
66
tracer/test/Datadog.Trace.ClrProfiler.IntegrationTests/CI/PipesXUnitEvpTests.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
// <copyright file="PipesXUnitEvpTests.cs" company="Datadog"> | ||
// Unless explicitly stated otherwise all files in this repository are licensed under the Apache 2 License. | ||
// This product includes software developed at Datadog (https://www.datadoghq.com/). Copyright 2017 Datadog, Inc. | ||
// </copyright> | ||
#if NETCOREAPP3_1_OR_GREATER | ||
using System; | ||
using System.Threading.Tasks; | ||
using Xunit; | ||
using Xunit.Abstractions; | ||
|
||
namespace Datadog.Trace.ClrProfiler.IntegrationTests.CI; | ||
|
||
public class PipesXUnitEvpTests(ITestOutputHelper output) : XUnitEvpTests(output) | ||
{ | ||
[SkippableTheory] | ||
[MemberData(nameof(GetData))] | ||
[Trait("Category", "EndToEnd")] | ||
[Trait("Category", "TestIntegrations")] | ||
public override async Task SubmitTraces(string packageVersion, string evpVersionToRemove, bool expectedGzip) | ||
{ | ||
EnvironmentHelper.EnableWindowsNamedPipes(); | ||
|
||
// The server implementation of named pipes is flaky so have 3 attempts | ||
var attemptsRemaining = 3; | ||
while (true) | ||
{ | ||
try | ||
{ | ||
attemptsRemaining--; | ||
await base.SubmitTraces(packageVersion, evpVersionToRemove, expectedGzip); | ||
return; | ||
} | ||
catch (Exception ex) when (attemptsRemaining > 0 && ex is not SkipException) | ||
{ | ||
await ReportRetry(Output, attemptsRemaining, ex); | ||
} | ||
} | ||
} | ||
|
||
[SkippableTheory] | ||
[MemberData(nameof(GetDataForEarlyFlakeDetection))] | ||
[Trait("Category", "EndToEnd")] | ||
[Trait("Category", "TestIntegrations")] | ||
[Trait("Category", "EarlyFlakeDetection")] | ||
public override async Task EarlyFlakeDetection(string packageVersion, string evpVersionToRemove, bool expectedGzip, string settingsJson, string testsJson, int expectedSpans, string friendlyName) | ||
{ | ||
EnvironmentHelper.EnableWindowsNamedPipes(); | ||
|
||
// The server implementation of named pipes is flaky so have 3 attempts | ||
var attemptsRemaining = 3; | ||
while (true) | ||
{ | ||
try | ||
{ | ||
attemptsRemaining--; | ||
await base.EarlyFlakeDetection(packageVersion, evpVersionToRemove, expectedGzip, settingsJson, testsJson, expectedSpans, friendlyName); | ||
return; | ||
} | ||
catch (Exception ex) when (attemptsRemaining > 0 && ex is not SkipException) | ||
{ | ||
await ReportRetry(Output, attemptsRemaining, ex); | ||
} | ||
} | ||
} | ||
} | ||
#endif |
279 changes: 16 additions & 263 deletions
279
tracer/test/Datadog.Trace.ClrProfiler.IntegrationTests/CI/PipesXUnitTests.cs
Large diffs are not rendered by default.
Oops, something went wrong.
35 changes: 35 additions & 0 deletions
35
tracer/test/Datadog.Trace.ClrProfiler.IntegrationTests/CI/TcpXUnitEvpTests.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
// <copyright file="TcpXUnitEvpTests.cs" company="Datadog"> | ||
// Unless explicitly stated otherwise all files in this repository are licensed under the Apache 2 License. | ||
// This product includes software developed at Datadog (https://www.datadoghq.com/). Copyright 2017 Datadog, Inc. | ||
// </copyright> | ||
#if NETCOREAPP3_1_OR_GREATER | ||
using System.Threading.Tasks; | ||
using Xunit; | ||
using Xunit.Abstractions; | ||
|
||
namespace Datadog.Trace.ClrProfiler.IntegrationTests.CI; | ||
|
||
public class TcpXUnitEvpTests(ITestOutputHelper output) : XUnitEvpTests(output) | ||
{ | ||
[SkippableTheory] | ||
[MemberData(nameof(GetData))] | ||
[Trait("Category", "EndToEnd")] | ||
[Trait("Category", "TestIntegrations")] | ||
public override Task SubmitTraces(string packageVersion, string evpVersionToRemove, bool expectedGzip) | ||
{ | ||
EnvironmentHelper.EnableDefaultTransport(); | ||
return base.SubmitTraces(packageVersion, evpVersionToRemove, expectedGzip); | ||
} | ||
|
||
[SkippableTheory] | ||
[MemberData(nameof(GetDataForEarlyFlakeDetection))] | ||
[Trait("Category", "EndToEnd")] | ||
[Trait("Category", "TestIntegrations")] | ||
[Trait("Category", "EarlyFlakeDetection")] | ||
public override Task EarlyFlakeDetection(string packageVersion, string evpVersionToRemove, bool expectedGzip, string settingsJson, string testsJson, int expectedSpans, string friendlyName) | ||
{ | ||
EnvironmentHelper.EnableDefaultTransport(); | ||
return base.EarlyFlakeDetection(packageVersion, evpVersionToRemove, expectedGzip, settingsJson, testsJson, expectedSpans, friendlyName); | ||
} | ||
} | ||
#endif |
25 changes: 25 additions & 0 deletions
25
tracer/test/Datadog.Trace.ClrProfiler.IntegrationTests/CI/TcpXUnitTests.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
// <copyright file="TcpXUnitTests.cs" company="Datadog"> | ||
// Unless explicitly stated otherwise all files in this repository are licensed under the Apache 2 License. | ||
// This product includes software developed at Datadog (https://www.datadoghq.com/). Copyright 2017 Datadog, Inc. | ||
// </copyright> | ||
#if NETCOREAPP3_1_OR_GREATER | ||
using System.Threading.Tasks; | ||
using Xunit; | ||
using Xunit.Abstractions; | ||
|
||
namespace Datadog.Trace.ClrProfiler.IntegrationTests.CI | ||
{ | ||
public class TcpXUnitTests(ITestOutputHelper output) : XUnitTests(output) | ||
{ | ||
[SkippableTheory] | ||
[MemberData(nameof(PackageVersions.XUnit), MemberType = typeof(PackageVersions))] | ||
[Trait("Category", "EndToEnd")] | ||
[Trait("Category", "TestIntegrations")] | ||
public override Task SubmitTraces(string packageVersion) | ||
{ | ||
EnvironmentHelper.EnableDefaultTransport(); | ||
return base.SubmitTraces(packageVersion); | ||
} | ||
} | ||
} | ||
#endif |
Oops, something went wrong.