TestFileSystemManager.cpp
Go to the documentation of this file.00001 00002 // 00003 // This source file is a part of ParCompMark 00004 // Parallel Compositing Benchmark Framework 00005 // 00006 // for latest info see http://parcompmark.sourceforge.net 00007 00008 // 00009 // Copyright (C) 2006 IT2 ParCompMark Dev. Team 00010 // 00011 // This program is free software; you can redistribute it and/or 00012 // modify it under the terms of the GNU General Public License 00013 // as published by the Free Software Foundation; either version 2 00014 // of the License, or (at your option) any later version. 00015 // 00016 // This program is distributed in the hope that it will be useful, 00017 // but WITHOUT ANY WARRANTY; without even the implied warranty of 00018 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00019 // GNU General Public License for more details. 00020 // 00021 // You should have received a copy of the GNU General Public License 00022 // along with this program; if not, write to the Free Software 00023 // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 00024 00027 00028 #include "../include/TestFileSystemManager.h" 00029 00030 namespace ParCompMarkTest 00031 { 00032 00033 void TestFileSystemManager::setUp() 00034 { 00035 } 00036 00037 /*----------------------------------------------------------------------*/ 00038 00039 void TestFileSystemManager::tearDown() 00040 { 00041 } 00042 00043 /*----------------------------------------------------------------------*/ 00044 00045 // 00046 // Constructor & destructor tests 00047 // 00048 00049 void TestFileSystemManager::test_constructor_cstd__string_cstd__string() 00050 { 00051 00052 /* 00053 * You have to verify the following: 00054 * 00055 * Creates file system manager. 00056 */ 00057 00058 CPPUNIT_FAIL("Implement this test!"); 00059 } 00060 00061 /*----------------------------------------------------------------------*/ 00062 00063 void TestFileSystemManager::test_destructor() 00064 { 00065 00066 CPPUNIT_FAIL("Implement this test!"); 00067 } 00068 00069 /*----------------------------------------------------------------------*/ 00070 00071 // 00072 // Class method tests 00073 // 00074 00075 void TestFileSystemManager::test_getInstance() 00076 { 00077 00078 /* 00079 * You have to verify the following: 00080 * 00081 * Gets the instance of the singleton class. Reimplemented for squirrel usage. 00082 */ 00083 00084 CPPUNIT_FAIL("Implement this test!"); 00085 } 00086 00087 /*----------------------------------------------------------------------*/ 00088 00089 void TestFileSystemManager::test_closeFile_FileSystemManager__CppFilePointer() 00090 { 00091 00092 /* 00093 * You have to verify the following: 00094 * 00095 * Close file from fstream object. This method is static to be able to close the logfile. 00096 */ 00097 00098 CPPUNIT_FAIL("Implement this test!"); 00099 } 00100 00101 /*----------------------------------------------------------------------*/ 00102 00103 void TestFileSystemManager::test_closeFile_FileSystemManager__CFilePointer() 00104 { 00105 00106 /* 00107 * You have to verify the following: 00108 * 00109 * Close file from C-style pointer. This method is static to be able to close the logfile. 00110 */ 00111 00112 CPPUNIT_FAIL("Implement this test!"); 00113 } 00114 00115 /*----------------------------------------------------------------------*/ 00116 00117 // 00118 // Method tests 00119 // 00120 00121 void TestFileSystemManager::test_initialize() 00122 { 00123 00124 /* 00125 * You have to verify the following: 00126 * 00127 * Initialize the file system manager. 00128 */ 00129 00130 CPPUNIT_FAIL("Implement this test!"); 00131 } 00132 00133 /*----------------------------------------------------------------------*/ 00134 00135 void TestFileSystemManager::test_finalize() 00136 { 00137 00138 /* 00139 * You have to verify the following: 00140 * 00141 * Finalize the file system manager. 00142 */ 00143 00144 CPPUNIT_FAIL("Implement this test!"); 00145 } 00146 00147 /*----------------------------------------------------------------------*/ 00148 00149 void TestFileSystemManager::test_existsDirectory_cstd__string() 00150 { 00151 00152 /* 00153 * You have to verify the following: 00154 * 00155 * Return true if the specified directory exists. 00156 */ 00157 00158 CPPUNIT_FAIL("Implement this test!"); 00159 } 00160 00161 /*----------------------------------------------------------------------*/ 00162 00163 void TestFileSystemManager::test_createDirectory_cstd__string() 00164 { 00165 00166 /* 00167 * You have to verify the following: 00168 * 00169 * Create directory. 00170 */ 00171 00172 CPPUNIT_FAIL("Implement this test!"); 00173 } 00174 00175 /*----------------------------------------------------------------------*/ 00176 00177 void TestFileSystemManager::test_findDataDirectory() 00178 { 00179 00180 /* 00181 * You have to verify the following: 00182 * 00183 * Find data directory path. Throw exception if not found. 00184 */ 00185 00186 CPPUNIT_FAIL("Implement this test!"); 00187 } 00188 00189 /*----------------------------------------------------------------------*/ 00190 00191 void TestFileSystemManager::test_existsLibrary_cstd__string_cstd__vector___std__string__() 00192 { 00193 00194 /* 00195 * You have to verify the following: 00196 * 00197 * Returns true if the library can be found. 00198 */ 00199 00200 CPPUNIT_FAIL("Implement this test!"); 00201 } 00202 00203 /*----------------------------------------------------------------------*/ 00204 00205 void TestFileSystemManager::test_findLibraryPath_cstd__string_cstd__vector___std__string__() 00206 { 00207 00208 /* 00209 * You have to verify the following: 00210 * 00211 * Find path for library. Throw exception if not found. 00212 */ 00213 00214 CPPUNIT_FAIL("Implement this test!"); 00215 } 00216 00217 /*----------------------------------------------------------------------*/ 00218 00219 void TestFileSystemManager::test_listDirectory_cstd__string() 00220 { 00221 00222 /* 00223 * You have to verify the following: 00224 * 00225 * List files in the specified directory. Throw exception if not found. 00226 */ 00227 00228 CPPUNIT_FAIL("Implement this test!"); 00229 } 00230 00231 /*----------------------------------------------------------------------*/ 00232 00233 void TestFileSystemManager::test_listDataDirectory_cstd__string() 00234 { 00235 00236 /* 00237 * You have to verify the following: 00238 * 00239 * List files in the specified directory relative to the data directory. Throw exception if not found. 00240 */ 00241 00242 CPPUNIT_FAIL("Implement this test!"); 00243 } 00244 00245 /*----------------------------------------------------------------------*/ 00246 00247 void TestFileSystemManager::test_existsFile_cstd__string() 00248 { 00249 00250 /* 00251 * You have to verify the following: 00252 * 00253 * Return true if the specified file exists. 00254 */ 00255 00256 CPPUNIT_FAIL("Implement this test!"); 00257 } 00258 00259 /*----------------------------------------------------------------------*/ 00260 00261 void TestFileSystemManager::test_existsAppFile_cstd__string() 00262 { 00263 00264 /* 00265 * You have to verify the following: 00266 * 00267 * Return true if the specified file exists in the application directory. 00268 */ 00269 00270 CPPUNIT_FAIL("Implement this test!"); 00271 } 00272 00273 /*----------------------------------------------------------------------*/ 00274 00275 void TestFileSystemManager::test_existsDataFile_cchar_p() 00276 { 00277 00278 /* 00279 * You have to verify the following: 00280 * 00281 * Return true if the specified file exists in the data directory. 00282 */ 00283 00284 CPPUNIT_FAIL("Implement this test!"); 00285 } 00286 00287 /*----------------------------------------------------------------------*/ 00288 00289 void TestFileSystemManager::test_openFileC_cstd__string_cFileOperation() 00290 { 00291 00292 /* 00293 * You have to verify the following: 00294 * 00295 * Open file for reading or writing and return a C-style file pointer. 00296 */ 00297 00298 CPPUNIT_FAIL("Implement this test!"); 00299 } 00300 00301 /*----------------------------------------------------------------------*/ 00302 00303 void TestFileSystemManager::test_openAppFileC_cstd__string_cFileOperation() 00304 { 00305 00306 /* 00307 * You have to verify the following: 00308 * 00309 * Open file for reading or writing in the application directory and return a C-style file pointer. 00310 */ 00311 00312 CPPUNIT_FAIL("Implement this test!"); 00313 } 00314 00315 /*----------------------------------------------------------------------*/ 00316 00317 void TestFileSystemManager::test_openDataFileC_cstd__string_cFileOperation() 00318 { 00319 00320 /* 00321 * You have to verify the following: 00322 * 00323 * Open file for reading or writing in the application data directory and return a C-style file pointer. 00324 */ 00325 00326 CPPUNIT_FAIL("Implement this test!"); 00327 } 00328 00329 /*----------------------------------------------------------------------*/ 00330 00331 void TestFileSystemManager::test_openFileCpp_cstd__string_cFileOperation() 00332 { 00333 00334 /* 00335 * You have to verify the following: 00336 * 00337 * Open file for reading or writing and return a fstream object. 00338 */ 00339 00340 CPPUNIT_FAIL("Implement this test!"); 00341 } 00342 00343 /*----------------------------------------------------------------------*/ 00344 00345 void TestFileSystemManager::test_openAppFileCpp_cstd__string_cFileOperation() 00346 { 00347 00348 /* 00349 * You have to verify the following: 00350 * 00351 * Open file for reading or writing in the application directory and return a fstream object. 00352 */ 00353 00354 CPPUNIT_FAIL("Implement this test!"); 00355 } 00356 00357 /*----------------------------------------------------------------------*/ 00358 00359 void TestFileSystemManager::test_openDataFileCpp_cstd__string_cFileOperation() 00360 { 00361 00362 /* 00363 * You have to verify the following: 00364 * 00365 * Open file for reading or writing in the application data directory and return a fstream object. 00366 */ 00367 00368 CPPUNIT_FAIL("Implement this test!"); 00369 } 00370 00371 /*----------------------------------------------------------------------*/ 00372 00373 void TestFileSystemManager::test_getPathDataFile_cstd__string() 00374 { 00375 00376 /* 00377 * You have to verify the following: 00378 * 00379 * Get full path of the specified data file. 00380 */ 00381 00382 CPPUNIT_FAIL("Implement this test!"); 00383 } 00384 00385 /*----------------------------------------------------------------------*/ 00386 00387 void TestFileSystemManager::test_readTextFile_cstd__string() 00388 { 00389 00390 /* 00391 * You have to verify the following: 00392 * 00393 * Read contents of a text file. 00394 */ 00395 00396 CPPUNIT_FAIL("Implement this test!"); 00397 } 00398 00399 /*----------------------------------------------------------------------*/ 00400 00401 void TestFileSystemManager::test_readAppTextFile_cstd__string() 00402 { 00403 00404 /* 00405 * You have to verify the following: 00406 * 00407 * Read contents of a text file in the application directory. 00408 */ 00409 00410 CPPUNIT_FAIL("Implement this test!"); 00411 } 00412 00413 /*----------------------------------------------------------------------*/ 00414 00415 void TestFileSystemManager::test_readDataTextFile_cstd__string() 00416 { 00417 00418 /* 00419 * You have to verify the following: 00420 * 00421 * Read contents of a text file in the application data directory. 00422 */ 00423 00424 CPPUNIT_FAIL("Implement this test!"); 00425 } 00426 00427 /*----------------------------------------------------------------------*/ 00428 00429 void TestFileSystemManager::test__findHomeDirectory() 00430 { 00431 00432 /* 00433 * You have to verify the following: 00434 * 00435 * Find the home directory of the user on the filesystem. 00436 */ 00437 00438 CPPUNIT_FAIL("Implement this test!"); 00439 } 00440 00441 /*----------------------------------------------------------------------*/ 00442 00443 void TestFileSystemManager::test__replaceHomeChar_cstd__string() 00444 { 00445 00446 /* 00447 * You have to verify the following: 00448 * 00449 * Replace '~' char in the specified path string. 00450 */ 00451 00452 CPPUNIT_FAIL("Implement this test!"); 00453 } 00454 00455 /*----------------------------------------------------------------------*/ 00456 00457 void TestFileSystemManager::test__translateToAbsolutePath_cstd__string() 00458 { 00459 00460 /* 00461 * You have to verify the following: 00462 * 00463 * Translate relative path to absolute (also replace '~' char in the specified path string). 00464 * Original code: http://www.codeproject.com/useritems/path_conversion.asp 00465 * 00466 */ 00467 00468 CPPUNIT_FAIL("Implement this test!"); 00469 } 00470 00471 /*----------------------------------------------------------------------*/ 00472 00473 void TestFileSystemManager::test__createAppDirectory() 00474 { 00475 00476 /* 00477 * You have to verify the following: 00478 * 00479 * Create user-level application directory. Do nothing if already exists. 00480 */ 00481 00482 CPPUNIT_FAIL("Implement this test!"); 00483 } 00484 00485 /*----------------------------------------------------------------------*/ 00486 00487 // To register the suite we add: 00489 CPPUNIT_TEST_SUITE_REGISTRATION(TestFileSystemManager); 00490 }