aboutsummaryrefslogtreecommitdiffstats
path: root/docker/exec_tests.sh
diff options
context:
space:
mode:
authorchenjiankun <chenjiankun1@huawei.com>2017-03-27 02:18:05 +0000
committerchenjiankun <chenjiankun1@huawei.com>2017-03-27 02:56:15 +0000
commit473a5a1d3a463dd0c47c0785094f7ed0e821b399 (patch)
tree0804b8e996fabb8f40d3e6576513dfe71e14e454 /docker/exec_tests.sh
parentc7114df918ca1d463e49a1c41805e8f414100e7c (diff)
pathspec 'master' did not match any file(s) known to git
JIRA: YARDSTICK-605 On stable branch, exec_tests.sh will also try to git checkout master branch, which cause error "pathspec 'master' did not match any file(s) known to git." This is a remianing bug from the previous release. see at: https://build.opnfv.org/ci/view/yardstick/job/yardstick-apex-lf-pod1-daily-danube/62/console This error occur in line 48. But the reason is 'set -e' If we set 'set -e': 'git checkout master && git pull' return 1 but it will go on executing; but 'git checkout master' will return 1 and terminate immediately. If we do not set, it will return 1 but will terminate immediately. Actually we not need 'git checkout master' here because it is already in stable/danube branch. So I remove it. Change-Id: I106a1da28cf2deee90ebcb25adaf638a210928ee Signed-off-by: chenjiankun <chenjiankun1@huawei.com>
Diffstat (limited to 'docker/exec_tests.sh')
-rwxr-xr-xdocker/exec_tests.sh3
1 files changed, 1 insertions, 2 deletions
diff --git a/docker/exec_tests.sh b/docker/exec_tests.sh
index 5e0d30453..db053f7bc 100755
--- a/docker/exec_tests.sh
+++ b/docker/exec_tests.sh
@@ -22,7 +22,7 @@ git_checkout()
{
if git cat-file -e $1^{commit} 2>/dev/null; then
# branch, tag or sha1 object
- git checkout $1
+ git checkout $1 && git pull
else
# refspec / changeset
git fetch --tags --progress $2 $1
@@ -45,7 +45,6 @@ if [ ! -d $YARDSTICK_REPO_DIR ]; then
git clone $YARDSTICK_REPO $YARDSTICK_REPO_DIR
fi
cd $YARDSTICK_REPO_DIR
-git checkout master
git_checkout $YARDSTICK_BRANCH $YARDSTICK_REPO
# setup the environment