diff options
author | Joe Hershberger <joe.hershberger@ni.com> | 2015-05-20 14:27:27 -0500 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2015-05-21 09:16:16 -0400 |
commit | e721b882e9daf3ad3599eef5a9ccf3847b694228 (patch) | |
tree | d92fadcb65548e6ed19c60d4dfa27ecc80c3778c /test/dm/eth.c | |
parent | 6e0d26c0502e4d697cb235069aef188f8f1407d3 (diff) |
test: Generalize the unit test framework
Separate the ability to define tests and assert status of test functions
from the dm tests so they can be used more consistently throughout all
tests.
Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'test/dm/eth.c')
-rw-r--r-- | test/dm/eth.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/test/dm/eth.c b/test/dm/eth.c index f31f6b322d7..061584e2e16 100644 --- a/test/dm/eth.c +++ b/test/dm/eth.c @@ -9,16 +9,16 @@ #include <common.h> #include <dm.h> -#include <dm/test.h> -#include <dm/ut.h> #include <fdtdec.h> #include <malloc.h> #include <net.h> +#include <dm/test.h> #include <asm/eth.h> +#include <test/ut.h> DECLARE_GLOBAL_DATA_PTR; -static int dm_test_eth(struct dm_test_state *dms) +static int dm_test_eth(struct unit_test_state *uts) { net_ping_ip = string_to_ip("1.1.2.2"); @@ -38,7 +38,7 @@ static int dm_test_eth(struct dm_test_state *dms) } DM_TEST(dm_test_eth, DM_TESTF_SCAN_FDT); -static int dm_test_eth_alias(struct dm_test_state *dms) +static int dm_test_eth_alias(struct unit_test_state *uts) { net_ping_ip = string_to_ip("1.1.2.2"); setenv("ethact", "eth0"); @@ -62,7 +62,7 @@ static int dm_test_eth_alias(struct dm_test_state *dms) } DM_TEST(dm_test_eth_alias, DM_TESTF_SCAN_FDT); -static int dm_test_eth_prime(struct dm_test_state *dms) +static int dm_test_eth_prime(struct unit_test_state *uts) { net_ping_ip = string_to_ip("1.1.2.2"); @@ -82,7 +82,7 @@ static int dm_test_eth_prime(struct dm_test_state *dms) } DM_TEST(dm_test_eth_prime, DM_TESTF_SCAN_FDT); -static int dm_test_eth_rotate(struct dm_test_state *dms) +static int dm_test_eth_rotate(struct unit_test_state *uts) { char ethaddr[18]; @@ -127,7 +127,7 @@ static int dm_test_eth_rotate(struct dm_test_state *dms) } DM_TEST(dm_test_eth_rotate, DM_TESTF_SCAN_FDT); -static int dm_test_net_retry(struct dm_test_state *dms) +static int dm_test_net_retry(struct unit_test_state *uts) { net_ping_ip = string_to_ip("1.1.2.2"); |