diff options
author | Ned Batchelder <ned@nedbatchelder.com> | 2009-10-20 11:59:35 -0400 |
---|---|---|
committer | Ned Batchelder <ned@nedbatchelder.com> | 2009-10-20 11:59:35 -0400 |
commit | 7f53916e61839c18b3e06f56e898f1df55afed1d (patch) | |
tree | f39577426803b0cd4661fe732c3d02fb9cce14f3 /coverage/control.py | |
parent | 832ee468e711e6d33fb49fb718e60a85c970a8ef (diff) | |
download | python-coveragepy-git-7f53916e61839c18b3e06f56e898f1df55afed1d.tar.gz |
More exception flow testing. This stuff is kind of involved...
Diffstat (limited to 'coverage/control.py')
-rw-r--r-- | coverage/control.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/coverage/control.py b/coverage/control.py index 5e857aa6..da773d3e 100644 --- a/coverage/control.py +++ b/coverage/control.py @@ -384,5 +384,8 @@ class Analysis: def arcs_unpredicted(self): possible = self.arc_possibilities() executed = self.arcs_executed() - unpredicted = [e for e in executed if e not in possible] + # Exclude arcs here which connect a line to itself. They can occur + # in executed data in some cases. This is where they can cause trouble, + # and here is where it's the least burden to remove them. + unpredicted = [e for e in executed if e not in possible and e[0] != e[1]] return sorted(unpredicted) |