Skip to content

Commit

Permalink
Merge pull request #1072 from andersjonsson/develop
Browse files Browse the repository at this point in the history
Update InvalidXMLTests.cs
  • Loading branch information
andersjonsson authored Jun 25, 2024
2 parents d9fdffa + 77c64b5 commit 17b862f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/SoapCore.Tests/InvalidXMLTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ public async Task InvalidSoapActionContentType(string contentType)
SoapSerializer = SoapSerializer.XmlSerializer
};

var soapCore = new SoapEndpointMiddleware<CustomMessage>(logger, _ => Task.CompletedTask, options);
var soapCore = new SoapEndpointMiddleware<CustomMessage>(logger, _ => Task.CompletedTask, options, serviceCollection.BuildServiceProvider());

var context = new DefaultHttpContext();
context.Request.Path = new PathString("/Service.asmx");
Expand All @@ -184,7 +184,7 @@ public async Task InvalidSoapActionContentType(string contentType)
context.Request.Body = new MemoryStream(Encoding.UTF8.GetBytes(request), false);
context.Request.ContentType = contentType;

await soapCore.Invoke(context, serviceCollection.BuildServiceProvider());
await soapCore.Invoke(context);

// Assert
context.Response.Body.Seek(0, SeekOrigin.Begin);
Expand Down

0 comments on commit 17b862f

Please sign in to comment.