diff --git a/mutmut/cache.py b/mutmut/cache.py index f9c2ca20..e0fd9505 100644 --- a/mutmut/cache.py +++ b/mutmut/cache.py @@ -270,7 +270,7 @@ def create_html_report(dict_synonyms): index_file.write('Killed %s out of %s mutants' % (len([x for x in mutants if x.status == OK_KILLED]), len(mutants))) - index_file.write('') + index_file.write('
FileTotalKilled% killedSurvived
') for filename, mutants in groupby(mutants, key=lambda x: x.line.sourcefile.filename): report_filename = join('html', filename) @@ -293,10 +293,11 @@ def create_html_report(dict_synonyms): killed = len(mutants_by_status[OK_KILLED]) f.write('Killed %s out of %s mutants' % (killed, len(mutants))) - index_file.write('' % ( + index_file.write('' % ( filename, filename, len(mutants), + len(mutants_by_status[SKIPPED]), killed, (killed / len(mutants) * 100), len(mutants_by_status[BAD_SURVIVED]), @@ -324,6 +325,11 @@ def print_diffs(status): f.write('Mutants that made the test suite take longer, but otherwise seemed ok') print_diffs(OK_SUSPICIOUS) + if mutants_by_status[SKIPPED]: + f.write('

Skipped

') + f.write('Mutants that were skipped') + print_diffs(SKIPPED) + f.write('') index_file.write('
FileTotalSkippedKilled% killedSurvived
%s%s%s%.2f%s
%s%s%s%s%.2f%s
') diff --git a/tests/test_main.py b/tests/test_main.py index 48194323..c226a02f 100644 --- a/tests/test_main.py +++ b/tests/test_main.py @@ -701,6 +701,6 @@ def test_html_output(surviving_mutants_filesystem): assert f.read() == ( '

Mutation testing report

' 'Killed 0 out of 2 mutants' - '' - '' + '
FileTotalKilled% killedSurvived
foo.py200.002
' + '' '
FileTotalSkippedKilled% killedSurvived
foo.py2000.002
')