forked from Imagelibrary/rtems
libtests/shell01:add test empty and NULL usernames check
This commit is contained in:
@@ -239,6 +239,12 @@ static void test(void)
|
|||||||
ok = rtems_shell_login_check("invchroot", NULL);
|
ok = rtems_shell_login_check("invchroot", NULL);
|
||||||
rtems_test_assert(!ok);
|
rtems_test_assert(!ok);
|
||||||
|
|
||||||
|
ok = rtems_shell_login_check("", NULL);
|
||||||
|
rtems_test_assert(!ok);
|
||||||
|
|
||||||
|
ok = rtems_shell_login_check(NULL, NULL);
|
||||||
|
rtems_test_assert(ok);
|
||||||
|
|
||||||
rtems_test_assert(getuid() == 0);
|
rtems_test_assert(getuid() == 0);
|
||||||
rtems_test_assert(geteuid() == 0);
|
rtems_test_assert(geteuid() == 0);
|
||||||
rtems_test_assert(getgid() == 0);
|
rtems_test_assert(getgid() == 0);
|
||||||
|
|||||||
Reference in New Issue
Block a user