Skip to content

Commit fa88333

Browse files
committed
dotnet format CA1823
1 parent 84558d1 commit fa88333

File tree

4 files changed

+13
-13
lines changed

4 files changed

+13
-13
lines changed

test/IntegrationTests/AspNetTests.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ public class AspNetTests
1212
{
1313
private const string ServiceName = "TestApplication.AspNet.NetFramework";
1414

15-
private static readonly HttpClient HttpClient = new();
15+
private static readonly HttpClient Client = new();
1616

1717
public AspNetTests(ITestOutputHelper output)
1818
{
@@ -235,16 +235,16 @@ private static string GetTestImageName(AppPoolMode appPoolMode, Gac useGac)
235235

236236
private async Task CallTestApplicationEndpoint(int webPort)
237237
{
238-
HttpClient.DefaultRequestHeaders.Add("Custom-Request-Test-Header1", "Test-Value1");
239-
HttpClient.DefaultRequestHeaders.Add("Custom-Request-Test-Header2", "Test-Value2");
240-
HttpClient.DefaultRequestHeaders.Add("Custom-Request-Test-Header3", "Test-Value3");
238+
Client.DefaultRequestHeaders.Add("Custom-Request-Test-Header1", "Test-Value1");
239+
Client.DefaultRequestHeaders.Add("Custom-Request-Test-Header2", "Test-Value2");
240+
Client.DefaultRequestHeaders.Add("Custom-Request-Test-Header3", "Test-Value3");
241241

242-
var response = await HttpClient.GetAsync(new Uri($"http://localhost:{webPort}")).ConfigureAwait(false);
242+
var response = await Client.GetAsync(new Uri($"http://localhost:{webPort}")).ConfigureAwait(false);
243243
var content = await response.Content.ReadAsStringAsync().ConfigureAwait(false);
244244
Output.WriteLine("MVC Response:");
245245
Output.WriteLine(content);
246246

247-
response = await HttpClient.GetAsync(new Uri($"http://localhost:{webPort}/api/values")).ConfigureAwait(false);
247+
response = await Client.GetAsync(new Uri($"http://localhost:{webPort}/api/values")).ConfigureAwait(false);
248248
content = await response.Content.ReadAsStringAsync().ConfigureAwait(false);
249249
Output.WriteLine("WebApi Response:");
250250
Output.WriteLine(content);

test/IntegrationTests/GraphQLTests.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ namespace IntegrationTests;
1414

1515
public class GraphQLTests : TestHelper
1616
{
17-
private static readonly HttpClient HttpClient = new();
17+
private static readonly HttpClient Client = new();
1818

1919
public GraphQLTests(ITestOutputHelper output)
2020
: base("GraphQL", output)
@@ -156,7 +156,7 @@ private async Task SubmitRequestsAsync(int aspNetCorePort, IEnumerable<RequestIn
156156
{
157157
foreach (var requestInfo in requests)
158158
{
159-
await SubmitRequestAsync(HttpClient, aspNetCorePort, requestInfo).ConfigureAwait(false);
159+
await SubmitRequestAsync(Client, aspNetCorePort, requestInfo).ConfigureAwait(false);
160160
}
161161
}
162162

test/IntegrationTests/Helpers/HealthzHelper.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ namespace IntegrationTests.Helpers;
1111

1212
internal static class HealthzHelper
1313
{
14-
private static readonly HttpClient HttpClient = new();
14+
private static readonly HttpClient Client = new();
1515

1616
public static async Task TestAsync(string healthzUrl, ITestOutputHelper output)
1717
{
@@ -24,7 +24,7 @@ public static async Task TestAsync(string healthzUrl, ITestOutputHelper output)
2424
{
2525
try
2626
{
27-
var response = await HttpClient.GetAsync(new Uri(healthzUrl)).ConfigureAwait(false);
27+
var response = await Client.GetAsync(new Uri(healthzUrl)).ConfigureAwait(false);
2828
if (response.StatusCode == HttpStatusCode.OK)
2929
{
3030
return;

test/IntegrationTests/OwinIISTests.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ namespace IntegrationTests;
1111

1212
public class OwinIISTests
1313
{
14-
private static readonly HttpClient HttpClient = new();
14+
private static readonly HttpClient Client = new();
1515

1616
public OwinIISTests(ITestOutputHelper output)
1717
{
@@ -84,8 +84,8 @@ public async Task SubmitMetrics()
8484

8585
private async Task CallWebEndpoint(int webPort)
8686
{
87-
HttpClient.DefaultRequestHeaders.Add("traceparent", "00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01"); // send a traceparent header to verify that parent span id is propagated
88-
var response = await HttpClient.GetAsync(new Uri($"http://localhost:{webPort}/test/")).ConfigureAwait(false);
87+
Client.DefaultRequestHeaders.Add("traceparent", "00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01"); // send a traceparent header to verify that parent span id is propagated
88+
var response = await Client.GetAsync(new Uri($"http://localhost:{webPort}/test/")).ConfigureAwait(false);
8989
Assert.Equal(System.Net.HttpStatusCode.OK, response.StatusCode);
9090
var content = await response.Content.ReadAsStringAsync().ConfigureAwait(false);
9191
Output.WriteLine("Response:");

0 commit comments

Comments
 (0)