Rev 4678: FreeBSD and OSX create temp dirs with the 'wheel' group. in file:///home/vila/src/bzr/bugs/freebsd-regressions/

Vincent Ladeuil v.ladeuil+lp at free.fr
Mon Sep 7 09:46:01 BST 2009


At file:///home/vila/src/bzr/bugs/freebsd-regressions/

------------------------------------------------------------
revno: 4678
revision-id: v.ladeuil+lp at free.fr-20090907084600-g2gheboken7azq5y
parent: v.ladeuil+lp at free.fr-20090907084147-3qejx7c6wx30u8lx
committer: Vincent Ladeuil <v.ladeuil+lp at free.fr>
branch nick: freebsd-regressions
timestamp: Mon 2009-09-07 10:46:00 +0200
message:
  FreeBSD and OSX create temp dirs with the 'wheel' group.
  
  * bzrlib/tests/test_permissions.py:
  (TestPermissions.test_new_files_group_sticky_bit): Same cause,
  same fix.
  
  * bzrlib/tests/per_branch/test_permissions.py:
  (TestPermissions.test_new_branch_group_sticky_bit): Same cause,
  same fix.
-------------- next part --------------
=== modified file 'bzrlib/tests/per_branch/test_permissions.py'
--- a/bzrlib/tests/per_branch/test_permissions.py	2009-03-23 14:59:43 +0000
+++ b/bzrlib/tests/per_branch/test_permissions.py	2009-09-07 08:46:00 +0000
@@ -91,10 +91,10 @@
                                           ' permission logic')
         if sys.platform == 'win32':
             raise tests.TestNotApplicable('chmod has no effect on win32')
-        elif sys.platform == 'darwin':
-            # OS X creates temp dirs with the 'wheel' group, which users are
-            # not likely to be in, and this prevents us from setting the sgid
-            # bit
+        elif sys.platform == 'darwin' or sys.platform.startswith('freebsd'):
+            # OS X (and FreeBSD) create temp dirs with the 'wheel' group, which
+            # users are not likely to be in, and this prevents us from setting
+            # the sgid bit
             os.chown(self.test_dir, os.getuid(), os.getgid())
         # also, these are BzrBranch format specific things..
         t = self.make_branch_and_tree('.')

=== modified file 'bzrlib/tests/test_permissions.py'
--- a/bzrlib/tests/test_permissions.py	2009-03-23 14:59:43 +0000
+++ b/bzrlib/tests/test_permissions.py	2009-09-07 08:46:00 +0000
@@ -140,10 +140,10 @@
     def test_new_files_group_sticky_bit(self):
         if sys.platform == 'win32':
             raise TestSkipped('chmod has no effect on win32')
-        elif sys.platform == 'darwin':
-            # OS X creates temp dirs with the 'wheel' group, which users are
-            # not likely to be in, and this prevents us from setting the sgid
-            # bit
+        elif sys.platform == 'darwin' or sys.platform.startswith('freebsd'):
+            # OS X (and FreeBSD) create temp dirs with the 'wheel' group, which
+            # users are not likely to be in, and this prevents us from setting
+            # the sgid bit
             os.chown(self.test_dir, os.getuid(), os.getgid())
 
         t = self.make_branch_and_tree('.')



More information about the bazaar-commits mailing list