forked from LaconicNetwork/kompose
Fix docker local build (#1212)
This commit is contained in:
@@ -70,6 +70,16 @@ function convert::run_cmd() {
|
||||
}
|
||||
readonly -f convert::run_cmd
|
||||
|
||||
|
||||
function convert::expect_cmd_success() {
|
||||
local cmd=$1
|
||||
|
||||
convert::start_test "convert::expect_cmd_success: Running: '${cmd}'"
|
||||
|
||||
convert::run_cmd $cmd
|
||||
exit_status=$?
|
||||
if [ $exit_status -ne 0 ]; then FAIL_MSGS=$FAIL_MSGS"exit status: $exit_status\n"; return $exit_status; fi
|
||||
}
|
||||
# run the command and match the output to the existing file
|
||||
# if error then save error string in FAIL_MSGS
|
||||
# if success save pass string in SUCCESS_MSGS
|
||||
|
||||
@@ -537,6 +537,14 @@ cd $CURRENT_DIR
|
||||
|
||||
|
||||
|
||||
#### Test docker build feature
|
||||
cmd="kompose convert -f $KOMPOSE_ROOT/script/test/fixtures/buildconfig/docker-compose-dockerfile.yml --stdout -j --build=local"
|
||||
convert::expect_cmd_success "$cmd"
|
||||
|
||||
cmd="kompose convert --provider openshift -f $KOMPOSE_ROOT/script/test/fixtures/buildconfig/docker-compose-dockerfile.yml --stdout -j --build=local"
|
||||
convert::expect_cmd_success "$cmd"
|
||||
|
||||
|
||||
# Test the presence of build args in buildconfig
|
||||
# Replacing variables with current branch and uri
|
||||
# Test BuildConfig
|
||||
|
||||
Reference in New Issue
Block a user