Skip to content

Rename previous compare_ctx with the new compare_6lowpan_ctx function #35

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions test/unit/modunit_pico_6lowpan.c
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ START_TEST(tc_compare_prefix)
}
END_TEST

START_TEST(tc_compare_ctx)
START_TEST(tc_compare_6lowpan_ctx)
{
int test = 1, ret = 0;
struct pico_ip6 a, b, c;
Expand All @@ -153,19 +153,19 @@ START_TEST(tc_compare_ctx)
STARTING();

TRYING("With 2 equal ctx's\n");
ret = compare_ctx(&ca, &cb);
ret = compare_6lowpan_ctx(&ca, &cb);
RESULTS();
FAIL_UNLESS(0 == ret, test, "Prefixes are equal, should've returned 0, ret = %d", ret);

ca.size = 60;
TRYING("With b > a\n");
ret = compare_ctx(&ca, &cb);
ret = compare_6lowpan_ctx(&ca, &cb);
RESULTS();
FAIL_UNLESS(ret, test, "Prefixes are not equal, shouln'r return 0, ret = %d", ret);

cb.size = 64;
TRYING("With b > c\n");
ret = compare_ctx(&cb, &cc);
ret = compare_6lowpan_ctx(&cb, &cc);
RESULTS();
FAIL_UNLESS(ret, test, "Prefixes are not equal, shouldn't return 0, ret = %d", ret);

Expand Down Expand Up @@ -1532,7 +1532,7 @@ static Suite *pico_suite(void)
Suite *s = suite_create("PicoTCP");

TCase *TCase_compare_prefix = tcase_create("Unit test for compare_prefix");
TCase *TCase_compare_ctx = tcase_create("Unit test for compare_ctx");
TCase *TCase_compare_6lowpan_ctx = tcase_create("Unit test for compare_6lowpan_ctx");
TCase *TCase_ctx_lookup = tcase_create("Unit test for ctx_lookup");

/*******************************************************************************
Expand Down Expand Up @@ -1565,8 +1565,8 @@ static Suite *pico_suite(void)

tcase_add_test(TCase_compare_prefix, tc_compare_prefix);
suite_add_tcase(s, TCase_compare_prefix);
tcase_add_test(TCase_compare_ctx ,tc_compare_ctx);
suite_add_tcase(s, TCase_compare_ctx);
tcase_add_test(TCase_compare_6lowpan_ctx ,tc_compare_6lowpan_ctx);
suite_add_tcase(s, TCase_compare_6lowpan_ctx);
tcase_add_test(TCase_ctx_lookup ,tc_ctx_lookup);
suite_add_tcase(s, TCase_ctx_lookup);

Expand Down
Loading