Skip to content

Commit

Permalink
fix: shellcheck warnings in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
benmcclelland committed Jun 10, 2024
1 parent 0d5cc61 commit 8267a7a
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion tests/commands/create_multipart_upload.sh
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ create_multipart_upload_custom() {
local multipart_data
log 5 "additional create multipart params"
for i in "$@"; do
log 5 $i
log 5 "$i"
done
log 5 "${*:3}"
log 5 "aws --no-verify-ssl s3api create-multipart-upload --bucket $1 --key $2 ${*:3}"
Expand Down
1 change: 0 additions & 1 deletion tests/commands/list_buckets.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ list_buckets() {
fi

local exit_code=0
local error
if [[ $1 == 's3' ]]; then
buckets=$(aws --no-verify-ssl s3 ls 2>&1 s3://) || exit_code=$?
elif [[ $1 == 's3api' ]] || [[ $1 == 'aws' ]]; then
Expand Down
1 change: 1 addition & 0 deletions tests/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -88,4 +88,5 @@ case $command_type in
;;
esac

# shellcheck disable=SC2086
exit $exit_code
3 changes: 3 additions & 0 deletions tests/util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -231,6 +231,7 @@ object_exists() {
echo "error checking if object exists"
return 2
fi
# shellcheck disable=SC2086
return $head_result
}

Expand Down Expand Up @@ -493,6 +494,7 @@ check_object_tags_empty() {
return 2
fi
check_tags_empty "$1" || local check_result=$?
# shellcheck disable=SC2086
return $check_result
}

Expand All @@ -506,6 +508,7 @@ check_bucket_tags_empty() {
return 2
fi
check_tags_empty "$1" || local check_result=$?
# shellcheck disable=SC2086
return $check_result
}

Expand Down

0 comments on commit 8267a7a

Please sign in to comment.