The "logs" property has been removed from the specification of the
test and build messages, so the functions in the respective modules
that access these properties must be removed as well.
This commit removes the foundry_msg_build_get_logs() and
foundry_msg_test_get_logs() functions and removes the logs parameter
from the foundry_msg_test_new() and foundry_msg_build_new() functions.
local branch="$3"
local commit="$4"
local result="$5"
- local -n __foundry_msg_build_new_logs="$6"
- local -n __foundry_msg_build_new_artifacts="$7"
+ local -n __foundry_msg_build_new_artifacts="$6"
local artifact_array
- local log_array
local json
local msg
return 1
fi
- if ! log_array=$(json_array "${__foundry_msg_build_new_logs[@]}"); then
- return 1
- fi
-
if ! json=$(json_object "context" "$context" \
"repository" "$repository" \
"branch" "$branch" \
"commit" "$commit" \
"result" "$result" \
- "logs" "$log_array" \
"artifacts" "$artifact_array"); then
return 1
fi
return 0
}
-foundry_msg_build_get_logs() {
- local msg="$1"
-
- local logs
-
- if ! logs=$(foundry_msg_get_data_field "$msg" "logs[]"); then
- return 1
- fi
-
- echo "$logs"
- return 0
-}
-
foundry_msg_build_get_artifacts() {
local msg="$1"
local branch="$3"
local commit="$4"
local result="$5"
- local logs=("${@:6}")
- local logs_json
local json
local msg
- if ! logs_json=$(json_array "${logs[@]}"); then
- return 1
- fi
-
if ! json=$(json_object "context" "$context" \
"repository" "$repository" \
"branch" "$branch" \
"commit" "$commit" \
- "result" "$result" \
- "logs" "$logs_json"); then
+ "result" "$result"); then
return 1
fi
echo "$result"
return 0
}
-
-foundry_msg_test_get_logs() {
- local msg="$1"
-
- local logs
-
- if ! logs=$(foundry_msg_get_data_field "$msg" "logs[]"); then
- return 1
- fi
-
- echo "$logs"
- return 0
-}