Exemple #1
0
        public void TRuleDNSBLCondition_BuildXmlElement()
        {
            var testClass = new TRuleDNSBLCondition(GetXmlNode(_xml));

            Assert.AreEqual(TRuleConditionType.DNSBL, testClass.ConditionType);
            Assert.AreEqual("server", testClass.Server);
            Assert.AreEqual("regex", testClass.Regex);
        }
Exemple #2
0
        public void TRuleDNSBLCondition()
        {
            var testClass = new TRuleDNSBLCondition
            {
                Server = "server",
                Regex  = "regex"
            };

            var testXml = ToFormattedXml(testClass);

            Assert.AreEqual(_xml, testXml);
        }