Exemplo n.º 1
0
        public virtual void TestGetters()
        {
            IgnoreRule r = new IgnoreRule("/pattern/");

            NUnit.Framework.Assert.IsFalse(r.GetNameOnly());
            NUnit.Framework.Assert.IsTrue(r.DirOnly());
            NUnit.Framework.Assert.IsFalse(r.GetNegation());
            NUnit.Framework.Assert.AreEqual(r.GetPattern(), "/pattern");
            r = new IgnoreRule("/patter?/");
            NUnit.Framework.Assert.IsFalse(r.GetNameOnly());
            NUnit.Framework.Assert.IsTrue(r.DirOnly());
            NUnit.Framework.Assert.IsFalse(r.GetNegation());
            NUnit.Framework.Assert.AreEqual(r.GetPattern(), "/patter?");
            r = new IgnoreRule("patt*");
            NUnit.Framework.Assert.IsTrue(r.GetNameOnly());
            NUnit.Framework.Assert.IsFalse(r.DirOnly());
            NUnit.Framework.Assert.IsFalse(r.GetNegation());
            NUnit.Framework.Assert.AreEqual(r.GetPattern(), "patt*");
            r = new IgnoreRule("pattern");
            NUnit.Framework.Assert.IsTrue(r.GetNameOnly());
            NUnit.Framework.Assert.IsFalse(r.DirOnly());
            NUnit.Framework.Assert.IsFalse(r.GetNegation());
            NUnit.Framework.Assert.AreEqual(r.GetPattern(), "pattern");
            r = new IgnoreRule("!pattern");
            NUnit.Framework.Assert.IsTrue(r.GetNameOnly());
            NUnit.Framework.Assert.IsFalse(r.DirOnly());
            NUnit.Framework.Assert.IsTrue(r.GetNegation());
            NUnit.Framework.Assert.AreEqual(r.GetPattern(), "pattern");
            r = new IgnoreRule("!/pattern");
            NUnit.Framework.Assert.IsFalse(r.GetNameOnly());
            NUnit.Framework.Assert.IsFalse(r.DirOnly());
            NUnit.Framework.Assert.IsTrue(r.GetNegation());
            NUnit.Framework.Assert.AreEqual(r.GetPattern(), "/pattern");
            r = new IgnoreRule("!/patter?");
            NUnit.Framework.Assert.IsFalse(r.GetNameOnly());
            NUnit.Framework.Assert.IsFalse(r.DirOnly());
            NUnit.Framework.Assert.IsTrue(r.GetNegation());
            NUnit.Framework.Assert.AreEqual(r.GetPattern(), "/patter?");
        }
Exemplo n.º 2
0
		public virtual void TestGetters()
		{
			IgnoreRule r = new IgnoreRule("/pattern/");
			NUnit.Framework.Assert.IsFalse(r.GetNameOnly());
			NUnit.Framework.Assert.IsTrue(r.DirOnly());
			NUnit.Framework.Assert.IsFalse(r.GetNegation());
			NUnit.Framework.Assert.AreEqual(r.GetPattern(), "/pattern");
			r = new IgnoreRule("/patter?/");
			NUnit.Framework.Assert.IsFalse(r.GetNameOnly());
			NUnit.Framework.Assert.IsTrue(r.DirOnly());
			NUnit.Framework.Assert.IsFalse(r.GetNegation());
			NUnit.Framework.Assert.AreEqual(r.GetPattern(), "/patter?");
			r = new IgnoreRule("patt*");
			NUnit.Framework.Assert.IsTrue(r.GetNameOnly());
			NUnit.Framework.Assert.IsFalse(r.DirOnly());
			NUnit.Framework.Assert.IsFalse(r.GetNegation());
			NUnit.Framework.Assert.AreEqual(r.GetPattern(), "patt*");
			r = new IgnoreRule("pattern");
			NUnit.Framework.Assert.IsTrue(r.GetNameOnly());
			NUnit.Framework.Assert.IsFalse(r.DirOnly());
			NUnit.Framework.Assert.IsFalse(r.GetNegation());
			NUnit.Framework.Assert.AreEqual(r.GetPattern(), "pattern");
			r = new IgnoreRule("!pattern");
			NUnit.Framework.Assert.IsTrue(r.GetNameOnly());
			NUnit.Framework.Assert.IsFalse(r.DirOnly());
			NUnit.Framework.Assert.IsTrue(r.GetNegation());
			NUnit.Framework.Assert.AreEqual(r.GetPattern(), "pattern");
			r = new IgnoreRule("!/pattern");
			NUnit.Framework.Assert.IsFalse(r.GetNameOnly());
			NUnit.Framework.Assert.IsFalse(r.DirOnly());
			NUnit.Framework.Assert.IsTrue(r.GetNegation());
			NUnit.Framework.Assert.AreEqual(r.GetPattern(), "/pattern");
			r = new IgnoreRule("!/patter?");
			NUnit.Framework.Assert.IsFalse(r.GetNameOnly());
			NUnit.Framework.Assert.IsFalse(r.DirOnly());
			NUnit.Framework.Assert.IsTrue(r.GetNegation());
			NUnit.Framework.Assert.AreEqual(r.GetPattern(), "/patter?");
		}