40 references to StringContent
Aspire.Cli.Tests (16)
Agents\AspireSkillsInstallerTests.cs (1)
2180
Content = new
StringContent
(json)
Mcp\ApiDocs\ApiDocsCacheTests.cs (2)
29
Content = new
StringContent
("<urlset></urlset>")
55
Content = new
StringContent
("# Methods")
Mcp\ApiDocs\ApiDocsFetcherTests.cs (3)
30
Content = new
StringContent
(expectedContent)
56
Content = new
StringContent
(expectedContent)
83
Content = new
StringContent
(expectedContent)
Mcp\Docs\DocsCacheTests.cs (1)
28
Content = new
StringContent
("# Content")
Mcp\Docs\DocsFetcherTests.cs (9)
36
Content = new
StringContent
(expectedContent)
55
Content = new
StringContent
("# Content")
77
Content = new
StringContent
(content)
159
Content = new
StringContent
(freshContent)
226
Content = new
StringContent
("")
246
Content = new
StringContent
(whitespace)
329
Content = new
StringContent
(serverContent)
362
Content = new
StringContent
(serverContent)
405
Content = new
StringContent
("# Content")
Aspire.Dashboard.Tests (4)
Telemetry\DashboardTelemetrySenderTests.cs (1)
87
return Task.FromResult(new HttpResponseMessage(telemetryEnabledResponseStatusCode.Value) { Content = new
StringContent
(telemetryEnabledResponseBody ?? string.Empty) });
Telemetry\DashboardTelemetryServiceTests.cs (3)
110
Content = new
StringContent
(JsonSerializer.Serialize(new TelemetryEnabledResponse(IsEnabled: true)) ?? string.Empty)
125
Content = new
StringContent
(JsonSerializer.Serialize(new TelemetryEventCorrelation { Id = userTaskCorrelationId }))
135
Content = new
StringContent
(JsonSerializer.Serialize(new TelemetryEventCorrelation { Id = Guid.NewGuid() }))
Aspire.Hosting.Azure.Tests (4)
AcrLoginServiceTests.cs (4)
27
Content = new
StringContent
("""{"refresh_token":"refresh-token"}""")
53
Content = new
StringContent
("bad request")
75
Content = new
StringContent
("registry not ready")
97
Content = new
StringContent
("registry not ready")
Aspire.Hosting.PostgreSQL.Tests (1)
PostgresFunctionalTests.cs (1)
173
{ new
StringContent
(dbName), "bookmark_id" }
Aspire.Hosting.Tests (1)
WithHttpCommandTests.cs (1)
581
: new
StringContent
(responseBody);
Binding.Http.IntegrationTests (1)
BasicHttpBindingTests.4.0.0.cs (1)
165
message.Content = new
StringContent
(requestMessageBody);
Microsoft.Arcade.Common (1)
ArcadeHttpMessageHandler.cs (1)
34
Content = new
StringContent
($"No response specified in RequestResponses for '({request.Method}) {request.RequestUri}")
Microsoft.AspNetCore.Diagnostics.Middleware.Tests (5)
Logging\AcceptanceTests.cs (5)
216
using var content = new
StringContent
(Content);
380
Content = new
StringContent
(Content)
692
using var content = new
StringContent
(Content);
726
using var content = new
StringContent
(Content);
755
using var content = new
StringContent
("Client: hello!");
Microsoft.Extensions.AI.Evaluation.Safety (1)
ContentSafetyService.cs (1)
416
request.Content = new
StringContent
(payload ?? string.Empty);
Microsoft.Extensions.AI.Integration.Tests (1)
VerbatimHttpHandler.cs (1)
86
return new() { Content = new
StringContent
(_expectedOutput) };
Microsoft.Extensions.AI.OpenAI.Tests (2)
OpenAIHostedFileClientTests.cs (1)
903
Task.FromResult(new HttpResponseMessage(HttpStatusCode.NotFound) { Content = new
StringContent
("{}") });
OpenAIResponseClientTests.cs (1)
6884
return new HttpResponseMessage { Content = new
StringContent
(body) };
Microsoft.Extensions.Http.Diagnostics.Tests (2)
Logging\HttpHeadersReaderTest.cs (2)
131
using var requestContent = new
StringContent
(string.Empty);
140
using var responseContent = new
StringContent
(string.Empty);
Microsoft.NET.Build.Containers (1)
Registry\DefaultManifestOperations.cs (1)
56
HttpContent manifestUploadContent = new
StringContent
(manifestJson);