예제 #1
0
		private static void AssertLowerCaseUpperCase(Mock<INativeElement> elementMock) 
		{
			// LowerCase
			elementMock.Expect(element => element.TagName).Returns("input");
            elementMock.Expect(element => element.GetAttributeValue("type")).Returns("image");

			// UpperCase
			var elementTag = new ElementTag("INPUT", "IMAGE");
			Assert.IsTrue(elementTag.IsMatch(elementMock.Object), "Compare should compare using CultureInvariant");

            elementMock.VerifyAll();
		}
예제 #2
0
        private static void AssertUpperCaseUpperCase(Mock <INativeElement> elementMock)
        {
            // UpperCase
            elementMock.Expect(element => element.TagName).Returns("INPUT");
            elementMock.Expect(element => element.GetAttributeValue("type")).Returns("IMAGE");

            // UpperCase
            var elementTag = new ElementTag("INPUT", "IMAGE");

            Assert.IsTrue(elementTag.IsMatch(elementMock.Object), "Compare should compare using CultureInvariant");

            elementMock.VerifyAll();
        }
예제 #3
0
        private static void AssertUpperCaseLowerCase(Mock <INativeElement> elementMock)
        {
            // UpperCase
            elementMock.Expect(element => element.TagName).Returns("INPUT");
            elementMock.Expect(element => element.GetAttributeValue("type")).Returns("IMAGE");

            // LowerCase
            var elementTag = new ElementTag("input", "image");

            Assert.IsTrue(elementTag.IsMatch(elementMock.Object), "Compare should compare using CultureInvariant");
            Assert.AreEqual("INPUT (image)", elementTag.ToString(), "ToString problem");

            elementMock.VerifyAll();
        }
예제 #4
0
        public void IsMatchNullShouldThrow()
        {
            var elementTag = new ElementTag("tagname");

            elementTag.IsMatch(null);
        }
예제 #5
0
		public void IsMatchNullShouldThrow()
		{
			var elementTag = new ElementTag("tagname");
			elementTag.IsMatch(null);
		}