Misc.java revision 2362
2362N/A * Copyright (c) 2008, 2009, Oracle and/or its affiliates. All rights reserved. 893N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 893N/A * This code is free software; you can redistribute it and/or modify it 893N/A * under the terms of the GNU General Public License version 2 only, as 893N/A * published by the Free Software Foundation. 893N/A * This code is distributed in the hope that it will be useful, but WITHOUT 893N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 893N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 893N/A * version 2 for more details (a copy is included in the LICENSE file that 893N/A * accompanied this code). 893N/A * You should have received a copy of the GNU General Public License version 893N/A * 2 along with this work; if not, write to the Free Software Foundation, 893N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 2362N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 2362N/A * or visit www.oracle.com if you need additional information or have any 1577N/A * @bug 4313887 6838333 6867101 893N/A * @summary Unit test for java.nio.file.Path for miscellenous methods not 893N/A * covered by other tests 893N/A // equals and hashCode methods 893N/A // getFileAttributeView methods 893N/A * Exercise equals and hashCode methods 893N/A * Exercise checkAccess method 893N/A * Test: This directory should readable and writable 1476N/A * Test: Check access to all files in all root directories. 1476N/A * (A useful test on Windows for special files such as pagefile.sys) 1476N/A continue;
// skip root directories that aren't accessible 893N/A * Test: File does not exist 893N/A * Test: Edit ACL to deny WRITE and EXECUTE 893N/A // Insert entry to deny WRITE and EXECUTE 893N/A * Test: Windows DOS read-only attribute 893N/A // Read-only attribute does not make direcory read-only 893N/A * Exercise getFileAttributeFile methods 893N/A * Exercise toRealPath method 893N/A * Test: toRealPath(true) will access same file as toRealPath(false) 893N/A * Test: toRealPath(true) should resolve links 893N/A * Test: toRealPath(false) should not resolve links 1319N/A * Test: toRealPath(false) with broken link 893N/A * Test: toRealPath should eliminate "." 893N/A * Test: toRealPath should eliminate ".." when it doesn't follow a 893N/A * Exercise isSameFile method 893N/A * Test: isSameFile for self and null 893N/A * Test: Neither files exist 893N/A * Test: One file exists 893N/A * Test: Both file exists 893N/A * Exercise isHidden method