Merge lp:~gz/bzr/trivial_mac_insensitive_glob into lp:bzr

Proposed by Martin Packman
Status: Merged
Approved by: Vincent Ladeuil
Approved revision: no longer in the source branch.
Merged at revision: 5562
Proposed branch: lp:~gz/bzr/trivial_mac_insensitive_glob
Merge into: lp:bzr
Diff against target: 22 lines (+4/-2)
1 file modified
bzrlib/tests/test_win32utils.py (+4/-2)
To merge this branch: bzr merge lp:~gz/bzr/trivial_mac_insensitive_glob
Reviewer Review Type Date Requested Status
Vincent Ladeuil Approve
John A Meinel Approve
Review via email: mp+42978@code.launchpad.net

Commit message

Skip win32utils case insensitive globbing tests on OS X

Description of the change

Refine the skip condition of a couple of win32utils tests so OSX isn't surprised when it runs them and they don't work. In practice, these tests require not only an case-insensitive filesystem, but beyond that working support in os.path itself.

I've not made this into a new feature because something that comes up in one file only isn't refined enough to make into an api, especially when the current check is depending on implementation details of several standard library modules. Nevertheless, it's more accurate than the current.

To post a comment you must log in.
Revision history for this message
John A Meinel (jameinel) wrote :

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 12/7/2010 11:45 AM, Martin [gz] wrote:
> Martin [gz] has proposed merging lp:~gz/bzr/trivial_mac_insensitive_glob into lp:bzr.
>
> Requested reviews:
> bzr-core (bzr-core)
> Related bugs:
> #686595 Windows-specific case insensitive globbing tests fail on Mac OSX
> https://bugs.launchpad.net/bugs/686595
>
>
> Refine the skip condition of a couple of win32utils tests so OSX isn't surprised when it runs them and they don't work. In practice, these tests require not only an case-insensitive filesystem, but beyond that working support in os.path itself.
>
> I've not made this into a new feature because something that comes up in one file only isn't refined enough to make into an api, especially when the current check is depending on implementation details of several standard library modules. Nevertheless, it's more accurate than the current.

 review: approve

John
=:->

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkz+0JMACgkQJdeBCYSNAAMLhgCgtDFCT4Fr1DHWBmYUJWhQnsJ9
EhoAoNIECpstAzkPdiByd2nNlo5L/fB9
=byqi
-----END PGP SIGNATURE-----

review: Approve
Revision history for this message
Vincent Ladeuil (vila) wrote :

Thanks ! You beat me too it :)

This makes sense when reading the cover letter but is a bit terse otherwise. In the long term, we want to be able to test any sort of file system by using in-memory trees, so it's a good thing to keep precise tests (instead of running the whole module on windows only) but we also need to document the details.

So I'll copy some of the cover letter into comments before merging.

review: Approve
Revision history for this message
Vincent Ladeuil (vila) wrote :

Meh, the skip condition documents the point well enough, what crossed my mind ?

Revision history for this message
Vincent Ladeuil (vila) wrote :

sent to pqm by email

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'bzrlib/tests/test_win32utils.py'
2--- bzrlib/tests/test_win32utils.py 2010-06-22 23:58:34 +0000
3+++ bzrlib/tests/test_win32utils.py 2010-12-07 17:45:00 +0000
4@@ -120,7 +120,8 @@
5 ])
6
7 def test_case_insensitive_globbing(self):
8- self.requireFeature(tests.CaseInsCasePresFilenameFeature)
9+ if os.path.normcase("AbC") == "AbC":
10+ self.skip("Test requires case insensitive globbing function")
11 self.build_ascii_tree()
12 self._run_testset([
13 [[u'A'], [u'A']],
14@@ -326,7 +327,8 @@
15 single_quotes_allowed=True)
16
17 def test_case_insensitive_globs(self):
18- self.requireFeature(tests.CaseInsCasePresFilenameFeature)
19+ if os.path.normcase("AbC") == "AbC":
20+ self.skip("Test requires case insensitive globbing function")
21 self.build_tree(['a/', 'a/b.c', 'a/c.c', 'a/c.h'])
22 self.assertCommandLine([u'A/b.c'], 'A/B*')
23