1 /* 2 * Copyright (c) 2020 Nordic Semiconductor ASA 3 * Copyright (c) 2022 Antmicro 4 * 5 * SPDX-License-Identifier: Apache-2.0 6 */ 7 8 #include <zephyr/ztest.h> 9 #include <zephyr/fs/littlefs.h> 10 #include "testfs_tests.h" 11 #include "testfs_lfs.h" 12 13 void test_fs_mount_flags(void); 14 /* Using smallest partition for this tests as they do not write 15 * a lot of data, basically they just check flags. 16 */ 17 struct fs_mount_t *mount_flags_mp = &testfs_small_mnt; 18 cleanup(struct fs_mount_t * mp)19static void cleanup(struct fs_mount_t *mp) 20 { 21 TC_PRINT("Clean %s\n", mp->mnt_point); 22 23 zassert_equal(testfs_lfs_wipe_partition(mp), TC_PASS, 24 "Failed to clean partition"); 25 } 26 ZTEST(littlefs,test_fs_mount_flags_lfs)27ZTEST(littlefs, test_fs_mount_flags_lfs) 28 { 29 cleanup(mount_flags_mp); 30 31 test_fs_mount_flags(); 32 } 33