-
-
Notifications
You must be signed in to change notification settings - Fork 62
Expand file tree
/
Copy pathBUILD.bazel
More file actions
43 lines (40 loc) · 976 Bytes
/
BUILD.bazel
File metadata and controls
43 lines (40 loc) · 976 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
load("@bazel_lib//lib:diff_test.bzl", "diff_test")
load("//distroless:defs.bzl", "group")
load("//distroless/tests:asserts.bzl", "assert_tar_mtree")
group(
name = "group",
entries = [
# https://www.ibm.com/docs/kk/aix/7.2?topic=files-etcgroup-file#group_security__a3179518__title__1
dict(
name = "root",
gid = 0,
users = [
"shadow",
"cjf",
],
),
dict(
name = "nonroot",
gid = 4656,
password = "x",
users = [
"shadow",
"cjf",
],
),
],
)
diff_test(
name = "test_group_content",
file1 = "group_content",
file2 = "group.expected.txt",
)
assert_tar_mtree(
name = "test_group",
actual = "group",
expected = """\
#mtree
./etc time=0.0 mode=755 gid=0 uid=0 type=dir
./etc/group time=0.0 mode=644 gid=0 uid=0 type=file size=46
""",
)