Skip to content

Commit 43040f3

Browse files
author
Brian Burkhalter
committed
8372012: java/nio/file/attribute/BasicFileAttributeView/SetTimesNanos.java should check ability to create links
Reviewed-by: alanb, jpai
1 parent dcba014 commit 43040f3

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

test/jdk/java/nio/file/attribute/BasicFileAttributeView/SetTimesNanos.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2019, 2024, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2019, 2025, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -67,8 +67,10 @@ public static void main(String[] args) throws Exception {
6767
Path file = Files.createFile(dir.resolve("test.dat"));
6868
testNanos(file);
6969

70-
testNanosLink(false);
71-
testNanosLink(true);
70+
if (TestUtil.supportsSymbolicLinks(Path.of(""))) {
71+
testNanosLink(false);
72+
testNanosLink(true);
73+
}
7274
}
7375

7476
private static void testNanos(Path path) throws IOException {

0 commit comments

Comments
 (0)