public void ReturnInvalidForInvalidTag() { var element = "<amazon:domain name1=\"bla\" />".ToXElement(); var strategy = new AmazonDomainStrategy(); var errors = strategy.Verify(element); Assert.AreEqual(VerificationState.MissingAttribute, errors.First().State); }
public void ReturnInvalidForInvalidAttributeValue() { var element = "<amazon:domain name=\"InvalidContent\" />".ToXElement(); var strategy = new AmazonDomainStrategy(); var errors = strategy.Verify(element); Assert.AreEqual(VerificationState.InvalidAttributeValue, errors.First().State); }
public void ReturnValidForValidTag() { var element = "<amazon:domain name=\"music\" />".ToXElement(); var strategy = new AmazonDomainStrategy(); var errors = strategy.Verify(element); Assert.AreEqual(0, errors.Count()); }