From eddd0fe20c0ac9645874cca70349ccfe1967e627 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Wed, 5 Jun 2013 21:46:31 -0600 Subject: librechroot: fix clean-repo --- test/librechroot-test.sh | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'test') diff --git a/test/librechroot-test.sh b/test/librechroot-test.sh index 9dc1b7d..06abd23 100644 --- a/test/librechroot-test.sh +++ b/test/librechroot-test.sh @@ -7,7 +7,7 @@ describe librechroot before() { _before librechroot mkdir -p "$XDG_CONFIG_HOME"/libretools - echo "CHROOTDIR='$tmpdir'" > "$XDG_CONFIG_HOME"/libretools/chroot.conf + echo "CHROOTDIR='$tmpdir/chrootdir'" > "$XDG_CONFIG_HOME"/libretools/chroot.conf echo "CHROOT='default'" >> "$XDG_CONFIG_HOME"/libretools/chroot.conf echo "CHROOTEXTRAPKG=()" >> "$XDG_CONFIG_HOME"/libretools/chroot.conf } @@ -23,6 +23,15 @@ it_creates_repo_for_new_chroots() { sudo -EH librechroot run test -r /repo/repo.db } +it_cleans_the_local_repo_correctly() { + require network sudo || return 0 + libremessages msg 'Creating a chroot, may take a few minutes' &>/dev/tty + sudo -EH librechroot make + sudo -EH librechroot clean-repo + sudo -EH librechroot run test -r /repo/repo.db + # TODO: inspect /repo/* more +} + it_displays_help_as_normal_user() { rm -rf "$XDG_CONFIG_HOME" librechroot help >$tmpdir/stdout 2>$tmpdir/stderr -- cgit v1.2.2