Skip to content

Commit 39723f7

Browse files
committed
10_immutable.cf: Use getacls instead of command
Ticket: ENT-10961, CFE-1840 Signed-off-by: Lars Erik Wik <lars.erik.wik@northern.tech>
1 parent 3a74565 commit 39723f7

File tree

1 file changed

+3
-8
lines changed

1 file changed

+3
-8
lines changed

tests/acceptance/10_files/unsafe/10_immutable.cf

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -67,17 +67,12 @@ bundle agent test
6767
bundle agent check
6868
{
6969
vars:
70-
"getfacl"
71-
string => ifelse(
72-
fileexists("/var/cfengine/bin/getfacl"), # if
73-
"/var/cfengine/bin/getfacl", # then
74-
"/usr/bin/getfacl" # else
75-
);
76-
7770
"expected"
7871
string => ".*user:root:rwx.*";
72+
"acls"
73+
slist => getacls("$(global.filename)", "access");
7974
"actual"
80-
string => execresult("$(getfacl) $(global.testfile)", "noshell");
75+
string => nth("acls", "0");
8176

8277
classes:
8378
"ok"

0 commit comments

Comments
 (0)