mirror of
https://github.com/bitwarden/server.git
synced 2025-06-30 07:36:14 -05:00
[PM-5052] Upgrade to .NET 8 (#3461)
* Upgrade to .NET 8 * Linting * Clean up old JSON deserialization code * More .NET 8-oriented linting * Light feedback * Get rid of old test we don't know the root issue for * Fix a new test * Remove now-unnecessary Renovate constraint * Use Any() * Somehow a 6.0 tooling config we don't need snuck back in * Space out properties that always change per release * Bump a few core packages since the last update
This commit is contained in:
@ -35,7 +35,7 @@ public class IdentityApplicationFactory : WebApplicationFactoryBase<Startup>
|
||||
{ "grant_type", "password" },
|
||||
{ "username", username },
|
||||
{ "password", password },
|
||||
}), context => context.Request.Headers.Add("Auth-Email", CoreHelpers.Base64UrlEncodeString(username)));
|
||||
}), context => context.Request.Headers.Append("Auth-Email", CoreHelpers.Base64UrlEncodeString(username)));
|
||||
|
||||
using var body = await AssertHelper.AssertResponseTypeIs<JsonDocument>(context);
|
||||
var root = body.RootElement;
|
||||
|
@ -28,7 +28,7 @@ public static class WebApplicationFactoryExtensions
|
||||
{
|
||||
foreach (var header in content.Headers)
|
||||
{
|
||||
httpContext.Request.Headers.Add(header.Key, new StringValues(header.Value.ToArray()));
|
||||
httpContext.Request.Headers.Append(header.Key, new StringValues(header.Value.ToArray()));
|
||||
}
|
||||
|
||||
httpContext.Request.Body = content.ReadAsStream();
|
||||
@ -64,7 +64,7 @@ public static class WebApplicationFactoryExtensions
|
||||
|
||||
public static HttpContext SetAuthEmail(this HttpContext context, string username)
|
||||
{
|
||||
context.Request.Headers.Add("Auth-Email", CoreHelpers.Base64UrlEncodeString(username));
|
||||
context.Request.Headers.Append("Auth-Email", CoreHelpers.Base64UrlEncodeString(username));
|
||||
return context;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user