mirror of
https://github.com/DuendeSoftware/products
synced 2026-05-24 09:28:24 +00:00
The analyser missed this one
This commit is contained in:
parent
bbf40cd2e8
commit
c71bfa2283
1 changed files with 6 additions and 7 deletions
|
|
@ -13,12 +13,11 @@ namespace UnitTests.Endpoints.Results;
|
|||
|
||||
public class EndSessionCallbackResultTests
|
||||
{
|
||||
private EndSessionCallbackHttpWriter _subject;
|
||||
|
||||
private EndSessionCallbackValidationResult _result = new EndSessionCallbackValidationResult();
|
||||
private IdentityServerOptions _options = TestIdentityServerOptions.Create();
|
||||
|
||||
private DefaultHttpContext _context = new DefaultHttpContext();
|
||||
private readonly CancellationToken _ct = TestContext.Current.CancellationToken;
|
||||
private readonly EndSessionCallbackHttpWriter _subject;
|
||||
private readonly EndSessionCallbackValidationResult _result = new EndSessionCallbackValidationResult();
|
||||
private readonly IdentityServerOptions _options = TestIdentityServerOptions.Create();
|
||||
private readonly DefaultHttpContext _context = new DefaultHttpContext();
|
||||
|
||||
public EndSessionCallbackResultTests()
|
||||
{
|
||||
|
|
@ -59,7 +58,7 @@ public class EndSessionCallbackResultTests
|
|||
_context.Response.Headers["X-Content-Security-Policy"].First().ShouldContain("frame-src http://foo.com http://bar.com");
|
||||
_context.Response.Body.Seek(0, SeekOrigin.Begin);
|
||||
using var rdr = new StreamReader(_context.Response.Body);
|
||||
var html = await rdr.ReadToEndAsync();
|
||||
var html = await rdr.ReadToEndAsync(_ct);
|
||||
html.ShouldContain("<iframe loading='eager' allow='' src='http://foo.com'></iframe>");
|
||||
html.ShouldContain("<iframe loading='eager' allow='' src='http://bar.com'></iframe>");
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue