From: Emmanuel Venisse Date: Thu, 26 Apr 2007 14:33:45 +0000 (+0000) Subject: Little fix for windows X-Git-Tag: archiva-1.0-alpha-1~113^2~11 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=b0003019c09dc411daafe611fb22d9650748c001;p=archiva.git Little fix for windows git-svn-id: https://svn.apache.org/repos/asf/maven/archiva/branches/archiva-jpox-database-refactor@532761 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/archiva-base/archiva-common/src/test/java/org/apache/maven/archiva/common/utils/PathUtilTest.java b/archiva-base/archiva-common/src/test/java/org/apache/maven/archiva/common/utils/PathUtilTest.java index a66951511..f74e22114 100644 --- a/archiva-base/archiva-common/src/test/java/org/apache/maven/archiva/common/utils/PathUtilTest.java +++ b/archiva-base/archiva-common/src/test/java/org/apache/maven/archiva/common/utils/PathUtilTest.java @@ -52,6 +52,11 @@ public class PathUtilTest workingDirname = workingDirname.substring( 0, workingDirname.length() - 2 ); } + if ( !workingDirname.startsWith( "/" ) ) + { + workingDirname = "/" + workingDirname; + } + String path = "path/to/resource.xml"; String expectedPath = "file:" + workingDirname + "/" + path; @@ -70,6 +75,11 @@ public class PathUtilTest workingDirname = workingDirname.substring( 0, workingDirname.length() - 2 ); } + if ( !workingDirname.startsWith( "/" ) ) + { + workingDirname = "/" + workingDirname; + } + String path = "path/to/resource.xml"; String expectedPath = "file:" + workingDirname + "/" + path;