public void Should_throw_if_class_contains_completely_the_argument() { attributes["class"] = "foo"; Assert.Throws <NotSupportedException>(() => HtmlAttributesContainerExtensions.ThrowIfClassIsPresent(container.Object, "foo", "bar")); }
public void Should_not_throw_if_class_contains_partially_the_argument() { attributes["class"] = "foos"; Assert.DoesNotThrow(() => HtmlAttributesContainerExtensions.ThrowIfClassIsPresent(container.Object, "foo", "bar")); }
public void Should_not_throw_if_class_is_null() { attributes["class"] = null; Assert.DoesNotThrow(() => HtmlAttributesContainerExtensions.ThrowIfClassIsPresent(container.Object, "foo", "bar")); }