Back to index

python3.2  3.2.2
Public Member Functions
test.test_locale.TestFormatPatternArg Class Reference

List of all members.

Public Member Functions

def test_onlyOnePattern

Detailed Description

Definition at line 229 of file test_locale.py.


Member Function Documentation

Definition at line 232 of file test_locale.py.

00232 
00233     def test_onlyOnePattern(self):
00234         # Issue 2522: accept exactly one % pattern, and no extra chars.
00235         self.assertRaises(ValueError, locale.format, "%f\n", 'foo')
00236         self.assertRaises(ValueError, locale.format, "%f\r", 'foo')
00237         self.assertRaises(ValueError, locale.format, "%f\r\n", 'foo')
00238         self.assertRaises(ValueError, locale.format, " %f", 'foo')
00239         self.assertRaises(ValueError, locale.format, "%fg", 'foo')
00240         self.assertRaises(ValueError, locale.format, "%^g", 'foo')
00241         self.assertRaises(ValueError, locale.format, "%f%%", 'foo')
00242 

Here is the call graph for this function:


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