tests: drivers: move the nrf pinctrl test to new ztest API
Migrate the testsuite tests/drivers/pinctrl/nrf to the new ztest API. Signed-off-by: Enjia Mai <enjia.mai@intel.com>
This commit is contained in:
parent
9ccf98fbf3
commit
ac97b47596
@ -1,2 +1,3 @@
|
||||
CONFIG_ZTEST=y
|
||||
CONFIG_ZTEST_NEW_API=y
|
||||
CONFIG_PINCTRL_TEST_NON_STATIC=y
|
||||
|
||||
@ -12,7 +12,7 @@
|
||||
PINCTRL_DT_DEV_CONFIG_DECLARE(TEST_DEVICE);
|
||||
static const struct pinctrl_dev_config *pcfg = PINCTRL_DT_DEV_CONFIG_GET(TEST_DEVICE);
|
||||
|
||||
static void test_dt_extract(void)
|
||||
ZTEST(pinctrl_nrf, test_dt_extract)
|
||||
{
|
||||
const struct pinctrl_state *scfg;
|
||||
|
||||
@ -64,9 +64,4 @@ static void test_dt_extract(void)
|
||||
zassert_equal(NRF_GET_PIN(scfg->pins[6]), 38U, NULL);
|
||||
}
|
||||
|
||||
void test_main(void)
|
||||
{
|
||||
ztest_test_suite(pinctrl_nrf,
|
||||
ztest_unit_test(test_dt_extract));
|
||||
ztest_run_test_suite(pinctrl_nrf);
|
||||
}
|
||||
ZTEST_SUITE(pinctrl_nrf, NULL, NULL, NULL, NULL, NULL);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user