public void GlobalSetup() { _httpContext = new DefaultHttpContext(); _serverTiming = Factory.CreateServerTiming(); _callbacks = Factory.CreateCallbacks(); _middleware = new ServerTimingMiddleware(_ => Task.CompletedTask, new ServerTimingOptions(), null); }
public void GlobalSetup() { _serverTimingOptions = new ServerTimingOptions { InvokeCallbackServices = true }; _serverTimingOptions.WithRequestTimingOptions((_, requestOptions) => requestOptions.WriteHeader = true); _middleware = new ServerTimingMiddleware(_ => Task.CompletedTask, _serverTimingOptions, null); _callbacks = Factory.CreateCallbacks(1); }
public void GlobalSetup() { _httpContext = new DefaultHttpContext(); _serverTiming = Factory.CreateServerTiming(); _serverTimingOptions = new ServerTimingOptions(); _requestTimingOptions = new RequestTimingOptions { WriteHeader = true }; _middleware = new ServerTimingMiddleware(_ => Task.CompletedTask, _serverTimingOptions, null); }