GSoC/GCI Archive
Google Code-in 2011 SymPy

Improve the code coverage of the statistics module

completed by: David Ju

mentors: Aaron Meurer, Ondřej Čertík, Hector1618, Stefan Krastanov, Matthew Rocklin, Alexey Gudchenko, Chris Smith, Joachim Durchholz, Vladimir Perić

Please see http://code.google.com/p/sympy/issues/detail?id=2859 for full information on this task. 

 

Please read https://github.com/sympy/sympy/wiki/GCI-2011-Landing before completing any tasks for SymPy. 

 

The task is to increase the test coverage of each file in the statistics directory to at least 90%, according to the ./bin/coverage_report.py utility.  Note that the goal is only 90% because there will be some lines that are uncoverable, or else are very difficult to cover. Higher than 90% is of course better.  You should try to cover each line, though don't worry about it if you have to skip some.

 

One important thing to note for test coverage is that you can test an exception using the raises() function (see the landing page above for an example of this).