Skip to content

Commit da867db

Browse files
dewitt-garminnashif
authored andcommitted
tests: Ensure the maximum expected SYS init priority works
Add a test to ensure that the max expected 2-digit SYS init priority works. Signed-off-by: Josh DeWitt <[email protected]>
1 parent 0f46359 commit da867db

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

tests/kernel/device/src/main.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,10 +270,11 @@ SYS_INIT(init_fn, APPLICATION, 0);
270270
SYS_INIT_NAMED(init1, init_fn, APPLICATION, 1);
271271
SYS_INIT_NAMED(init2, init_fn, APPLICATION, 2);
272272
SYS_INIT_NAMED(init3, init_fn, APPLICATION, 2);
273+
SYS_INIT_NAMED(init4, init_fn, APPLICATION, 99);
273274

274275
ZTEST(device, test_sys_init_multiple)
275276
{
276-
zassert_equal(sys_init_counter, 4, "");
277+
zassert_equal(sys_init_counter, 5, "");
277278
}
278279

279280
/* this is for storing sequence during initialization */

0 commit comments

Comments
 (0)