summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--test/lib-conf-test.sh2
-rw-r--r--test/librechroot-test.sh6
-rw-r--r--test/libremakepkg-test.sh2
3 files changed, 5 insertions, 5 deletions
diff --git a/test/lib-conf-test.sh b/test/lib-conf-test.sh
index eeea287..0ee0f62 100644
--- a/test/lib-conf-test.sh
+++ b/test/lib-conf-test.sh
@@ -25,7 +25,7 @@ it_figures_out_HOME_when_root() {
cd "$tmpdir"
echo '. $(librelib conf.sh); echo "$LIBREHOME"' > test.sh
- LIBREHOME=$(sudo bash ./test.sh)
+ LIBREHOME=$(sudo -EH bash ./test.sh)
[[ $LIBREHOME == $HOME ]]
}
diff --git a/test/librechroot-test.sh b/test/librechroot-test.sh
index c9fa130..c34af6e 100644
--- a/test/librechroot-test.sh
+++ b/test/librechroot-test.sh
@@ -14,7 +14,7 @@ after() {
}
it_creates_repo_for_new_chroots() {
- sudo librechroot run test -r /repo/repo.db
+ sudo -EH librechroot run test -r /repo/repo.db
}
it_displays_help_as_normal_user() {
@@ -41,7 +41,7 @@ it_displays_help_and_fails_with_0_args() {
}
it_fails_for_unknown_commands() {
- sudo librechroot phony >$tmpdir/stdout 2>$tmpdir/stderr || stat=$?
+ sudo -EH librechroot phony >$tmpdir/stdout 2>$tmpdir/stderr || stat=$?
[[ $stat != 0 ]]
[[ -z "$(cat $tmpdir/stdout)" ]]
@@ -49,7 +49,7 @@ it_fails_for_unknown_commands() {
}
it_fails_for_unknown_flags() {
- sudo librechroot -q >$tmpdir/stdout 2>$tmpdir/stderr || stat=$?
+ sudo -EH librechroot -q >$tmpdir/stdout 2>$tmpdir/stderr || stat=$?
[[ $stat != 0 ]]
[[ -z "$(cat $tmpdir/stdout)" ]]
diff --git a/test/libremakepkg-test.sh b/test/libremakepkg-test.sh
index 5ea3b59..b014da7 100644
--- a/test/libremakepkg-test.sh
+++ b/test/libremakepkg-test.sh
@@ -17,7 +17,7 @@ it_builds_a_trivial_package() {
cp libremakepkg.d/PKGBUILD-hello "$tmpdir/PKGBUILD"
cd "$tmpdir"
- sudo libremakepkg &>/dev/null
+ sudo -EH libremakepkg &>/dev/null
[[ -f $(echo libretools-hello-1.0-1-any.pkg.tar.?z) ]]
}