QSPIFBlockDevice: Add unit test for the S25FS512S quirk
Add a test case to verify that the quirk on `CR1NV` and `CR3NV` registers get applied by `QSPIFBlockDevice` when the flash device is S25FS512S. `QSPIFBlockDevice` depends on the SFDP functions and the `QSPI` class, but we can't use gMock on them because: * SFDP functions are global functions, whereas gMock only supports mocking class member functions. * A mocked class is injected into the test subject, but passing a preexisting `QSPI` instance into `QSPIFBlockDevice` is not possible (unless we resort to pointers). For details, see comments in test_QSPIFBlockDevice.cpp. So fakes of the `QSPI` class and any SFDP functions involved are defined in test_QSPIFBlockDevice.cpp. |
---|
|
storage/blockdevice/CMakeLists.txt |
---|
storage/blockdevice/COMPONENT_QSPIF/CMakeLists.txt |
---|
storage/blockdevice/COMPONENT_QSPIF/UNITTESTS/.mbedignore 0 → 100644 |
---|
storage/blockdevice/COMPONENT_QSPIF/UNITTESTS/CMakeLists.txt 0 → 100644 |
---|
storage/blockdevice/COMPONENT_QSPIF/UNITTESTS/test_QSPIFBlockDevice.cpp 0 → 100644 |
---|