1
0
mirror of https://github.com/rwengine/openrw.git synced 2024-11-01 16:32:31 +01:00
Commit Graph

14 Commits

Author SHA1 Message Date
Anonymous Maarten
0f2cacd35a rwtests: fix FileIndex test on Windows 2018-08-17 03:31:29 +02:00
Filip Gawin
27333efd8c Remove unneed FileHandle (aka shared_ptr) 2018-08-06 22:42:09 +02:00
Anonymous Maarten
8aee672466 rwlib: refactor FileIndex
- make FileIndex const correct (std::map::operator[] modifies the std::map)
- use a single map
- keys are paths relative in the game data directory + filenames
  (so paths like "data/main.scm" can be found twice in the map)
- normalization of the file paths is done inside FileIndex,
  so there shouldn't be any ::tolower's anymore.
- added a normalizer helper function "normalizeFilePath"
- added Documentation
2018-06-30 04:03:20 +02:00
Anonymous Maarten
21c722f7cc run_tests: fix 'Type has to implement operator<< to be printable' (MSVC compiler)
fixes:
error C2338: Type has to implement operator<< to be printable
error C2679: binary '<<': no operator found which takes a right-hand
operand of type 'const boost::filesystem::path::string_type' (or there
is no acceptable conversion)
2018-01-05 06:21:34 +00:00
Anonymous Maarten
adc8255d4b tests: test_FileIndex needs include of rw/filesystem.hpp 2017-10-31 08:17:34 +00:00
Anonymous Maarten
e663d061b7 tests: capitalize test name (test_name.cpp -> test_Name.cpp) 2017-10-29 20:40:57 +00:00
Anonymous Maarten
9e9e684a44 tests: only include test_globals.hpp when needed 2017-08-15 15:58:01 +01:00
Daniel Evans
3015b7f3e0 clang-format files in tests 2016-09-09 21:13:22 +01:00
Daniel Evans
7b7e65e002 Fix file include path in test_FileIndex.cpp 2016-09-09 21:13:15 +01:00
Daniel Evans
d7dea62f04 remove unused method FileIndex::findFile 2016-09-07 22:06:38 +01:00
Daniel Evans
674ce55af3 Replace findPathRealCase with FileIndex methods
This introduces indexGameDirectory and findFilePath.
indexGameDirectory indexes the files in the game directory.
findFilePath returns the on-disk location of a case-insensitive
game data path.
2016-09-06 00:23:25 +01:00
darkf
196f9f6d25 Rewrite FileIndex to use boost::filesystem instead of POSIX 2016-08-03 18:31:47 -07:00
Daniel Evans
dd70e41bbd Add TESTS_NODATA to build tests without data 2016-06-16 21:22:18 +01:00
Daniel Evans
f3b81c5690 Bring tests back up to compiling and running. Only a few are failing 2016-04-15 01:06:10 +01:00