TestServer.SendAsync(Action<HttpContext>, CancellationToken) 方法

定義

建立、設定、傳送和傳回 HttpContext 。 一旦啟動回應,這就會完成。

public System.Threading.Tasks.Task<Microsoft.AspNetCore.Http.HttpContext> SendAsync (Action<Microsoft.AspNetCore.Http.HttpContext> configureContext, System.Threading.CancellationToken cancellationToken = default);
member this.SendAsync : Action<Microsoft.AspNetCore.Http.HttpContext> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Http.HttpContext>
Public Function SendAsync (configureContext As Action(Of HttpContext), Optional cancellationToken As CancellationToken = Nothing) As Task(Of HttpContext)

參數

configureContext
Action<HttpContext>
cancellationToken
CancellationToken

傳回

Task<HttpContext>

適用於