File tree Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -249,6 +249,11 @@ function check_image_variable_matches_name_and_commitref_and_size() {
249249 }
250250
251251 # Check the size change constraints now
252+ if test -z " ${expected_img_size} " || test " ${expected_img_size} " -eq 0; then
253+ echo " Expected image size is undefined or empty, please check the pre-defined values!"
254+ return 1
255+ fi
256+
252257 # 1. Percentual size change
253258 percent_change=$(( 100 * actual_img_size / expected_img_size - 100 ))
254259 abs_percent_change=${percent_change# -* }
Original file line number Diff line number Diff line change @@ -58,6 +58,11 @@ function check_image_size() {
5858 esac
5959
6060 # Check the size change constraints now
61+ if test -z " ${expected_img_size} " || test " ${expected_img_size} " -eq 0; then
62+ echo " Expected image size is undefined or empty, please check the pre-defined values!"
63+ return 1
64+ fi
65+
6166 # 1. Percentual size change
6267 percent_change=$(( 100 * actual_img_size / expected_img_size - 100 ))
6368 abs_percent_change=${percent_change# -* }
You can’t perform that action at this time.
0 commit comments