Issue #12345: Add mathemathcal constant tau to math and cmath.

Patch by Lisa Roach. See also PEP 628.
This commit is contained in:
Guido van Rossum 2016-08-15 09:12:52 -07:00
parent 6349612a8e
commit 0a891d70de
7 changed files with 23 additions and 2 deletions

View file

@ -196,6 +196,7 @@ class MathTests(unittest.TestCase):
def testConstants(self):
self.ftest('pi', math.pi, 3.1415926)
self.ftest('e', math.e, 2.7182818)
self.assertEqual(math.tau, 2*math.pi)
def testAcos(self):
self.assertRaises(TypeError, math.acos)