[apparmor] [patch] utils: add python coverage generation

Christian Boltz apparmor at cboltz.de
Sat Oct 25 22:49:12 UTC 2014


Hello,

Am Samstag, 25. Oktober 2014 schrieb Steve Beattie:
> This patch adds support for generating test coverage information for
> the python utils.

Good idea :-)

However...
 
> To generate the coverage data, in the test subdirectory, do:
> 
>   make coverage
> 
> This essentially runs make check, using a single python interpreter,
> and records which lines and branches of the python code were
> exercised.
> 
> To view a text based report, after generating the coverage data, do:
>
>   make coverage-report

Instead of "after generating the coverage data", can't you just use a 
make dependency like
    coverage-report: coverage
    coverage-html: coverage
?

(I noticed that you add coverage to .PHONY, and I understand the reason 
- getting the dependencies 100% correct would be hard[1]. Nevertheless I 
hope that we can use a make dependency for coverage-report and coverage-
html)

Besides this, the patch looks good. 


Regards,

Christian Boltz

[1] hmm - what about   $(wildcard ../aa-* ../apparmor/*.py)   ?
-- 
[Need tool to uncover Rootkits]
Our approach is not to let rootkits enter the system :)
[Marcus Meissner in https://bugzilla.novell.com/show_bug.cgi?id=199078]




More information about the AppArmor mailing list