mirror of
https://github.com/k3s-io/k3s.git
synced 2024-06-07 19:41:36 +00:00
Improve sonobuoy status output handling
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
This commit is contained in:
parent
97a606bac1
commit
fd991cb964
@ -171,12 +171,12 @@ export -f dump-logs
|
||||
# ---
|
||||
|
||||
retrieve-sonobuoy-logs() {
|
||||
sonobuoy status || true
|
||||
|
||||
local status=passed
|
||||
local code=0
|
||||
local testStatus=$(sonobuoy status 2>&1)
|
||||
cat <<< $testStatus
|
||||
|
||||
if ! sonobuoy status | grep -q -E ' +e2e +complete +passed +'; then
|
||||
if ! grep -q -E '\s+e2e\s+complete\s+passed\s+' <<< $testStatus; then
|
||||
status=failed
|
||||
code=1
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user