Skip to content

Commit 70ed42b

Browse files
authored
Fix MapAction_SingleTimeOnlyParam_StringReturn (#47064)
This test assumes a locale and fails in the Helix queue on other distros.
1 parent d132420 commit 70ed42b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Http/Http.Extensions/test/RequestDelegateGenerator/RequestDelegateGeneratorTests.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ public async Task MapAction_ExplicitQueryParam_StringReturn(string source, strin
106106
public async Task MapAction_SingleTimeOnlyParam_StringReturn()
107107
{
108108
var (results, compilation) = await RunGeneratorAsync("""
109-
app.MapGet("/hello", ([FromQuery]TimeOnly p) => p.ToString());
109+
app.MapGet("/hello", ([FromQuery]TimeOnly p) => p.ToString("o"));
110110
""");
111111
var endpoint = GetEndpointFromCompilation(compilation);
112112

@@ -123,7 +123,7 @@ public async Task MapAction_SingleTimeOnlyParam_StringReturn()
123123
httpContext.Request.QueryString = new QueryString("?p=13:30");
124124

125125
await endpoint.RequestDelegate(httpContext);
126-
await VerifyResponseBodyAsync(httpContext, "1:30 PM");
126+
await VerifyResponseBodyAsync(httpContext, "13:30:00.0000000");
127127
await VerifyAgainstBaselineUsingFile(compilation);
128128
}
129129

0 commit comments

Comments
 (0)