mbed-os/features/storage/TESTS/filesystem
Kyle Kearney 18af867704 Filesystem test: Move lfs init in test startup
tests-filesystem-general_filesystem declares BlockDevice and FileSystem
pointers as globals. If these are initialized to their respective
default_instance values in the declaration, the LFS init happens during
OS startup when __libc_init_array() is invoked by mbed_toolchain_init().
If the filesystem blockdevice does not currently contain a valid filesystem
(e.g. the chip has just been erased), then LFS will flag this as corruption
and abort the mounting process.
This cleanup process can take long enough (and is running pre-main) that
greentea times out waiting for the device to respond to its sync packet,
and resets the device.
To resolve this, move the initialization into the first test case
(bd_init_fs_reformat) right before it initializes and formats the
blockdevice and filesystem.
2020-04-21 15:13:01 -07:00
..
fat_filesystem FATFileSystem::stat() enabled for all compilers 2019-08-09 15:52:49 +03:00
general_filesystem Filesystem test: Move lfs init in test startup 2020-04-21 15:13:01 -07:00
multipart_fat_filesystem Newline at the end of files 2019-08-01 08:44:58 +02:00