Skip to content

Commit 5dbd91e

Browse files
author
José Valim
committed
Merge pull request #2746 from styx/master
Fixes #2744
2 parents 2c17007 + 5b2eb54 commit 5dbd91e

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

lib/elixir/test/elixir/path_test.exs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,12 @@ defmodule PathTest do
3838
assert Path.relative("/usr/local/bin") == "usr/local/bin"
3939
assert Path.relative("usr/local/bin") == "usr/local/bin"
4040
assert Path.relative("../usr/local/bin") == "../usr/local/bin"
41+
42+
assert Path.relative_to("D:/usr/local/foo", "D:/usr/") == "local/foo"
43+
assert Path.relative_to("D:/usr/local/foo", "d:/usr/") == "local/foo"
44+
assert Path.relative_to("d:/usr/local/foo", "D:/usr/") == "local/foo"
45+
assert Path.relative_to("D:/usr/local/foo", "d:") == "usr/local/foo"
46+
assert Path.relative_to("D:/usr/local/foo", "D:") == "usr/local/foo"
4147
end
4248

4349
test :type_win do

0 commit comments

Comments
 (0)