Rev 4643: Merge trunk. in http://bazaar.launchpad.net/~lifeless/bzr/bug-398668
Robert Collins
robertc at robertcollins.net
Tue Aug 18 21:05:39 BST 2009
At http://bazaar.launchpad.net/~lifeless/bzr/bug-398668
------------------------------------------------------------
revno: 4643 [merge]
revision-id: robertc at robertcollins.net-20090818200530-a24ariaq1o0bcvq0
parent: robertc at robertcollins.net-20090818051852-cp8udof6ta6agsuv
parent: pqm at pqm.ubuntu.com-20090818162232-zkwunetmap96ai48
committer: Robert Collins <robertc at robertcollins.net>
branch nick: bug-398668
timestamp: Wed 2009-08-19 06:05:30 +1000
message:
Merge trunk.
modified:
NEWS NEWS-20050323055033-4e00b5db738777ff
bzrlib/revisionspec.py revisionspec.py-20050907152633-17567659fd5c0ddb
bzrlib/tests/__init__.py selftest.py-20050531073622-8d0e3c8845c97a64
bzrlib/tests/blackbox/test_locale.py test_lang.py-20060824204205-80v50j25qkuop7yn-1
=== modified file 'NEWS'
--- a/NEWS 2009-08-18 05:18:52 +0000
+++ b/NEWS 2009-08-18 20:05:30 +0000
@@ -9,6 +9,12 @@
In Development
##############
+Bug Fixes
+*********
+
+* Fix a test failure on karmic by making a locale test more robust.
+ (Vincent Ladeuil, #413514)
+
Improvements
************
=== modified file 'bzrlib/revisionspec.py'
--- a/bzrlib/revisionspec.py 2009-03-23 14:59:43 +0000
+++ b/bzrlib/revisionspec.py 2009-07-25 08:26:42 +0000
@@ -161,9 +161,9 @@
return spectype(spec, _internal=True)
else:
for spectype in SPEC_TYPES:
- trace.mutter('Returning RevisionSpec %s for %s',
- spectype.__name__, spec)
if spec.startswith(spectype.prefix):
+ trace.mutter('Returning RevisionSpec %s for %s',
+ spectype.__name__, spec)
return spectype(spec, _internal=True)
# RevisionSpec_revno is special cased, because it is the only
# one that directly handles plain integers
@@ -185,7 +185,6 @@
called directly. Only from RevisionSpec.from_string()
"""
if not _internal:
- # XXX: Update this after 0.10 is released
symbol_versioning.warn('Creating a RevisionSpec directly has'
' been deprecated in version 0.11. Use'
' RevisionSpec.from_string()'
=== modified file 'bzrlib/tests/__init__.py'
--- a/bzrlib/tests/__init__.py 2009-08-17 17:04:24 +0000
+++ b/bzrlib/tests/__init__.py 2009-08-18 14:20:28 +0000
@@ -2344,7 +2344,7 @@
def _getTestDirPrefix(self):
# create a directory within the top level test directory
- if sys.platform == 'win32':
+ if sys.platform in ('win32', 'cygwin'):
name_prefix = re.sub('[<>*=+",:;_/\\-]', '_', self.id())
# windows is likely to have path-length limits so use a short name
name_prefix = name_prefix[-30:]
@@ -3818,13 +3818,11 @@
try:
osutils.rmtree(dirname)
except OSError, e:
- if sys.platform == 'win32' and e.errno == errno.EACCES:
- sys.stderr.write('Permission denied: '
- 'unable to remove testing dir '
- '%s\n%s'
- % (os.path.basename(dirname), e))
- else:
- raise
+ # We don't want to fail here because some useful display will be lost
+ # otherwise. Polluting the tmp dir is bad, but not giving all the
+ # possible info to the test runner is even worse.
+ sys.stderr.write('Unable to remove testing dir %s\n%s'
+ % (os.path.basename(dirname), e))
class Feature(object):
=== modified file 'bzrlib/tests/blackbox/test_locale.py'
--- a/bzrlib/tests/blackbox/test_locale.py 2009-03-23 14:59:43 +0000
+++ b/bzrlib/tests/blackbox/test_locale.py 2009-08-17 22:16:49 +0000
@@ -61,21 +61,7 @@
'--no-aliases --no-plugins log -q --log-format=long tree',
env_changes={'LANG':'BOGUS', 'BZR_PROGRESS_BAR':'none',
'LC_ALL':None, 'LC_CTYPE':None, 'LANGUAGE':None})
- # XXX: This depends on the exact formatting of a locale.Error
- # as the first part of the string. It may be a little tempermental
- self.assertEqualDiff("""\
-bzr: warning: unsupported locale setting
- bzr could not set the application locale.
- Although this should be no problem for bzr itself,
- it might cause problems with some plugins.
- To investigate the issue, look at the output
- of the locale(1p) tool available on POSIX systems.
-bzr: warning: unsupported locale setting
- Could not determine what text encoding to use.
- This error usually means your Python interpreter
- doesn't support the locale set by $LANG (BOGUS)
- Continuing with ascii encoding.
-""", err)
+ self.assertStartsWith(err, 'bzr: warning: unsupported locale setting')
self.assertEqualDiff("""\
------------------------------------------------------------
revno: 1
More information about the bazaar-commits
mailing list