Skip to content

Commit b446ca9

Browse files
committed
[nrf fromlist] tests: fs: zms: add testsuite for ZMS storage
List of added tests : - zms.test_delete - zms.test_zms_cache_collission - zms.test_zms_cache_gc - zms.test_zms_cache_hash_quality - zms.test_zms_cache_init - zms.test_zms_corrupted_sector_close_operation - zms.test_zms_corrupted_write - zms.test_zms_full_sector - zms.test_zms_gc - zms.test_zms_gc_3sectors - zms.test_zms_gc_corrupt_ate - zms.test_zms_gc_corrupt_close_ate - zms.test_zms_mount - zms.test_zms_write Upstream PR: zephyrproject-rtos/zephyr#77930 Signed-off-by: Riadh Ghaddab <[email protected]> (cherry picked from commit d86870e25e50df952a8ff404ebdd8390f05a3107)
1 parent 8b923ca commit b446ca9

File tree

6 files changed

+948
-0
lines changed

6 files changed

+948
-0
lines changed

tests/subsys/fs/zms/CMakeLists.txt

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# SPDX-License-Identifier: Apache-2.0
2+
3+
cmake_minimum_required(VERSION 3.20.0)
4+
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
5+
project(fs_zms)
6+
7+
FILE(GLOB app_sources src/*.c)
8+
target_sources(app PRIVATE ${app_sources})
9+
target_include_directories(app PRIVATE ${ZEPHYR_BASE}/subsys/fs/zms)
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
/*
2+
* Copyright (c) 2024 Nordic Semiconductor ASA
3+
*
4+
* SPDX-License-Identifier: Apache-2.0
5+
*/
6+
7+
&flash0 {
8+
erase-block-size = <0x400>;
9+
};
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
/*
2+
* Copyright (c) 2024 Nordic Semiconductor ASA
3+
*
4+
* SPDX-License-Identifier: Apache-2.0
5+
*/
6+
7+
&sim_flash {
8+
erase-value = < 0x00 >;
9+
};

tests/subsys/fs/zms/prj.conf

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
CONFIG_ZTEST=y
2+
CONFIG_ZTEST_STACK_SIZE=4096
3+
CONFIG_STDOUT_CONSOLE=y
4+
5+
CONFIG_FLASH=y
6+
CONFIG_FLASH_MAP=y
7+
8+
CONFIG_ZMS=y
9+
CONFIG_LOG=y
10+
CONFIG_ZMS_LOG_LEVEL_DBG=y

0 commit comments

Comments
 (0)