ztest API Migration: bluetooth/at
Migrate the unit tests at `bluetooth/at` to use the new ztest API. Signed-off-by: Tristan Honscheid <honscheid@google.com>
This commit is contained in:
parent
d39063a20d
commit
7e7855d669
2 changed files with 3 additions and 10 deletions
|
@ -3,4 +3,5 @@ CONFIG_BT_BREDR=y
|
|||
CONFIG_BT_HFP_HF=y
|
||||
CONFIG_NET_BUF=y
|
||||
CONFIG_ZTEST=y
|
||||
CONFIG_ZTEST_NEW_API=y
|
||||
CONFIG_SERIAL=y
|
||||
|
|
|
@ -43,8 +43,9 @@ int at_resp(struct at_client *hf_at, struct net_buf *buf)
|
|||
return 0;
|
||||
}
|
||||
|
||||
ZTEST_SUITE(at_tests, NULL, NULL, NULL, NULL, NULL);
|
||||
|
||||
static void test_at(void)
|
||||
ZTEST(at_tests, test_at)
|
||||
{
|
||||
struct net_buf *buf;
|
||||
int len;
|
||||
|
@ -65,12 +66,3 @@ static void test_at(void)
|
|||
|
||||
zassert_equal(at_parse_input(&at, buf), 0, "Parsing failed");
|
||||
}
|
||||
|
||||
void test_main(void)
|
||||
{
|
||||
ztest_test_suite(at_tests,
|
||||
ztest_unit_test(test_at)
|
||||
);
|
||||
|
||||
ztest_run_test_suite(at_tests);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue