Commit 026a2c54 authored by Emil Gydesen's avatar Emil Gydesen Committed by Benjamin Cabé
Browse files

tests: Bluetooth: Audio: Spring cleanup for audio test files



Add missing and remove unused includes. Fix spelling mistakes.

Signed-off-by: default avatarEmil Gydesen <emil.gydesen@nordicsemi.no>
parent 48aedc98
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -6,7 +6,11 @@

#ifndef MOCKS_BAP_UNICAST_SERVER_H_
#define MOCKS_BAP_UNICAST_SERVER_H_
#include <stddef.h>
#include <stdint.h>

#include <zephyr/bluetooth/audio/audio.h>
#include <zephyr/bluetooth/conn.h>
#include <zephyr/fff.h>
#include <zephyr/bluetooth/audio/bap.h>

+1 −0
Original line number Diff line number Diff line
@@ -8,6 +8,7 @@
#define MOCKS_BAP_UNICAST_SERVER_EXPECTS_H_

#include <zephyr/bluetooth/audio/bap.h>
#include <zephyr/ztest_assert.h>

#include "bap_unicast_server.h"
#include "expects_util.h"
+3 −0
Original line number Diff line number Diff line
@@ -3,10 +3,13 @@
 *
 * SPDX-License-Identifier: Apache-2.0
 */
#include <stdint.h>

#include <zephyr/bluetooth/audio/bap.h>
#include <zephyr/bluetooth/conn.h>
#include <zephyr/bluetooth/gatt.h>
#include <zephyr/bluetooth/iso.h>
#include <zephyr/bluetooth/uuid.h>

#define test_ase_snk_get(_num_ase, ...) test_ase_get(BT_UUID_ASCS_ASE_SNK, _num_ase, __VA_ARGS__)
#define test_ase_src_get(_num_ase, ...) test_ase_get(BT_UUID_ASCS_ASE_SRC, _num_ase, __VA_ARGS__)
+9 −5
Original line number Diff line number Diff line
@@ -9,8 +9,12 @@
 */

#include <errno.h>
#include <stdint.h>
#include <stdlib.h>
#include <string.h>

#include <zephyr/bluetooth/gap.h>
#include <zephyr/bluetooth/iso.h>
#include <zephyr/fff.h>
#include <zephyr/kernel.h>
#include <zephyr/bluetooth/audio/audio.h>
@@ -20,10 +24,13 @@
#include <zephyr/bluetooth/hci_types.h>
#include <zephyr/bluetooth/gatt.h>
#include <zephyr/bluetooth/uuid.h>
#include <zephyr/net_buf.h>
#include <zephyr/sys/util_macro.h>
#include <zephyr/ztest_assert.h>
#include <zephyr/ztest_test.h>
#include <sys/types.h>

#include "assert.h"
#include "ascs_internal.h"
#include "bap_unicast_server.h"
#include "bap_unicast_server_expects.h"
#include "bap_stream.h"
@@ -32,11 +39,8 @@
#include "gatt.h"
#include "gatt_expects.h"
#include "iso.h"
#include "mock_kernel.h"
#include "pacs.h"

#include "test_common.h"
#include "ztest_assert.h"

DEFINE_FFF_GLOBALS;

@@ -193,7 +197,7 @@ ZTEST_F(ascs_test_suite, test_release_ase_on_callback_unregister)
	/* Reset mock, as we expect ASE notification to be sent */
	bt_gatt_notify_cb_reset();

	/* Unregister the callbacks - whis will clean up the ASCS */
	/* Unregister the callbacks - which will clean up the ASCS */
	bt_bap_unicast_server_unregister_cb(&mock_bap_unicast_server_cb);

	/* Expected to notify the upper layers */
+7 −4
Original line number Diff line number Diff line
@@ -9,25 +9,28 @@

#include <stdint.h>
#include <stdlib.h>
#include <zephyr/bluetooth/gap.h>
#include <zephyr/bluetooth/iso.h>
#include <zephyr/bluetooth/uuid.h>
#include <zephyr/kernel.h>
#include <zephyr/toolchain.h>
#include <zephyr/types.h>
#include <zephyr/bluetooth/audio/audio.h>
#include <zephyr/bluetooth/audio/bap.h>
#include <zephyr/bluetooth/conn.h>
#include <zephyr/bluetooth/gatt.h>
#include <zephyr/sys/util_macro.h>
#include <zephyr/ztest_assert.h>
#include <zephyr/ztest_test.h>
#include <sys/types.h>

#include "bap_unicast_server.h"
#include "bap_unicast_server_expects.h"
#include "bap_stream.h"
#include "bap_stream_expects.h"
#include "conn.h"
#include "gatt.h"
#include "gatt_expects.h"
#include "iso.h"

#include "test_common.h"
#include "ztest_assert.h"

struct test_ase_control_params_fixture {
	struct bt_conn conn;
Loading