~bzr/ubuntu/hardy/bzr/bzr-ppa

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
Description: Fix test of "bzr log" in "C" locale
Author: Jelmer Vernooij <jelmer@samba.org>
Origin: upstream, commit:5629

--- bzr-2.3.0.orig/bzrlib/tests/blackbox/test_locale.py
+++ bzr-2.3.0/bzrlib/tests/blackbox/test_locale.py
@@ -16,7 +16,6 @@
 
 """Test that bzr handles locales in a reasonable way"""
 
-import os
 import sys
 
 from bzrlib import (
@@ -44,10 +43,13 @@ class TestLocale(tests.TestCaseWithTrans
 
     def test_log_C(self):
         self.disable_missing_extensions_warning()
+        # C is not necessarily the default locale, so set both LANG and LC_ALL
+        # explicitly because LC_ALL is preferred on (some?) Linux systems but
+        # only LANG is respected on Windows.
         out, err = self.run_bzr_subprocess(
             '--no-aliases --no-plugins log -q --log-format=long tree',
-               env_changes={'LANG':'C', 'BZR_PROGRESS_BAR':'none',
-                            'LC_ALL':None, 'LC_CTYPE':None, 'LANGUAGE':None})
+               env_changes={'LANG': 'C', 'BZR_PROGRESS_BAR':'none',
+                            'LC_ALL': 'C', 'LC_CTYPE':None, 'LANGUAGE':None})
         self.assertEqual('', err)
         self.assertEqualDiff("""\
 ------------------------------------------------------------