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.vader22
1 files changed, 18 insertions, 4 deletions
diff --git a/test/test_get_abspath.vader b/test/test_get_abspath.vader
index 5f813804..7e1b5930 100644
--- a/test/test_get_abspath.vader
+++ b/test/test_get_abspath.vader
@@ -1,15 +1,29 @@
Execute(Relative paths should be resolved correctly):
AssertEqual
- \ '/foo/bar/baz/whatever.txt',
+ \ has('win32') ? '\foo\bar\baz\whatever.txt' : '/foo/bar/baz/whatever.txt',
\ ale#path#GetAbsPath('/foo/bar/xyz', '../baz/whatever.txt')
AssertEqual
- \ has('win32') ? '/foo/bar/xyz\whatever.txt' : '/foo/bar/xyz/whatever.txt',
+ \ has('win32') ? '\foo\bar\xyz\whatever.txt' : '/foo/bar/xyz/whatever.txt',
\ ale#path#GetAbsPath('/foo/bar/xyz', './whatever.txt')
AssertEqual
- \ has('win32') ? '/foo/bar/xyz\whatever.txt' : '/foo/bar/xyz/whatever.txt',
+ \ has('win32') ? '\foo\bar\xyz\whatever.txt' : '/foo/bar/xyz/whatever.txt',
\ ale#path#GetAbsPath('/foo/bar/xyz', 'whatever.txt')
+ if has('win32')
+ AssertEqual
+ \ 'C:\foo\bar\baz\whatever.txt',
+ \ ale#path#GetAbsPath('C:\foo\bar\baz\xyz', '../whatever.txt')
+ endif
+
Execute(Absolute paths should be resolved correctly):
AssertEqual
- \ '/ding/dong',
+ \ has('win32') ? '\ding\dong' : '/ding/dong',
\ ale#path#GetAbsPath('/foo/bar/xyz', '/ding/dong')
+
+ AssertEqual
+ \ has('win32') ? '\ding\dong' : '/ding/dong',
+ \ ale#path#GetAbsPath('/foo/bar/xyz', '//ding/dong')
+
+ if has('win32')
+ AssertEqual '\ding', ale#path#GetAbsPath('/foo/bar/xyz', '\\ding')
+ endif