mirror of
https://gitee.com/dromara/hutool.git
synced 2025-06-28 13:34:09 +08:00
fix test
This commit is contained in:
parent
1cfd6c7a5c
commit
aa13f98934
@ -516,7 +516,11 @@ public class FileUtilTest {
|
|||||||
final String parseSmbPath = FileUtil.getAbsolutePath(smbPath);
|
final String parseSmbPath = FileUtil.getAbsolutePath(smbPath);
|
||||||
assertEquals(smbPath, parseSmbPath);
|
assertEquals(smbPath, parseSmbPath);
|
||||||
assertTrue(FileUtil.isAbsolutePath(smbPath));
|
assertTrue(FileUtil.isAbsolutePath(smbPath));
|
||||||
assertTrue(Paths.get(smbPath).isAbsolute());
|
if(FileUtil.isWindows()){
|
||||||
|
// 在Windows下`\`路径是绝对路径,也表示SMB路径
|
||||||
|
// 但是在Linux下,`\`表示转义字符,并不被识别为路径
|
||||||
|
assertTrue(Paths.get(smbPath).isAbsolute());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
Loading…
Reference in New Issue
Block a user