From 39079d4e848a6ed5fe7b5da00c349a899de18b48 Mon Sep 17 00:00:00 2001 From: Joakim Erdfelt Date: Wed, 25 Jun 2014 15:27:42 -0700 Subject: [PATCH] Tweaking for windows test conditions --- .../eclipse/jetty/util/resource/AbstractFSResourceTest.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/jetty-util/src/test/java/org/eclipse/jetty/util/resource/AbstractFSResourceTest.java b/jetty-util/src/test/java/org/eclipse/jetty/util/resource/AbstractFSResourceTest.java index 62ef4f0e429..c4becbcdb4a 100644 --- a/jetty-util/src/test/java/org/eclipse/jetty/util/resource/AbstractFSResourceTest.java +++ b/jetty-util/src/test/java/org/eclipse/jetty/util/resource/AbstractFSResourceTest.java @@ -33,6 +33,7 @@ import java.net.URI; import java.net.URL; import java.nio.ByteBuffer; import java.nio.channels.ReadableByteChannel; +import java.nio.file.FileSystemException; import java.nio.file.Files; import java.nio.file.InvalidPathException; import java.nio.file.Path; @@ -86,7 +87,7 @@ public abstract class AbstractFSResourceTest } else if (OS.IS_WINDOWS) { - newResource(new URI("file:/dev/null")); + newResource(new URI("file://some\"text\"")); } } @@ -339,7 +340,7 @@ public abstract class AbstractFSResourceTest Files.createFile(foo); Files.createSymbolicLink(bar,foo); } - catch (UnsupportedOperationException e) + catch (UnsupportedOperationException | FileSystemException e) { // if unable to create symlink, no point testing the rest // this is the path that Microsoft Windows takes.