summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorMark Dickinson <dickinsm@gmail.com>2009-10-24 14:01:08 (GMT)
committerMark Dickinson <dickinsm@gmail.com>2009-10-24 14:01:08 (GMT)
commitda8652d920210a5ff783a7ad30f4c24d2b5ff2a2 (patch)
tree4637c39f07fcd7781d2326c4ec0a11370a089040 /Lib
parent99abd145dc88b1e240e55e34d9a89b7dd2360d2c (diff)
downloadcpython-da8652d920210a5ff783a7ad30f4c24d2b5ff2a2.zip
cpython-da8652d920210a5ff783a7ad30f4c24d2b5ff2a2.tar.gz
cpython-da8652d920210a5ff783a7ad30f4c24d2b5ff2a2.tar.bz2
Issue #7117 (backport py3k float repr) continued:
Add sys.float_repr_style attribute ('short' if short float repr is in used; 'legacy' otherwise).
Diffstat (limited to 'Lib')
-rw-r--r--Lib/test/test_sys.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/test/test_sys.py b/Lib/test/test_sys.py
index 0e364af..1d0e2ef 100644
--- a/Lib/test/test_sys.py
+++ b/Lib/test/test_sys.py
@@ -369,6 +369,8 @@ class SysModuleTest(unittest.TestCase):
self.assertEqual(vi[3], vi.releaselevel)
self.assertEqual(vi[4], vi.serial)
self.assertTrue(vi > (1,0,0))
+ self.assertIsInstance(sys.float_repr_style, str)
+ self.assertTrue(sys.float_repr_style in ('short', 'legacy'))
def test_43581(self):
# Can't use sys.stdout, as this is a cStringIO object when