summaryrefslogtreecommitdiff
path: root/test/test-utils-glib.h
Commit message (Collapse)AuthorAgeFilesLines
* Treat root as a valid candidate for TEST_USER_MESimon McVittie2015-02-031-4/+3
| | | | | | | | | | | | If spawn_dbus_daemon() can fail for TEST_USER_ME, then we'd have to go through all the tests adding the ability to skip tests after it fails, which is a fairly extensive change. The tests have historically all run as whatever uid is supplied, and if the tests are being run as root for some reason - perhaps in a CI framework for an embedded platform that doesn't have non-root users, or in an environment where you can be root or non-root but not both - there is no particular reason to skip them.
* Add a test for uid-controlled permissionsSimon McVittie2015-02-031-0/+3
| | | | | | | | This is technical debt from mitigating CVE-2014-8148, which should really have had a regression test at the time. Bug: https://bugs.freedesktop.org/show_bug.cgi?id=88810 Reviewed-by: Philip Withnall
* Add infrastructure to run bits of tests under an alternative uidSimon McVittie2015-02-031-0/+31
| | | | | Bug: https://bugs.freedesktop.org/show_bug.cgi?id=88810 Reviewed-by: Philip Withnall
* Factor out some utility functions from test/dbus-daemon*Simon McVittie2015-02-031-0/+49
In the process, make test_kill_pid() safer: do not try to terminate more than one pid, or the NULL handle. Also stop leaking the address_fd in spawn_dbus_daemon, a pre-existing bug that was spotted by Philip Withnall during review. Bug: https://bugs.freedesktop.org/show_bug.cgi?id=88810 Reviewed-by: Philip Withnall