Commit 73d658bd authored by Mateusz Syc's avatar Mateusz Syc Committed by Anas Nashif
Browse files

tests/subsys/logging/log_backend_fs: Test of log_backend_fs



Tests verify correctness of the internal backend behaviour.

Signed-off-by: default avatarMateusz Syc <Mateusz.Syc@nordicsemi.no>
Signed-off-by: default avatarAndrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
parent fe5f6026
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: Apache-2.0

cmake_minimum_required(VERSION 3.13.1)
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
project(log_backend_fs_test)

FILE(GLOB app_sources src/*.c)
target_sources(app PRIVATE ${app_sources})
+8 −0
Original line number Diff line number Diff line
# Copyright (c) 2021 Nordic Semiconductor ASA
# SPDX-License-Identifier: Apache-2.0

config LOG_BACKEND_FS_TESTSUITE
	bool
	default y

source "Kconfig.zephyr"
+23 −0
Original line number Diff line number Diff line
/*
 * Copyright (c) 2021 Nordic Semiconductor ASA
 *
 * SPDX-License-Identifier: Apache-2.0
 */

/delete-node/ &lfs1;
/ {
	fstab {
		compatible = "zephyr,fstab";
		lfs1: lfs1 {
			compatible = "zephyr,fstab,littlefs";
			mount-point = "/lfs1";
			partition = <&lfs1_part>;
			automount;
			read-size = <16>;
			prog-size = <16>;
			cache-size = <64>;
			lookahead-size = <32>;
			block-cycles = <512>;
		};
	};
};
+1 −0
Original line number Diff line number Diff line
CONFIG_LOG_MODE_DEFERRED=y
+36 −0
Original line number Diff line number Diff line
/*
 * Copyright (c) 2021 Nordic Semiconductor ASA
 *
 * SPDX-License-Identifier: Apache-2.0
 */

/delete-node/ &storage_partition;

/ {
	fstab {
		compatible = "zephyr,fstab";
		lfs1: lfs1 {
			compatible = "zephyr,fstab,littlefs";
			mount-point = "/lfs1";
			partition = <&lfs1_part>;
			read-size = <16>;
			prog-size = <16>;
			cache-size = <64>;
			lookahead-size = <32>;
			block-cycles = <512>;
		};
	};
};

&flash0 {

	partitions {
		compatible = "fixed-partitions";
		#address-cells = <1>;
		#size-cells = <1>;
		lfs1_part: partition@fc000 {
			label = "storage";
			reg = <0x000fc000 0x00010000>;
		};
	};
};
Loading