Author: mturk
Date: Thu Aug  6 08:48:32 2009
New Revision: 801542

URL: http://svn.apache.org/viewvc?rev=801542&view=rev
Log:
Check for UWRITE instead GWRITE making it independent of umask

Modified:
    
commons/sandbox/runtime/trunk/src/test/org/apache/commons/runtime/TestFile.java

Modified: 
commons/sandbox/runtime/trunk/src/test/org/apache/commons/runtime/TestFile.java
URL: 
http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/test/org/apache/commons/runtime/TestFile.java?rev=801542&r1=801541&r2=801542&view=diff
==============================================================================
--- 
commons/sandbox/runtime/trunk/src/test/org/apache/commons/runtime/TestFile.java 
(original)
+++ 
commons/sandbox/runtime/trunk/src/test/org/apache/commons/runtime/TestFile.java 
Thu Aug  6 08:48:32 2009
@@ -240,8 +240,6 @@
     {
         File f = new File("ffoo");
         f.createNewFile();
-        // Make sure we have GWRITE regardless of default umask
-        f.setFileProtection(EnumSet.of(FileProtection.UWRITE, 
FileProtection.UREAD, FileProtection.GWRITE, FileProtection.GREAD));
         EnumSet <FileProtection> fp = f.getFileProtection();
         System.out.println();
         System.out.println("Org Rdonly Protection " + fp);
@@ -251,7 +249,7 @@
         f.setFileAttributes(EnumSet.noneOf(FileAttributes.class), 
EnumSet.of(FileAttributes.READONLY));
         EnumSet <FileProtection> np = f.getFileProtection();
         System.out.println("Set Rdonly Protection " + np);
-        assertTrue("GWRITE", np.contains(FileProtection.GWRITE));
+        assertTrue("UWRITE", np.contains(FileProtection.UWRITE));
         f.delete();
     }
 


Reply via email to