public FakeHttpRequest AddHeader(IDictionary <string, IEnumerable <string> >?headers) { if (headers?.Count > 0) { foreach (var(key, values) in headers) { Headers.AppendList(key, values.ToList()); } } return(this); }
/// <summary> /// Appends the header name and it's values. /// </summary> /// <param name="name">The header name.</param> /// <param name="values">The header values.</param> public void AppendList <T>(string name, IList <T> values) { Headers.AppendList <T>(name, values); }
public FakeHttpResponse AddHeader(string key, params string[] values) { Headers.AppendList(key, values); return(this); }