Index: PEAR_Command_Install/install/test_complex.phpt
===================================================================
RCS file: /repository/pear-core/tests/PEAR_Command_Install/install/test_complex.phpt,v
retrieving revision 1.9
diff -u -r1.9 test_complex.phpt
--- PEAR_Command_Install/install/test_complex.phpt	26 Mar 2007 19:36:57 -0000	1.9
+++ PEAR_Command_Install/install/test_complex.phpt	23 May 2007 19:29:43 -0000
@@ -478,6 +478,8 @@
   ),
 ), $fakelog->getLog(), 'log messages');
 } else {
+    // Don't forget umask ! permission of new file is 0666
+    $umask = decoct(0666 & ( 0777 - umask()));
     $phpunit->assertEquals(array (
       array (
         0 => 3,
@@ -525,7 +527,7 @@
       ),
       array (
         0 => 3,
-        1 => 'adding to transaction: chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo12.php',
+        1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo12.php',
       ),
       array (
         0 => 3,
@@ -541,7 +543,7 @@
       ),
       array (
         0 => 3,
-        1 => '+ chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo12.php',
+        1 => '+ chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo12.php',
       ),
       array (
         0 => 3,
@@ -568,7 +570,7 @@
       ),
       array (
         0 => 3,
-        1 => 'adding to transaction: chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo1.php',
+        1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo1.php',
       ),
       array (
         0 => 3,
@@ -584,7 +586,7 @@
       ),
       array (
         0 => 3,
-        1 => '+ chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo1.php',
+        1 => '+ chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo1.php',
       ),
       array (
         0 => 3,
@@ -607,7 +609,7 @@
       ),
       array (
         0 => 3,
-        1 => 'adding to transaction: chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo.php',
+        1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo.php',
       ),
       array (
         0 => 3,
@@ -623,7 +625,7 @@
       ),
       array (
         0 => 3,
-        1 => '+ chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo.php',
+        1 => '+ chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo.php',
       ),
       array (
         0 => 3,
Index: PEAR_Command_Install/install/test_complex_rest.phpt
===================================================================
RCS file: /repository/pear-core/tests/PEAR_Command_Install/install/test_complex_rest.phpt,v
retrieving revision 1.6
diff -u -r1.6 test_complex_rest.phpt
--- PEAR_Command_Install/install/test_complex_rest.phpt	26 Mar 2007 19:36:57 -0000	1.6
+++ PEAR_Command_Install/install/test_complex_rest.phpt	23 May 2007 19:29:44 -0000
@@ -338,6 +338,8 @@
   ),
 ), $fakelog->getLog(), 'log messages');
 } else {
+    // Don't forget umask ! permission of new file is 0666
+    $umask = decoct(0666 & ( 0777 - umask()));
     $phpunit->assertEquals(array (
       array (
         0 => 3,
@@ -385,7 +387,7 @@
       ),
       array (
         0 => 3,
-        1 => 'adding to transaction: chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo12.php',
+        1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo12.php',
       ),
       array (
         0 => 3,
@@ -401,7 +403,7 @@
       ),
       array (
         0 => 3,
-        1 => '+ chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo12.php',
+        1 => '+ chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo12.php',
       ),
       array (
         0 => 3,
@@ -428,7 +430,7 @@
       ),
       array (
         0 => 3,
-        1 => 'adding to transaction: chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo1.php',
+        1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo1.php',
       ),
       array (
         0 => 3,
@@ -444,7 +446,7 @@
       ),
       array (
         0 => 3,
-        1 => '+ chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo1.php',
+        1 => '+ chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo1.php',
       ),
       array (
         0 => 3,
@@ -467,7 +469,7 @@
       ),
       array (
         0 => 3,
-        1 => 'adding to transaction: chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo.php',
+        1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo.php',
       ),
       array (
         0 => 3,
@@ -483,7 +485,7 @@
       ),
       array (
         0 => 3,
-        1 => '+ chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo.php',
+        1 => '+ chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo.php',
       ),
       array (
         0 => 3,
Index: PEAR_Command_Install/install/test_extinstall.phpt
===================================================================
RCS file: /repository/pear-core/tests/PEAR_Command_Install/install/test_extinstall.phpt,v
retrieving revision 1.6
diff -u -r1.6 test_extinstall.phpt
--- PEAR_Command_Install/install/test_extinstall.phpt	26 Mar 2007 19:36:57 -0000	1.6
+++ PEAR_Command_Install/install/test_extinstall.phpt	23 May 2007 19:29:44 -0000
@@ -478,6 +478,8 @@
       ),
     ), $fakelog->getLog(), 'log messages');
 } else {
+    // Don't forget umask ! permission of new file is 0666
+    $umask = decoct(0666 & ( 0777 - umask()));
     $phpunit->assertEquals(array (
       array (
         0 => 3,
@@ -525,7 +527,7 @@
       ),
       array (
         0 => 3,
-        1 => 'adding to transaction: chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo12.php',
+        1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo12.php',
       ),
       array (
         0 => 3,
@@ -541,7 +543,7 @@
       ),
       array (
         0 => 3,
-        1 => '+ chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo12.php',
+        1 => '+ chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo12.php',
       ),
       array (
         0 => 3,
@@ -568,7 +570,7 @@
       ),
       array (
         0 => 3,
-        1 => 'adding to transaction: chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo1.php',
+        1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo1.php',
       ),
       array (
         0 => 3,
@@ -584,7 +586,7 @@
       ),
       array (
         0 => 3,
-        1 => '+ chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo1.php',
+        1 => '+ chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo1.php',
       ),
       array (
         0 => 3,
@@ -607,7 +609,7 @@
       ),
       array (
         0 => 3,
-        1 => 'adding to transaction: chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo.php',
+        1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo.php',
       ),
       array (
         0 => 3,
@@ -623,7 +625,7 @@
       ),
       array (
         0 => 3,
-        1 => '+ chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo.php',
+        1 => '+ chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php'  . DIRECTORY_SEPARATOR . '.tmpfoo.php',
       ),
       array (
         0 => 3,
Index: PEAR_Command_Install/install/test_installgroup.phpt
===================================================================
RCS file: /repository/pear-core/tests/PEAR_Command_Install/install/test_installgroup.phpt,v
retrieving revision 1.2
diff -u -r1.2 test_installgroup.phpt
--- PEAR_Command_Install/install/test_installgroup.phpt	3 Apr 2007 22:26:04 -0000	1.2
+++ PEAR_Command_Install/install/test_installgroup.phpt	23 May 2007 19:29:44 -0000
@@ -172,6 +172,8 @@
 )
 , $fakelog->getLog(), 'log');
 } else {
+    // Don't forget umask ! permission of new file is 0666
+    $umask = decoct(0666 & ( 0777 - umask()));
     $phpunit->assertEquals(array (
   array (
     0 => 1,
@@ -223,7 +225,7 @@
   11 => 
   array (
     0 => 3,
-    1 => 'adding to transaction: chmod 644 ' . $temp_path . '/php/Console/.tmpGetopt.php',
+    1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . '/php/Console/.tmpGetopt.php',
   ),
   12 => 
   array (
@@ -243,7 +245,7 @@
   15 => 
   array (
     0 => 3,
-    1 => '+ chmod 644 ' . $temp_path . '/php/Console/.tmpGetopt.php',
+    1 => '+ chmod '.$umask.' ' . $temp_path . '/php/Console/.tmpGetopt.php',
   ),
   16 => 
   array (
Index: PEAR_Command_Install/install/test_simple.phpt
===================================================================
RCS file: /repository/pear-core/tests/PEAR_Command_Install/install/test_simple.phpt,v
retrieving revision 1.5
diff -u -r1.5 test_simple.phpt
--- PEAR_Command_Install/install/test_simple.phpt	24 Sep 2006 05:27:22 -0000	1.5
+++ PEAR_Command_Install/install/test_simple.phpt	23 May 2007 19:29:44 -0000
@@ -58,6 +58,8 @@
        ),
     ), $fakelog->getLog(), 'log messages');
 } else {
+    // Don't forget umask ! permission of new file is 0666
+    $umask = decoct(0666 & ( 0777 - umask()));
     $phpunit->assertEquals(array (
       0 => 
       array (
@@ -67,7 +69,7 @@
       1 => 
       array (
         0 => 3,
-        1 => 'adding to transaction: chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
+        1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
       ),
       2 => 
       array (
@@ -87,7 +89,7 @@
       5 => 
       array (
         0 => 3,
-        1 => '+ chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
+        1 => '+ chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
       ),
       6 => 
       array (
Index: PEAR_Command_Install/upgrade/test_bug4060.phpt
===================================================================
RCS file: /repository/pear-core/tests/PEAR_Command_Install/upgrade/test_bug4060.phpt,v
retrieving revision 1.11
diff -u -r1.11 test_bug4060.phpt
--- PEAR_Command_Install/upgrade/test_bug4060.phpt	27 Mar 2007 05:24:33 -0000	1.11
+++ PEAR_Command_Install/upgrade/test_bug4060.phpt	23 May 2007 19:29:46 -0000
@@ -1723,6 +1723,8 @@
       ),
     ), $fakelog->getLog(), 'log messages');
 } else {
+    // Don't forget umask ! permission of new file is 0666
+    $umask = decoct(0666 & ( 0777 - umask()));
     $phpunit->assertEquals(array (
   0 => 
   array (
@@ -1832,7 +1834,7 @@
   21 => 
   array (
     0 => 3,
-    1 => 'adding to transaction: chmod 644 ' . $temp_path . '/test/Auth_HTTP/tests/.tmpsample.sql',
+    1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . '/test/Auth_HTTP/tests/.tmpsample.sql',
   ),
   22 => 
   array (
@@ -1857,7 +1859,7 @@
   26 => 
   array (
     0 => 3,
-    1 => 'adding to transaction: chmod 644 ' . $temp_path . '/test/Auth_HTTP/tests/.tmptest_basic_simple.php',
+    1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . '/test/Auth_HTTP/tests/.tmptest_basic_simple.php',
   ),
   27 => 
   array (
@@ -1882,7 +1884,7 @@
   31 => 
   array (
     0 => 3,
-    1 => 'adding to transaction: chmod 644 ' . $temp_path . '/test/Auth_HTTP/tests/.tmptest_digest_get.php',
+    1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . '/test/Auth_HTTP/tests/.tmptest_digest_get.php',
   ),
   32 => 
   array (
@@ -1907,7 +1909,7 @@
   36 => 
   array (
     0 => 3,
-    1 => 'adding to transaction: chmod 644 ' . $temp_path . '/test/Auth_HTTP/tests/.tmptest_digest_post.php',
+    1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . '/test/Auth_HTTP/tests/.tmptest_digest_post.php',
   ),
   37 => 
   array (
@@ -1932,7 +1934,7 @@
   41 => 
   array (
     0 => 3,
-    1 => 'adding to transaction: chmod 644 ' . $temp_path . '/test/Auth_HTTP/tests/.tmptest_digest_simple.php',
+    1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . '/test/Auth_HTTP/tests/.tmptest_digest_simple.php',
   ),
   42 => 
   array (
@@ -1957,7 +1959,7 @@
   46 => 
   array (
     0 => 3,
-    1 => 'adding to transaction: chmod 644 ' . $temp_path . '/php/Auth/.tmpHTTP.php',
+    1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . '/php/Auth/.tmpHTTP.php',
   ),
   47 => 
   array (
@@ -2067,7 +2069,7 @@
   68 => 
   array (
     0 => 3,
-    1 => '+ chmod 644 ' . $temp_path . '/test/Auth_HTTP/tests/.tmpsample.sql',
+    1 => '+ chmod '.$umask.' ' . $temp_path . '/test/Auth_HTTP/tests/.tmpsample.sql',
   ),
   69 => 
   array (
@@ -2077,7 +2079,7 @@
   70 => 
   array (
     0 => 3,
-    1 => '+ chmod 644 ' . $temp_path . '/test/Auth_HTTP/tests/.tmptest_basic_simple.php',
+    1 => '+ chmod '.$umask.' ' . $temp_path . '/test/Auth_HTTP/tests/.tmptest_basic_simple.php',
   ),
   71 => 
   array (
@@ -2087,7 +2089,7 @@
   72 => 
   array (
     0 => 3,
-    1 => '+ chmod 644 ' . $temp_path . '/test/Auth_HTTP/tests/.tmptest_digest_get.php',
+    1 => '+ chmod '.$umask.' ' . $temp_path . '/test/Auth_HTTP/tests/.tmptest_digest_get.php',
   ),
   73 => 
   array (
@@ -2097,7 +2099,7 @@
   74 => 
   array (
     0 => 3,
-    1 => '+ chmod 644 ' . $temp_path . '/test/Auth_HTTP/tests/.tmptest_digest_post.php',
+    1 => '+ chmod '.$umask.' ' . $temp_path . '/test/Auth_HTTP/tests/.tmptest_digest_post.php',
   ),
   75 => 
   array (
@@ -2107,7 +2109,7 @@
   76 => 
   array (
     0 => 3,
-    1 => '+ chmod 644 ' . $temp_path . '/test/Auth_HTTP/tests/.tmptest_digest_simple.php',
+    1 => '+ chmod '.$umask.' ' . $temp_path . '/test/Auth_HTTP/tests/.tmptest_digest_simple.php',
   ),
   77 => 
   array (
@@ -2117,7 +2119,7 @@
   78 => 
   array (
     0 => 3,
-    1 => '+ chmod 644 ' . $temp_path . '/php/Auth/.tmpHTTP.php',
+    1 => '+ chmod '.$umask.' ' . $temp_path . '/php/Auth/.tmpHTTP.php',
   ),
   79 => 
   array (
Index: PEAR_Installer/test_install_complexlocalpackage_force.phpt
===================================================================
RCS file: /repository/pear-core/tests/PEAR_Installer/test_install_complexlocalpackage_force.phpt,v
retrieving revision 1.7
diff -u -r1.7 test_install_complexlocalpackage_force.phpt
--- PEAR_Installer/test_install_complexlocalpackage_force.phpt	24 Sep 2006 04:09:36 -0000	1.7
+++ PEAR_Installer/test_install_complexlocalpackage_force.phpt	23 May 2007 19:29:56 -0000
@@ -536,6 +536,8 @@
 unset($info['_lastmodified']);
 $phpunit->assertEquals($ret, $info, 'test installation, PEAR1');
 if (!OS_WINDOWS) {
+    // Don't forget umask ! permission of new file is 0666
+    $umask = decoct(0666 & ( 0777 - umask()));
     $phpunit->assertEquals(array (
       0 => 
       array (
@@ -545,7 +547,7 @@
       1 => 
       array (
         0 => 3,
-        1 => 'adding to transaction: chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
+        1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
       ),
       2 => 
       array (
@@ -565,7 +567,7 @@
       5 => 
       array (
         0 => 3,
-        1 => '+ chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
+        1 => '+ chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
       ),
       6 => 
       array (
@@ -619,4 +621,4 @@
 require_once dirname(__FILE__) . '/teardown.php.inc';
 ?>
 --EXPECT--
-tests done
\ No newline at end of file
+tests done
Index: PEAR_Installer/test_install_complexlocalpackage_ignore-errors.phpt
===================================================================
RCS file: /repository/pear-core/tests/PEAR_Installer/test_install_complexlocalpackage_ignore-errors.phpt,v
retrieving revision 1.7
diff -u -r1.7 test_install_complexlocalpackage_ignore-errors.phpt
--- PEAR_Installer/test_install_complexlocalpackage_ignore-errors.phpt	24 Sep 2006 04:09:36 -0000	1.7
+++ PEAR_Installer/test_install_complexlocalpackage_ignore-errors.phpt	23 May 2007 19:29:56 -0000
@@ -569,6 +569,8 @@
       ),
     ), $fakelog->getLog(), 'log');
 } else {
+    // Don't forget umask ! permission of new file is 0666
+    $umask = decoct(0666 & ( 0777 - umask()));
     $phpunit->assertEquals(array (
       0 => 
       array (
@@ -578,7 +580,7 @@
       1 => 
       array (
         0 => 3,
-        1 => 'adding to transaction: chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
+        1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
       ),
       2 => 
       array (
@@ -598,7 +600,7 @@
       5 => 
       array (
         0 => 3,
-        1 => '+ chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
+        1 => '+ chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
       ),
       6 => 
       array (
@@ -619,4 +621,4 @@
 require_once dirname(__FILE__) . '/teardown.php.inc';
 ?>
 --EXPECT--
-tests done
\ No newline at end of file
+tests done
Index: PEAR_Installer/test_install_complexlocalpackage_ignore-errorssoft.phpt
===================================================================
RCS file: /repository/pear-core/tests/PEAR_Installer/test_install_complexlocalpackage_ignore-errorssoft.phpt,v
retrieving revision 1.7
diff -u -r1.7 test_install_complexlocalpackage_ignore-errorssoft.phpt
--- PEAR_Installer/test_install_complexlocalpackage_ignore-errorssoft.phpt	24 Sep 2006 04:09:36 -0000	1.7
+++ PEAR_Installer/test_install_complexlocalpackage_ignore-errorssoft.phpt	23 May 2007 19:29:57 -0000
@@ -556,6 +556,8 @@
       ),
     ), $fakelog->getLog(), 'log');
 } else {
+    // Don't forget umask ! permission of new file is 0666
+    $umask = decoct(0666 & ( 0777 - umask()));
     $phpunit->assertEquals(array (
       0 => 
       array (
@@ -565,7 +567,7 @@
       1 => 
       array (
         0 => 3,
-        1 => 'adding to transaction: chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
+        1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
       ),
       2 => 
       array (
@@ -585,7 +587,7 @@
       5 => 
       array (
         0 => 3,
-        1 => '+ chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
+        1 => '+ chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
       ),
       6 => 
       array (
@@ -606,4 +608,4 @@
 require_once dirname(__FILE__) . '/teardown.php.inc';
 ?>
 --EXPECT--
-tests done
\ No newline at end of file
+tests done
Index: PEAR_Installer/test_install_complexlocalpackage_nodeps.phpt
===================================================================
RCS file: /repository/pear-core/tests/PEAR_Installer/test_install_complexlocalpackage_nodeps.phpt,v
retrieving revision 1.7
diff -u -r1.7 test_install_complexlocalpackage_nodeps.phpt
--- PEAR_Installer/test_install_complexlocalpackage_nodeps.phpt	24 Sep 2006 04:09:36 -0000	1.7
+++ PEAR_Installer/test_install_complexlocalpackage_nodeps.phpt	23 May 2007 19:29:57 -0000
@@ -561,6 +561,8 @@
       ),
     ), $fakelog->getLog(), 'log');
 } else {
+    // Don't forget umask ! permission of new file is 0666
+    $umask = decoct(0666 & ( 0777 - umask()));
     $phpunit->assertEquals(array (
       0 => 
       array (
@@ -570,7 +572,7 @@
       1 => 
       array (
         0 => 3,
-        1 => 'adding to transaction: chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
+        1 => 'adding to transaction: chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
       ),
       2 => 
       array (
@@ -590,7 +592,7 @@
       5 => 
       array (
         0 => 3,
-        1 => '+ chmod 644 ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
+        1 => '+ chmod '.$umask.' ' . $temp_path . DIRECTORY_SEPARATOR . 'php' . DIRECTORY_SEPARATOR . '.tmpfoo.php',
       ),
       6 => 
       array (
@@ -611,4 +613,4 @@
 require_once dirname(__FILE__) . '/teardown.php.inc';
 ?>
 --EXPECT--
-tests done
\ No newline at end of file
+tests done
