File tree Expand file tree Collapse file tree 2 files changed +20
-20
lines changed Expand file tree Collapse file tree 2 files changed +20
-20
lines changed Original file line number Diff line number Diff line change @@ -17,4 +17,4 @@ echo "Sourcing env variables for ${CODE_SNIPPETS_FLAVOR} flavor"
17
17
test -f " ${test_dir} /env_variables_${CODE_SNIPPETS_FLAVOR} .sh" && source " ${test_dir} /env_variables_${CODE_SNIPPETS_FLAVOR} .sh"
18
18
19
19
${test_dir} /test.sh
20
- scripts/code_snippets/kind_community_search_snippets_render_template.sh
20
+ scripts/code_snippets/kind_community_search_snippets_render_template.sh " ${test_dir} "
Original file line number Diff line number Diff line change @@ -106,26 +106,26 @@ dump_objects() {
106
106
return
107
107
fi
108
108
109
- # Capture output first to check if it contains actual resources
110
- local temp_output
111
- temp_output=$( kubectl --context=" ${context} " -n " ${namespace} " ${action} " ${object} " 2>&1 )
112
-
113
- # Check if output contains actual resources (not just empty list)
114
- # Skip if it's an empty YAML list (contains "items: []")
115
- if printf ' %s\n' " ${temp_output} " | grep -Fq " items: []" ; then
116
- # Empty list, don't create file
117
- return
118
- fi
119
-
120
- if [[ -n " ${out_file} " ]]; then
121
- {
122
- header " ${msg} "
123
- echo " ${temp_output} "
124
- } > " ${out_file} "
125
- else
109
+ # Capture output first to check if it contains actual resources
110
+ local temp_output
111
+ temp_output=$( kubectl --context=" ${context} " -n " ${namespace} " ${action} " ${object} " 2>&1 )
112
+
113
+ # Check if output contains actual resources (not just empty list)
114
+ # Skip if it's an empty YAML list (contains "items: []")
115
+ if printf ' %s\n' " ${temp_output} " | grep -Fq " items: []" ; then
116
+ # Empty list, don't create file
117
+ return
118
+ fi
119
+
120
+ if [[ -n " ${out_file} " ]]; then
121
+ {
126
122
header " ${msg} "
127
- kubectl --context=" ${context} " -n " ${namespace} " ${action} " ${object} " 2>&1
128
- fi
123
+ echo " ${temp_output} "
124
+ } > " ${out_file} "
125
+ else
126
+ header " ${msg} "
127
+ kubectl --context=" ${context} " -n " ${namespace} " ${action} " ${object} " 2>&1
128
+ fi
129
129
}
130
130
131
131
# get_operator_managed_pods returns a list of names of the Pods that are managed
You can’t perform that action at this time.
0 commit comments