Hello
That's great. I think it is important to have such tests for any program
and being able to test them AND report this openly is really cool.
I've got a good experience participating in Python software, testing
them with unittest and checking everything in Jenkins. Some of them are
above 95 % in code coverage. I could give you some tips.
First, pylint is already checking pep8 recommendations. It is useless to
run both pep8 and pylint checks.
For tests, it could be a good idea to put them (test_*.py files) in a
separated directories. It will avoid some issues like nose reporting
error for test "nose.failure.Failure.runTest".
Usually you do not need to hack like __import_shinken. Simply set
PYTHONPATH=.. in your tests scripts.
The code coverage reports file in "Shinken-Upstream-Commit-Short-Tests"
and "Shinken-Upstream-Daily-Full-Tests". Obviously this is not what you
intended to do. Running nosetest in the right directory, and using
--cover-package or similar option to nosetest report could simplify this.
Anyway, go on this path! That's cool.
Do you plan to use Gerrit also? Coupled with git(obviously) and Jenkins,
this is great for code quality!
Regards
Aurélien
Le 08/11/2013 16:15, Sébastien Coavoux a écrit :
Hi everyone!
As you may know, Shinken is a test-driven software from the very
beginning. But when a lot of new features are on the roadmap it's hard
to keep a real test phase with a development one.
Today we are pleased to announce you that two new Jenkins dedicated to
Shinken are online! The first one launches a short set of test at
every commit (check every 10 minutes). The second one launches the
full test set every 6 hours.
The link to the jenkins is :
https://test.savoirfairelinux.com/view/Shinken/
The full one performs pep8 and pylint checking for code quality. It
also generates coverage reports that show the cover percent for each
file processed by Jenkins during tests. This way we will be able to
create new tests and cover even more code.
Here is an example of pep8 and pylint coverage per file :
https://test.savoirfairelinux.com/job/Shinken-Upstream-Commit-Short-Tests/violations/file/shinken/comment.py/?
Here is an example of test covering per file :
https://test.savoirfairelinux.com/job/Shinken-Upstream-Commit-Short-Tests/File_coverage/?
Isn't that great? Now you can cleary see which part of the core need
more test and also modules!
For now, there are 500+ tests launched by the full build. Let's
making it bigger!
Want to create new test? Just go on the wiki and follow instructions :
http://www.shinken-monitoring.org/wiki/test_driven_development#add_test_to_shinken
Have fun testing!
Sébastien COAVOUX,
Computer Science Engineer (Network && Systems)
Shinken Development Team Member
GitHub <https://github.com/Seb-Solon> - Twitter
<https://twitter.com/Seb_Cvx> - Linkedin
<http://www.linkedin.com/profile/view?id=86578210>
------------------------------------------------------------------------------
November Webinars for C, C++, Fortran Developers
Accelerate application performance with scalable programming models. Explore
techniques for threading, error checking, porting, and tuning. Get the most
from the latest Intel processors and coprocessors. See abstracts and register
http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk
_______________________________________________
Shinken-devel mailing list
Shinken-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/shinken-devel
------------------------------------------------------------------------------
November Webinars for C, C++, Fortran Developers
Accelerate application performance with scalable programming models. Explore
techniques for threading, error checking, porting, and tuning. Get the most
from the latest Intel processors and coprocessors. See abstracts and register
http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk
_______________________________________________
Shinken-devel mailing list
Shinken-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/shinken-devel