40 #ifndef __OPENFLUID_TOOLSTESTS_FILESYSTEMCOMMON_HPP__
41 #define __OPENFLUID_TOOLSTESTS_FILESYSTEMCOMMON_HPP__
44 #include "tests-config.hpp"
51 template<
class A,
class E>
58 template<
class A,
class E>
70 {{
"/my/joined",
"path/myfile.txt"},
"/my/joined/path/myfile.txt"},
71 {{
"/my/joined",
""},
"/my/joined/"},
72 {{
"",
"path/myfile.txt"},
"/path/myfile.txt"},
79 {
"/my/path/myfile.txt",{
"my",
"path",
"myfile.txt"}},
80 {
"/my/path/mydir/mysubdir/",{
"my",
"path",
"mydir",
"mysubdir"}},
81 {
"//my///path////mydir////",{
"my",
"path",
"mydir"}}
87 {
"/my/path1",
"/my/path1/subdir"},
88 {
"/my/path2//",
"/my/path2/subdir"},
89 {
"/my/path3",
"/my/path3/subdir//"},
90 {
"/my/path4",
"/my/path4"},
91 {
"/my/path5/",
"/my/path5"},
92 {
"/my/path6",
"/my/path6/"},
93 {
"/my/path7",
"/my/path7/subdir/subsubdir/subsubsubdir/////"}
101 {
"/my/path1/",
"/my/path1"},
102 {
"/my/path2",
"/my/path2"},
103 {
"/my/path3//",
"/my/path3"},
104 {
"/my/path4///////////////////",
"/my/path4"},
105 {
"my/path5/",
"my/path5"},
106 {
"my/path6",
"my/path6"},
107 {
"my/path7//",
"my/path7"},
108 {
"my/path8///////////////////",
"my/path8"}
112 {{
"c:\\my\\path1",
'\\'},
"c:\\my\\path1"},
113 {{
"c:\\my\\path2\\",
'\\'},
"c:\\my\\path2"},
114 {{
"c:\\my\\path3\\\\\\\\\\",
'\\'},
"c:\\my\\path3"},
115 {{
"c:/my/path4/////",
'/'},
"c:/my/path4"},
116 {{
"my\\path5\\\\\\\\\\",
'\\'},
"my\\path5"},
117 {{
"e:\\\\\\",
'\\'},
"e:\\"},
118 {{
"S:\\\\\\",
'\\'},
"S:\\"}
125 {
"/my/path1",
"/my/path1"},
126 {
"/my/path2/",
"/my/path2/"},
127 {
"/my\\\\path3/",
"/my\\\\path3/"},
128 {
"my\\\\path4/\\\\",
"my\\\\path4/\\\\"}
132 {
"/my/path1",
"/my/path1"},
133 {
"/my/path2/",
"/my/path2"},
134 {
"/my\\\\path3//",
"/my\\\\path3"},
135 {
"my\\\\path4//\\\\",
"my\\\\path4/\\\\"}
139 {
"/my/path1",
"/my/path1"},
140 {
"/my\\\\path2//",
"/my\\\\path2//"},
141 {
"my\\\\path3//\\\\",
"my\\\\path3//\\\\"}
145 {
"/my/path1",
"/my/path1"},
146 {
"/my\\\\path2//",
"/my/path2/"},
147 {
"my\\\\path3//\\\\",
"my/path3/"},
148 {
"a:/my/path4/",
"a:/my/path4/"},
149 {
"A:/my\\\\path5//",
"A:/my/path5/"}
153 {
"/my/path1",
"/my/path1"},
154 {
"/my\\\\path2//",
"/my/path2"},
155 {
"my\\\\path3//\\\\",
"my/path3"},
156 {
"a:/my/path4/",
"a:/my/path4"},
157 {
"A:/my\\\\path5//",
"A:/my/path5"}
161 {
"c:/my/path1",
"c:\\my\\path1"},
162 {
"c:/my\\path2",
"c:\\my\\path2"}
169 {
"/my/path/myfile.txt",{
"myfile.txt",
"/my/path",
"myfile",
"txt",
"myfile",
"txt"}},
170 {
"/my/other/path",{
"path",
"/my/other",
"path",
"",
"path",
""}},
171 {
"/my/path/",{
"",
"/my/path",
"",
"",
"",
""}},
172 {
"/my/path/myarchive.tar.gz",{
"myarchive.tar.gz",
"/my/path",
"myarchive.tar",
"gz",
"myarchive",
"tar.gz"}}
180 {{
"/path/to/directory",
"/path/to"},
"directory"},
181 {{
"/path/to/directory/subdirectory",
"/path/to"},
"directory/subdirectory"}
187 {CONFIGTESTS_BINARY_DIR,
true},
188 {CONFIGTESTS_SRC_DIR+
"/CMakeLists.txt",
false}
192 {CONFIGTESTS_BINARY_DIR,
false},
193 {CONFIGTESTS_SRC_DIR+
"/CMakeLists.txt",
true}
197 {CONFIGTESTS_BINARY_DIR,
true},
198 {CONFIGTESTS_SRC_DIR+
"/CMakeLists.txt",
true},
199 {CONFIGTESTS_SRC_DIR+
"/doesnotexists.txt",
false},
const TestInfoList< std::string, std::string > WinPathsToGenericClean
Definition: FilesystemCommon.hpp:152
const TestInfoList< std::string, std::vector< std::string > > PathsComponents
Definition: FilesystemCommon.hpp:167
const TestInfoList< std::vector< std::string >, std::string > JoinedPaths
Definition: FilesystemCommon.hpp:69
std::vector< A > BoolTestInfoList
Definition: FilesystemCommon.hpp:62
const TestInfoList< std::pair< std::string, char >, std::string > WinPathsWithTrailing
Definition: FilesystemCommon.hpp:111
const TestInfoList< std::string, std::vector< std::string > > SplittedPaths
Definition: FilesystemCommon.hpp:78
const TestInfoList< std::string, bool > ExistsPaths
Definition: FilesystemCommon.hpp:196
const BoolTestInfoList< std::pair< std::string, std::string > > ContainedPaths
Definition: FilesystemCommon.hpp:86
const TestInfoList< std::string, std::string > WinPathsToNative
Definition: FilesystemCommon.hpp:160
const TestInfoList< std::pair< std::string, std::string >, std::string > RelativePaths
Definition: FilesystemCommon.hpp:179
const TestInfoList< std::string, bool > IsFilePaths
Definition: FilesystemCommon.hpp:191
const TestInfoList< std::string, std::string > UnixPathsWithTrailing
Definition: FilesystemCommon.hpp:98
const TestInfoList< std::string, std::string > UnixPathsToGenericClean
Definition: FilesystemCommon.hpp:131
const TestInfoList< std::string, std::string > UnixPathsToGeneric
Definition: FilesystemCommon.hpp:124
const TestInfoList< std::string, bool > IsDirPaths
Definition: FilesystemCommon.hpp:186
const TestInfoList< std::string, std::string > UnixPathsToNative
Definition: FilesystemCommon.hpp:138
const TestInfoList< std::string, std::string > WinPathsToGeneric
Definition: FilesystemCommon.hpp:144
std::vector< TestInfo< A, E > > TestInfoList
Definition: FilesystemCommon.hpp:59
Definition: FilesystemCommon.hpp:53
E Expected
Definition: FilesystemCommon.hpp:55
A Arguments
Definition: FilesystemCommon.hpp:54