12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 */
23
24 import java.nio.file.*;
25 import java.net.*;
26 import java.util.*;
27 import java.io.IOException;
28
29 /**
30 *
31 * @test
32 * @bug 8038500
33 * @summary Tests path operations for zip provider.
34 */
35
36 public class PathOps {
37
38 static final java.io.PrintStream out = System.out;
39 static FileSystem fs;
40
41 private String input;
42 private Path path;
43 private Exception exc;
44
45 private PathOps(String s) {
46 out.println();
47 input = s;
48 try {
49 path = fs.getPath(s);
50 out.format("%s -> %s", s, path);
51 } catch (Exception x) {
52 exc = x;
53 out.format("%s -> %s", s, x);
|
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 */
23
24 import java.nio.file.*;
25 import java.net.*;
26 import java.util.*;
27 import java.io.IOException;
28
29 /**
30 *
31 * @test
32 * @bug 8038500 8040059
33 * @summary Tests path operations for zip provider.
34 *
35 * @run main PathOps
36 * @run main/othervm/policy=test.policy.readonly PathOps
37 */
38
39 public class PathOps {
40
41 static final java.io.PrintStream out = System.out;
42 static FileSystem fs;
43
44 private String input;
45 private Path path;
46 private Exception exc;
47
48 private PathOps(String s) {
49 out.println();
50 input = s;
51 try {
52 path = fs.getPath(s);
53 out.format("%s -> %s", s, path);
54 } catch (Exception x) {
55 exc = x;
56 out.format("%s -> %s", s, x);
|