]> git.lyx.org Git - lyx.git/blobdiff - src/support/tests/check_filetools.cpp
Merge branch 'master' of git.lyx.org:lyx
[lyx.git] / src / support / tests / check_filetools.cpp
index 4859f8db1848e5bdab14a63a7577d6ae735d398c..ad657facb100bc63be19600beb70c772e3f55e5f 100644 (file)
@@ -1,4 +1,7 @@
+#include <config.h>
+
 #include "../filetools.h"
+#include "../FileName.h"
 
 #include <iostream>
 
@@ -7,21 +10,11 @@ using namespace lyx::support;
 
 using namespace std;
 
-namespace lyx {
-       docstring const _(string const & s) { return from_ascii(s); }
-}
-
 void test_normalizePath()
 {
-       cout << normalizePath("foo/../bar") << endl;
-       cout << normalizePath("foo/./bar") << endl;
-       cout << normalizePath("./foo/../bar") << endl;
-       cout << normalizePath("./foo/./bar") << endl;
-       cout << normalizePath("/foo/../bar") << endl;
-       cout << normalizePath("/foo/./bar") << endl;
-       cout << normalizePath("foo//bar") << endl;
-       cout << normalizePath("./foo//bar") << endl;
-       cout << normalizePath("/foo//bar") << endl;
+       cout << FileName("/foo/../bar").absFileName() << endl;
+       cout << FileName("/foo/./bar").absFileName() << endl;
+       cout << FileName("/foo//bar").absFileName() << endl;
 }
 
 int main()