diff options
author | Bernard Ogden <bernie.ogden@linaro.org> | 2015-04-27 12:55:00 +0100 |
---|---|---|
committer | Bernard Ogden <bernie.ogden@linaro.org> | 2015-04-28 11:20:46 +0100 |
commit | 68a16f43d3e94bb4116623b918fd8726343b23c1 (patch) | |
tree | 9cf3bf74f2c076e943dc3c852c72d5e512e024d3 /testsuite | |
parent | af7d47dd621fd4a3d137bc9ca3bd9ed8db147621 (diff) |
Test that checkout produces expected directories
Change-Id: Ica70efda0d7cc07f6f062064e49d1ada7bcc45d0
Diffstat (limited to 'testsuite')
-rwxr-xr-x | testsuite/test.sh | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/testsuite/test.sh b/testsuite/test.sh index c911a591..bde449d7 100755 --- a/testsuite/test.sh +++ b/testsuite/test.sh @@ -1407,6 +1407,33 @@ else fi fi +rm -rf "${local_snapshots}"/* +in="`get_URL abe.git`" +testing="checkout: abe.git should produce ${local_snapshots}/abe.git" +if (cd "${local_snapshots}" && \ + if test x"${debug}" = xyes; then checkout "${in}" > /dev/null; else checkout "${in}" > /dev/null 2>&1; fi && \ + test `ls | wc -l` -eq 1 && \ + ls abe.git > /dev/null); then + pass "${testing}" +else + fail "${testing}" +fi + +rm -rf "${local_snapshots}"/* +in="`get_URL abe.git`" +in="`get_git_url ${in}`" +testing="checkout: abe.git~staging should produce ${local_snapshots}/abe.git and ${local_snapshots}/abe.git~staging" +if (cd "${local_snapshots}" && \ + if test x"${debug}" = xyes; then checkout "${in}~staging" > /dev/null; else + checkout "${in}~staging" >/dev/null 2>&1; fi && \ + test `ls | wc -l` -eq 2 && \ + ls abe.git > /dev/null && \ + ls abe.git~staging > /dev/null); then + pass "${testing}" +else + fail "${testing}" +fi + test_checkout () { local should="$1" |