Back to index

python3.2  3.2.2
Public Member Functions
test.test_random.TestModule Class Reference

List of all members.

Public Member Functions

def testMagicConstants
def test__all__
def test_random_subclass_with_kwargs

Detailed Description

Definition at line 478 of file test_random.py.


Member Function Documentation

Definition at line 485 of file test_random.py.

00485 
00486     def test__all__(self):
00487         # tests validity but not completeness of the __all__ list
00488         self.assertTrue(set(random.__all__) <= set(dir(random)))

Here is the call graph for this function:

Definition at line 489 of file test_random.py.

00489 
00490     def test_random_subclass_with_kwargs(self):
00491         # SF bug #1486663 -- this used to erroneously raise a TypeError
00492         class Subclass(random.Random):
00493             def __init__(self, newarg=None):
00494                 random.Random.__init__(self)
00495         Subclass(newarg=1)
00496 

Here is the call graph for this function:

Definition at line 479 of file test_random.py.

00479 
00480     def testMagicConstants(self):
00481         self.assertAlmostEqual(random.NV_MAGICCONST, 1.71552776992141)
00482         self.assertAlmostEqual(random.TWOPI, 6.28318530718)
00483         self.assertAlmostEqual(random.LOG4, 1.38629436111989)
00484         self.assertAlmostEqual(random.SG_MAGICCONST, 2.50407739677627)

Here is the call graph for this function:


The documentation for this class was generated from the following file: