From 9e2cd06dd56cf64e787b7951c889ceda31af7dae Mon Sep 17 00:00:00 2001 From: Ned Batchelder Date: Tue, 24 Nov 2009 21:49:19 -0500 Subject: Don't annotate partial branches with -1, use 'exit' instead. --- coverage/html.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'coverage/html.py') diff --git a/coverage/html.py b/coverage/html.py index 3877c834..fcab6f4a 100644 --- a/coverage/html.py +++ b/coverage/html.py @@ -89,7 +89,13 @@ class HtmlReporter(Reporter): elif self.arcs and lineno in missing_branch_arcs: line_class += c_par n_par += 1 - annotate = " ".join(map(str, missing_branch_arcs[lineno])) + annlines = [] + for b in missing_branch_arcs[lineno]: + if b == -1: + annlines.append("exit") + else: + annlines.append(str(b)) + annotate = " ".join(annlines) elif lineno in analysis.statements: line_class += c_run -- cgit v1.2.1