예제 #1
0
            public void ValidDomain()
            {
                UrlFilter filter = new UrlFilter
                {
                    Enabled = true,
                    Whitelist = new List<string>
                    {
                        @"http://www.dws.com.au",
                        @"http://www.google.com"
                    }
                };

                bool result = filter.Test(@"http://www.google.com/Foobar");
                Assert.IsTrue(result);
            }
예제 #2
0
 public void FilterDisabled()
 {
     UrlFilter filter = new UrlFilter { Enabled = false };
     bool result = filter.Test(@"http://www.dws.com.au/Foobar");
     Assert.IsTrue(result);
 }