summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorFrantisek Sumsal <frantisek@sumsal.cz>2018-11-08 09:40:13 +0100
committerFrantisek Sumsal <frantisek@sumsal.cz>2018-11-08 11:07:21 +0100
commitc446b8486d9ed18d1bc780948ae9ee8a53fa4c3f (patch)
treee2ea3518216bc745363ad2b7cef885824e470754 /src
parent0ccc48b5b8319ece4d8b87d8d9e0816df3991099 (diff)
downloadsystemd-c446b8486d9ed18d1bc780948ae9ee8a53fa4c3f.tar.gz
systemd-c446b8486d9ed18d1bc780948ae9ee8a53fa4c3f.tar.bz2
systemd-c446b8486d9ed18d1bc780948ae9ee8a53fa4c3f.zip
tests: drop the precondition check for inherited flag
Docker's default capability set has the inherited flag already set - that breaks tests which expect otherwise. Let's just drop the check and run the test anyway. Fixes #10663
Diffstat (limited to 'src')
-rw-r--r--src/test/test-capability.c8
1 files changed, 0 insertions, 8 deletions
diff --git a/src/test/test-capability.c b/src/test/test-capability.c
index 730dbf8cbd..1cca76cb5d 100644
--- a/src/test/test-capability.c
+++ b/src/test/test-capability.c
@@ -180,8 +180,6 @@ static void test_update_inherited_set(void) {
caps = cap_get_proc();
assert_se(caps);
- assert_se(!cap_get_flag(caps, CAP_CHOWN, CAP_INHERITABLE, &fv));
- assert(fv == CAP_CLEAR);
set = (UINT64_C(1) << CAP_CHOWN);
@@ -197,12 +195,6 @@ static void test_set_ambient_caps(void) {
uint64_t set = 0;
cap_flag_value_t fv;
- caps = cap_get_proc();
- assert_se(caps);
- assert_se(!cap_get_flag(caps, CAP_CHOWN, CAP_INHERITABLE, &fv));
- assert(fv == CAP_CLEAR);
- cap_free(caps);
-
assert_se(prctl(PR_CAP_AMBIENT, PR_CAP_AMBIENT_IS_SET, CAP_CHOWN, 0, 0) == 0);
set = (UINT64_C(1) << CAP_CHOWN);