ztest API Migration: bluetooth/hci_prop_evt
Migrate the unit tests at `bluetooth/hci_prop_evt` to use the
new ztest API.
Signed-off-by: Tristan Honscheid <honscheid@google.com>
diff --git a/tests/bluetooth/hci_prop_evt/prj.conf b/tests/bluetooth/hci_prop_evt/prj.conf
index 53cee7e..2d4e19b 100644
--- a/tests/bluetooth/hci_prop_evt/prj.conf
+++ b/tests/bluetooth/hci_prop_evt/prj.conf
@@ -1,5 +1,6 @@
CONFIG_TEST=y
CONFIG_ZTEST=y
+CONFIG_ZTEST_NEW_API=y
CONFIG_BT=y
CONFIG_BT_CTLR=n
diff --git a/tests/bluetooth/hci_prop_evt/src/main.c b/tests/bluetooth/hci_prop_evt/src/main.c
index cd055ef..f262e7d 100644
--- a/tests/bluetooth/hci_prop_evt/src/main.c
+++ b/tests/bluetooth/hci_prop_evt/src/main.c
@@ -342,8 +342,10 @@
bt_recv_job_submit(buf);
}
+ZTEST_SUITE(test_hci_prop_evt, NULL, NULL, NULL, NULL, NULL);
+
/* Test. */
-static void test_hci_prop_evt_entry(void)
+ZTEST(test_hci_prop_evt, test_hci_prop_evt_entry)
{
/* Register the test HCI driver */
bt_hci_driver_register(&drv);
@@ -377,12 +379,3 @@
/* Free the data memory */
k_free(prop_cb_data);
}
-
-/*test case main entry*/
-void test_main(void)
-{
- ztest_test_suite(test_hci_prop_evt,
- ztest_unit_test(test_hci_prop_evt_entry));
-
- ztest_run_test_suite(test_hci_prop_evt);
-}