Skip to content

Commit

Permalink
Improved test code coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
jstedfast committed Aug 26, 2023
1 parent cec6382 commit 155445e
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 0 deletions.
3 changes: 3 additions & 0 deletions UnitTests/Text/HtmlAttributeTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,9 @@ public void TestToHtmlAttributeId ()

Assert.AreEqual (value, parsed, "Failed to parse the HtmlAttributeId value for {0}", value);
}

name = ((HtmlAttributeId) 1024).ToAttributeName ();
Assert.AreEqual ("1024", name, "ToAttributeName() for unknown value");
}
}
}
3 changes: 3 additions & 0 deletions UnitTests/Text/HtmlTagIdTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,9 @@ public void TestToHtmlTagId ()

Assert.AreEqual (value, parsed, "Failed to parse the HtmlTagId value for {0}", value);
}

name = ((HtmlTagId) 1024).ToHtmlTagName ();
Assert.AreEqual ("1024", name, "ToHtmlTagName() for unknown value");
}

[Test]
Expand Down
3 changes: 3 additions & 0 deletions UnitTests/Text/HtmlTokenizerTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,9 @@ public void TestArgumentExceptions ()
Assert.Throws<ArgumentNullException> (() => new HtmlTokenizer ((Stream) null, Encoding.UTF8));

Assert.Throws<ArgumentNullException> (() => new HtmlTokenizer (Stream.Null, null));

var nullTokenizer = new HtmlTokenizer (Stream.Null);
var utf8Tokenizer = new HtmlTokenizer (Stream.Null, Encoding.UTF8);
}

static string Quote (string text)
Expand Down

0 comments on commit 155445e

Please sign in to comment.