mirror of
https://gitlab.alpinelinux.org/alpine/cloud/tiny-cloud.git
synced 2025-12-15 11:22:43 +03:00
Use fake getent to avoid existing system users
The default user may or may not exist on the system running the tests. Create a fake getent to simulate non-existing user in a consistent way. fixes https://gitlab.alpinelinux.org/alpine/cloud/tiny-cloud/-/issues/42
This commit is contained in:
parent
5f26d1f579
commit
40d15db038
@ -114,6 +114,10 @@ enable_sshd_body() {
|
||||
}
|
||||
|
||||
create_default_user_body() {
|
||||
fake_bin getent <<-EOF
|
||||
#!/bin/sh
|
||||
exit 2
|
||||
EOF
|
||||
atf_check \
|
||||
-o match:"addgroup alpine" \
|
||||
-o match:"adduser.*alpine" \
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user