Skip to content

Commit 1e436f4

Browse files
Thalleykartben
authored andcommitted
tests: Bluetooth: PACS: Modify unittests to native_sim
Modify the unit tests to use the native_sim board instead of the unit_testing board. The native_sim board allows us to use the kernel in a more regular way, while still being able to treat the tests as unittest. Signed-off-by: Emil Gydesen <[email protected]>
1 parent af00bc5 commit 1e436f4

File tree

3 files changed

+34
-38
lines changed

3 files changed

+34
-38
lines changed

tests/bluetooth/audio/pacs/CMakeLists.txt

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,10 @@
22

33
cmake_minimum_required(VERSION 3.20.0)
44

5-
find_package(Zephyr COMPONENTS unittest HINTS $ENV{ZEPHYR_BASE})
6-
5+
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
76
project(bluetooth_pacs)
87

9-
add_subdirectory(${ZEPHYR_BASE}/tests/bluetooth/audio/pacs/uut uut)
10-
11-
target_link_libraries(testbinary PRIVATE uut)
12-
13-
target_include_directories(testbinary PRIVATE include)
14-
15-
target_sources(testbinary
8+
target_sources(app
169
PRIVATE
1710
src/main.c
1811
)

tests/bluetooth/audio/pacs/testcase.yaml

Lines changed: 32 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,56 +4,80 @@ common:
44
- bluetooth_audio
55
tests:
66
bluetooth.audio.pacs.test_default:
7-
type: unit
7+
platform_allow:
8+
- native_sim
9+
integration_platforms:
10+
- native_sim
811
extra_configs:
912
- CONFIG_BT_PAC_SNK=y
1013
- CONFIG_BT_PAC_SNK_LOC=y
1114
- CONFIG_BT_PAC_SRC=y
1215
- CONFIG_BT_PAC_SRC_LOC=y
1316
bluetooth.audio.pacs.test_snk_pac_snk_loc_src_pac:
14-
type: unit
17+
platform_allow:
18+
- native_sim
19+
integration_platforms:
20+
- native_sim
1521
extra_configs:
1622
- CONFIG_BT_PAC_SNK=y
1723
- CONFIG_BT_PAC_SNK_LOC=y
1824
- CONFIG_BT_PAC_SRC=y
1925
- CONFIG_BT_PAC_SRC_LOC=n
2026
bluetooth.audio.pacs.test_snk_pac_snk_loc:
21-
type: unit
27+
platform_allow:
28+
- native_sim
29+
integration_platforms:
30+
- native_sim
2231
extra_configs:
2332
- CONFIG_BT_PAC_SNK=y
2433
- CONFIG_BT_PAC_SNK_LOC=y
2534
- CONFIG_BT_PAC_SRC=n
2635
- CONFIG_BT_PAC_SRC_LOC=n
2736
bluetooth.audio.pacs.test_snk_pac:
28-
type: unit
37+
platform_allow:
38+
- native_sim
39+
integration_platforms:
40+
- native_sim
2941
extra_configs:
3042
- CONFIG_BT_PAC_SNK=y
3143
- CONFIG_BT_PAC_SNK_LOC=n
3244
- CONFIG_BT_PAC_SRC=n
3345
- CONFIG_BT_PAC_SRC_LOC=n
3446
bluetooth.audio.pacs.test_snk_pac_src_pac_src_loc:
35-
type: unit
47+
platform_allow:
48+
- native_sim
49+
integration_platforms:
50+
- native_sim
3651
extra_configs:
3752
- CONFIG_BT_PAC_SNK=y
3853
- CONFIG_BT_PAC_SNK_LOC=n
3954
- CONFIG_BT_PAC_SRC=y
4055
- CONFIG_BT_PAC_SRC_LOC=y
4156
bluetooth.audio.pacs.test_snk_pac_src_pac:
42-
type: unit
57+
platform_allow:
58+
- native_sim
59+
integration_platforms:
60+
- native_sim
4361
extra_configs:
4462
- CONFIG_BT_PAC_SNK=y
4563
- CONFIG_BT_PAC_SNK_LOC=n
4664
- CONFIG_BT_PAC_SRC=y
4765
- CONFIG_BT_PAC_SRC_LOC=n
4866
bluetooth.audio.pacs.test_src_pac_src_loc:
49-
type: unit
67+
platform_allow:
68+
- native_sim
69+
integration_platforms:
70+
- native_sim
5071
extra_configs:
5172
- CONFIG_BT_PAC_SNK=n
5273
- CONFIG_BT_PAC_SNK_LOC=n
5374
- CONFIG_BT_PAC_SRC=y
5475
- CONFIG_BT_PAC_SRC_LOC=y
5576
bluetooth.audio.pacs.test_src_pac:
56-
type: unit
77+
platform_allow:
78+
- native_sim
79+
integration_platforms:
80+
- native_sim
5781
extra_configs:
5882
- CONFIG_BT_PAC_SNK=n
5983
- CONFIG_BT_PAC_SNK_LOC=n

tests/bluetooth/audio/pacs/uut/CMakeLists.txt

Lines changed: 0 additions & 21 deletions
This file was deleted.

0 commit comments

Comments
 (0)