Back to index

python3.2  3.2.2
Public Member Functions | Public Attributes | Static Public Attributes
test.test_locale.TestEnUSCollation Class Reference
Inheritance diagram for test.test_locale.TestEnUSCollation:
Inheritance graph
[legend]
Collaboration diagram for test.test_locale.TestEnUSCollation:
Collaboration graph
[legend]

List of all members.

Public Member Functions

def setUp
def test_strcoll_with_diacritic
def test_strxfrm_with_diacritic
def tearDown
def test_strcoll
def test_strxfrm

Public Attributes

 oldlocale

Static Public Attributes

 locale_type = locale.LC_ALL

Detailed Description

Definition at line 350 of file test_locale.py.


Member Function Documentation

Reimplemented from test.test_locale.BaseLocalizedTest.

Definition at line 355 of file test_locale.py.

00355 
00356     def setUp(self):
00357         enc = codecs.lookup(locale.getpreferredencoding(False) or 'ascii').name
00358         if enc not in ('utf-8', 'iso8859-1', 'cp1252'):
00359             raise unittest.SkipTest('encoding not suitable')
00360         if enc != 'iso8859-1' and (sys.platform == 'darwin' or
00361                                    sys.platform.startswith('freebsd')):
00362             raise unittest.SkipTest('wcscoll/wcsxfrm have known bugs')
00363         BaseLocalizedTest.setUp(self)

Here is the call graph for this function:

Here is the caller graph for this function:

def test.test_locale.BaseLocalizedTest.tearDown (   self) [inherited]

Definition at line 49 of file test_locale.py.

00049 
00050     def tearDown(self):
00051         locale.setlocale(self.locale_type, self.oldlocale)
00052 

Here is the call graph for this function:

Here is the caller graph for this function:

def test.test_locale.TestCollation.test_strcoll (   self) [inherited]

Definition at line 341 of file test_locale.py.

00341 
00342     def test_strcoll(self):
00343         self.assertLess(locale.strcoll('a', 'b'), 0)
00344         self.assertEqual(locale.strcoll('a', 'a'), 0)
00345         self.assertGreater(locale.strcoll('b', 'a'), 0)

Here is the call graph for this function:

Definition at line 364 of file test_locale.py.

00364 
00365     def test_strcoll_with_diacritic(self):
00366         self.assertLess(locale.strcoll('à', 'b'), 0)

Here is the call graph for this function:

def test.test_locale.TestCollation.test_strxfrm (   self) [inherited]

Definition at line 346 of file test_locale.py.

00346 
00347     def test_strxfrm(self):
00348         self.assertLess(locale.strxfrm('a'), locale.strxfrm('b'))
00349 

Here is the call graph for this function:

Definition at line 367 of file test_locale.py.

00367 
00368     def test_strxfrm_with_diacritic(self):
00369         self.assertLess(locale.strxfrm('à'), locale.strxfrm('b'))
00370 

Here is the call graph for this function:


Member Data Documentation

Definition at line 353 of file test_locale.py.

Definition at line 44 of file test_locale.py.


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