2 Commits

Author SHA1 Message Date
Thomas Boyer-Chammard
578e61f1da
Format Os Module (#3959)
* Format Os module

* Add Os to format-check CI

* Remove double semi-colon
2025-07-31 15:40:30 -07:00
Thomas Boyer-Chammard
d6ebdff460
Refactor Os::FileSystem and Os::Directory (#2871)
* Add FileSystem Interface

* Add OS::FileSystem interface and implementations

* static interface + global Os::init()

* Add test harness

* Implement Os::Directory interfaces and use it in FileSystem::readDirectory

* Add Stub tests for Directory and FileSystem

* wip: modify the interface from Michael feedback

* wip: move functions around and rework interface a little more

* Add Directory rule-based tests

* Refactored Directory for open-create + WIP: FileSystem tests

* Update state tracking mechanism in FileSystem test implementation + add RandomizedTesting

* Replace bounded while-loop with for-loop

* Code cleanup

* fix typo

* Rename FileTracker and code reorganization / clarification

* Code style and add CWD rule

* Clean up tester code

* More cleanup

* Add Posix tests to Os_ut_exe

* Fix DpCatalog readDirectory usage

* Appease CI checks

* Spelling and CI warnings

* Spelling + removing FppConstants include

* Add review changes and todos

* Add Directory::read(Fw::StringBase&) overload

* Refactor copyFileData to iterate over copied size

* Remove FppConstants.hpp include

* Rework moveFile into rename/copy-remove

* Add majestic comments

* Add option to error if dir exist in Fs::createDirectory

* spelling

* include <algorithm> for std::find in tests

* Fix leftover ::CREATE modes in comments and stub tests

* Fix CmdSequencer test case

* Fix memory leak in testing by conditioning the Open rule

* Fix FileManager tests

* Add Directory and FileSystem FPP type definitions; update CMakeLists and clean up comments

* spelling

* Reoder header guards

* Implement changes from peer-review

* read into StringBase with const_cast

* Fix resetSer() call

* Fix spelling

* fix spelling again i guess

* Fix DpCatalog unchecked return value
2024-09-27 09:15:21 -07:00