开发者

How to omit using python coverage lib?

I would like to omit some module that are in some particular directory : eggs and bin

coverage -r -i --omit=/usr/lib/,/usr/share/,eggs,bin
Name                                                开发者_StackOverflow社区                 Stmts   Exec  Cover
-----------------------------------------------------------------------------------------
bin/test                                                                5      5   100%
eggs/BeautifulSoup-3.0.7a-py2.6.egg/BeautifulSoup                    1008    463     45%
eggs/Django-1.0.2_final-py2.6.egg/django/__init__                      15     12    80%

I have also try several variant of this without luck :

coverage -r -i --omit=/usr/lib/,/usr/share/,`pwd`/eggs,`pwd`/bin
or
coverage -r -i --omit=/usr/lib/,/usr/share/,django,BeautifulSoup
or 
coverage -r -i --omit=/usr/lib/,/usr/share/,<absolute path>/eggs

It would be great if someone has a tip to get this working.


To tell you the truth, I think this might just be a bug in coverage.py. I'll look into it soon.

UPDATED: OK, I've fixed this bug (I hope), and posted new kits: Coverage.py 3.2b2. Please let me know if it still is no good.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜