tests: Small tweaks to pull corruption test

This one is failing here, I suspect it's the generic pull race
condition, but these fixes should make it slightly more reliable.
This commit is contained in:
Colin Walters 2014-01-19 11:48:27 -05:00
parent 14e1cf61d9
commit 0a9f246016
2 changed files with 4 additions and 1 deletions

View File

@ -17,6 +17,8 @@
# Free Software Foundation, Inc., 59 Temple Place - Suite 330,
# Boston, MA 02111-1307, USA.
set -e
cd ${test_tmpdir}
mkdir repo
${CMD_PREFIX} ostree --repo=repo init

View File

@ -39,7 +39,8 @@ do_corrupt_pull_test() {
fi
rm -rf ${repopath}
cp -a ${repopath}.orig ${repopath}
if ${CMD_PREFIX} ostree --repo=repo pull origin main && ${CMD_PREFIX} ostree --repo=repo fsck; then
${CMD_PREFIX} ostree --repo=repo pull origin main
if ${CMD_PREFIX} ostree --repo=repo fsck; then
echo "ok pull with correct data worked"
else
assert_not_reached "pull with correct data failed!"