test: update policy tests to handle user namespaces
Upstream kernels allow unprivileged users to create user namespaces
and change their uid/gid.
These patches update kdbus policy logic to handle this case and
improve our current checks across user namespaces.
So this patch adds:
* kdbus_test_waitpid() to get exit code of childs.
* kdbus_clone_userns_test() that performs the test inside a new
user namespace.
* Converts all the other tests to return CHECK_OK, CHECK_SKIP or
CHECK_ERR so we are consistent.
Currently we fail at kdbus_clone_userns_test() test #8. The next patch
will fix this issue.
Signed-off-by: Djalal Harouni <tixxdz@opendz.org>