~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/blackbox/test_locale.py

  • Committer: John Arbash Meinel
  • Date: 2011-05-11 11:35:28 UTC
  • mto: This revision was merged to the branch mainline in revision 5851.
  • Revision ID: john@arbash-meinel.com-20110511113528-qepibuwxicjrbb2h
Break compatibility with python <2.6.

This includes auditing the code for places where we were doing
explicit 'sys.version' checks and removing them as appropriate.

Show diffs side-by-side

added added

removed removed

Lines of Context:
16
16
 
17
17
"""Test that bzr handles locales in a reasonable way"""
18
18
 
19
 
import os
20
19
import sys
21
20
 
22
21
from bzrlib import (
44
43
 
45
44
    def test_log_C(self):
46
45
        self.disable_missing_extensions_warning()
 
46
        # C is not necessarily the default locale, so set both LANG and LC_ALL
 
47
        # explicitly because LC_ALL is preferred on (some?) Linux systems but
 
48
        # only LANG is respected on Windows.
47
49
        out, err = self.run_bzr_subprocess(
48
50
            '--no-aliases --no-plugins log -q --log-format=long tree',
49
 
               env_changes={'LANG':'C', 'BZR_PROGRESS_BAR':'none',
50
 
                            'LC_ALL':None, 'LC_CTYPE':None, 'LANGUAGE':None})
 
51
               env_changes={'LANG': 'C', 'BZR_PROGRESS_BAR':'none',
 
52
                            'LC_ALL': 'C', 'LC_CTYPE':None, 'LANGUAGE':None})
51
53
        self.assertEqual('', err)
52
54
        self.assertEqualDiff("""\
53
55
------------------------------------------------------------