Fix how relativePath handle case sensitiviy (#12312) [backport]
This commit is contained in:
parent
6dd4cbc3af
commit
64d5e25821
2 changed files with 6 additions and 2 deletions
|
|
@ -329,6 +329,10 @@ block ospaths:
|
|||
doAssert relativePath("/Users/me/bar/z.nim", "/Users/me", '/') == "bar/z.nim"
|
||||
doAssert relativePath("", "/users/moo", '/') == ""
|
||||
doAssert relativePath("foo", "", '/') == "foo"
|
||||
doAssert relativePath("/foo", "/Foo", '/') == (when FileSystemCaseSensitive: "../foo" else: "")
|
||||
doAssert relativePath("/Foo", "/foo", '/') == (when FileSystemCaseSensitive: "../Foo" else: "")
|
||||
doAssert relativePath("/foo", "/fOO", '/') == (when FileSystemCaseSensitive: "../foo" else: "")
|
||||
doAssert relativePath("/foO", "/foo", '/') == (when FileSystemCaseSensitive: "../foO" else: "")
|
||||
|
||||
doAssert joinPath("usr", "") == unixToNativePath"usr/"
|
||||
doAssert joinPath("", "lib") == "lib"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue