[InlineData("::1", "::1")] // Brackets are added to the host before the comparison public void HostDoesntMatch(string host, string pattern) { Assert.False(HostString.MatchesAny(host, new StringSegment[] { pattern })); }
public void HostMatchThrowsForBadPort() { Assert.Throws <FormatException>(() => HostString.MatchesAny("example.com:1abc", new StringSegment[] { "example.com" })); }
public void HostMatches(string host, string pattern) { Assert.True(HostString.MatchesAny(host, new StringSegment[] { pattern })); }