public void CheckCorsPopulatedCorrectly() { var headers = new ServerResponseHeaders(); headers.SetCors(CorsHeader.BuildHeader("*")); Assert.AreEqual("*", headers.Cors); headers.SetCors(CorsHeader.BuildHeader("http://localhost:2019/test")); Assert.AreEqual("localhost:2019", headers.Cors); headers.SetCors(CorsHeader.BuildHeader("http://www.google.com")); Assert.AreEqual("www.google.com", headers.Cors); }
static ExceptionHandler() { Headers = new ServerResponseHeaders(); Headers.SetCors(CorsHeader.BuildHeader("*")); }
public VideoController() { Headers.SetCors(CorsHeader.BuildHeader("*")); }