summaryrefslogtreecommitdiff
path: root/test/test_get_abspath.vader
diff options
context:
space:
mode:
Diffstat (limited to 'test/test_get_abspath.vader')
-rw-r--r--test/test_get_abspath.vader15
1 files changed, 15 insertions, 0 deletions
diff --git a/test/test_get_abspath.vader b/test/test_get_abspath.vader
new file mode 100644
index 00000000..2def3773
--- /dev/null
+++ b/test/test_get_abspath.vader
@@ -0,0 +1,15 @@
+Execute(Relative paths should be resolved correctly):
+ AssertEqual
+ \ '/foo/bar/baz/whatever.txt',
+ \ ale#path#GetAbsPath('/foo/bar/xyz', '../baz/whatever.txt')
+ AssertEqual
+ \ '/foo/bar/xyz/whatever.txt',
+ \ ale#path#GetAbsPath('/foo/bar/xyz', './whatever.txt')
+ AssertEqual
+ \ '/foo/bar/xyz/whatever.txt',
+ \ ale#path#GetAbsPath('/foo/bar/xyz', 'whatever.txt')
+
+Execute(Absolute paths should be resolved correctly):
+ AssertEqual
+ \ '/ding/dong',
+ \ ale#path#GetAbsPath('/foo/bar/xyz', '/ding/dong')