MCPcopy Index your code
hub / github.com/python/cpython / test_grouping

Method test_grouping

Lib/test/test_locale.py:167–171  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

165 self.sep = locale.localeconv()['thousands_sep']
166
167 def test_grouping(self):
168 self._test_format_string("%f", 1024, grouping=1, out='1%s024.000000' % self.sep)
169 self._test_format_string("%f", 102, grouping=1, out='102.000000')
170 self._test_format_string("%f", -42, grouping=1, out='-42.000000')
171 self._test_format_string("%+f", -42, grouping=1, out='-42.000000')
172
173 def test_grouping_and_padding(self):
174 self._test_format_string("%20.f", -42, grouping=1, out='-42'.rjust(20))

Callers

nothing calls this directly

Calls 1

_test_format_stringMethod · 0.80

Tested by

no test coverage detected