diff options
Diffstat (limited to 'test/librestage-test.sh')
-rw-r--r-- | test/librestage-test.sh | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/test/librestage-test.sh b/test/librestage-test.sh index 8caf5d6..4f617ca 100644 --- a/test/librestage-test.sh +++ b/test/librestage-test.sh @@ -6,15 +6,15 @@ describe librestage before() { common_before - mkdir -p $XDG_CONFIG_HOME/libretools - echo "WORKDIR='$tmpdir/workdir'" > $XDG_CONFIG_HOME/libretools/libretools.conf + install -Dm644 /dev/stdin "$XDG_CONFIG_HOME/libretools/libretools.conf" <<-eot + WORKDIR=${tmpdir@Q}/workdir + eot - mkdir -p $XDG_CONFIG_HOME/pacman - { - printf 'PKGDEST=%q\n' "$tmpdir/workdir/pkgdest" - printf 'SRCPKGDEST=%q\n' "$tmpdir/workdir/srcpkgdest" - echo "PACKAGER='Test Suite <test@localhost>'" - } >$XDG_CONFIG_HOME/pacman/makepkg.conf + install -Dm644 /dev/stdin "$XDG_CONFIG_HOME/pacman/makepkg.conf" <<-eot + PKGDEST=${tmpdir@Q}/workdir/pkgdest + SRCPKGDEST=${tmpdir@Q}/workdir/srcpkgdest + PACKAGER='Test Suite <test@localhost>' + eot mkdir -p "$tmpdir/workdir/pkgdest" mkdir -p "$tmpdir/workdir/srcpkgdest" @@ -66,8 +66,10 @@ it_guesses_the_repo() { it_stages_packages_without_PKGDEST() { nochroot=false; require network sudo || nochroot=true - echo "PKGDEST=''" >> $XDG_CONFIG_HOME/pacman/makepkg.conf - echo "SRCPKGDEST=''" >> $XDG_CONFIG_HOME/pacman/makepkg.conf + cat >> "$XDG_CONFIG_HOME/pacman/makepkg.conf" <<-eot + PKGDEST='' + SRCPKGDEST='' + eot cp librestage.d/PKGBUILD-hello "$tmpdir/PKGBUILD" cd "$tmpdir" |