toLineCoverage

Generate the html for a line coverage

string
toLineCoverage
(
T
)

Examples

Render line coverage column

LineCoverage("    |").toLineCoverage(1).should.contain([`<span class="line-number">1</span>`, `<span class="hit-count">0</span>`]);
LineCoverage("    |").toLineCoverage(1).should.not.contain(["has-code", `hit"`]);

LineCoverage("    1|code").toLineCoverage(2).should.contain([ `<span class="line-number">2</span>`, `<span class="hit-count">1</span>`, "has-code", `hit"` ]);

Meta