internal TeePee(string httpClientNamedInstance, TeePeeMode mode, List <RequestMatch> matches, HttpStatusCode unmatchedStatusCode, string unmatchedBody) { HttpClientNamedInstance = httpClientNamedInstance; HttpHandler = new TeePeeMessageHandler(mode, matches, () => new HttpResponseMessage(unmatchedStatusCode) { Content = unmatchedBody == null ? null : new StringContent(unmatchedBody) }); }
internal TeePeeMessageHandler(TeePeeMode mode, List <RequestMatch> matches, Func <HttpResponseMessage> defaultResponse) { m_Mode = mode; m_Matches = matches; m_DefaultResponse = defaultResponse; }
public TeePeeBuilder(string httpClientNamedInstance = null, TeePeeMode mode = default, JsonSerializerOptions bodySerializeOptions = default) { m_HttpClientNamedInstance = httpClientNamedInstance; m_Mode = mode; m_BodySerializeOptions = bodySerializeOptions ?? s_DefaultSerializeOptions; }