Skip to content

Commit e4194ff

Browse files
committed
disable testIsUnreadableTrue() on Windows
1 parent 8260d8f commit e4194ff

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

opengrok-web/src/test/java/org/opengrok/web/PageConfigTest.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1047,6 +1047,8 @@ public String getPathInfo() {
10471047
assertFalse(cfg.isUnreadable());
10481048
}
10491049

1050+
// File.setReadable() does not change the behavior of File.canRead() on Windows.
1051+
@EnabledOnOs({OS.LINUX, OS.MAC, OS.SOLARIS, OS.AIX, OS.OTHER})
10501052
@Test
10511053
void testIsUnreadableTrue() {
10521054
final String relativePath = Path.of("mercurial", "Makefile").toString();
@@ -1057,7 +1059,7 @@ public String getPathInfo() {
10571059
}
10581060
};
10591061

1060-
File file = new File(RuntimeEnvironment.getInstance().getSourceRootPath(), relativePath);
1062+
final File file = new File(RuntimeEnvironment.getInstance().getSourceRootPath(), relativePath);
10611063
assertTrue(file.exists());
10621064
assertTrue(file.setReadable(false, false));
10631065
PageConfig cfg = PageConfig.get(req);

0 commit comments

Comments
 (0)