Skip to content

Commit

Permalink
install required slices in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
linostar committed Aug 2, 2024
1 parent 544ba40 commit 56e3a67
Showing 1 changed file with 6 additions and 9 deletions.
15 changes: 6 additions & 9 deletions tests/spread/integration/adduser/task.yaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,10 @@
summary: Integration tests for adduser

execute: |
rootfs="$(install-slices adduser_bins)"
mkdir -p "$rootfs/{bin,lib,lib64}"
cp /bin/bash "$rootfs/bin"
chroot "$rootfs"
rootfs="$(install-slices base-files_base bash_bins coreutils_bins adduser_bins)"
test -f /etc/passwd
adduser --quiet --system testuser
grep testuser /etc/passwd
deluser --quiet testuser
! grep testuser /etc/passwd
chroot "$rootfs" test -f /etc/passwd
chroot "$rootfs" adduser --quiet --system testuser
chroot "$rootfs" grep testuser /etc/passwd
chroot "$rootfs" deluser --quiet testuser
chroot "$rootfs" grep -v testuser /etc/passwd

0 comments on commit 56e3a67

Please sign in to comment.