New submission from Víctor Terrón: I'm attaching a patch to increase the code coverage of the random module to 99% (only one line missing, see issue #17489; it's reported as 89%, however, because of the _test(N=2000) function, which is not executed when the unit tests are run). Many of the new tests, especially gammavariate(), involve mocking Random.random() so that it returns a series of fixed values that guarantee that all the branches of the algorithm are executed — hopefully this has been a good idea!
---------- components: Library (Lib) files: test_random.diff keywords: patch messages: 184728 nosy: mark.dickinson, rhettinger, vterron priority: normal severity: normal status: open title: Increase test coverage for random (up to 99%) type: enhancement versions: Python 3.4 Added file: http://bugs.python.org/file29498/test_random.diff _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue17492> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com