public InlineScriptBundle(string scriptContent) { this.scriptContent = scriptContent; isContentScriptTag = scriptContent != null && DetectScriptRegex.IsMatch(scriptContent, 0); if (isContentScriptTag) { HtmlAttributes.Clear(); } }
public void Can_be_cleared() { var attributes = new HtmlAttributes { { "one", 1 } }; attributes.Count.Should().Be(1); attributes.Clear(); attributes.Count.Should().Be(0); }