Skip to content

Commit 4f7143a

Browse files
Merge pull request #18098 from ironcladlou/observe-flake
Automatic merge from submit-queue (batch tested with PRs 18040, 18097, 18098, 18106, 18087). Stabilize observe test Stabilize the observe cmd test by removing the assumption that all services lack annotations. Fixes #17811.
2 parents 302b11f + 37f2025 commit 4f7143a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/cmd/observe.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@ os::cmd::expect_failure_and_text 'oc observe services --exit-after=1m --all-name
3030
# argument templates
3131
os::cmd::expect_success_and_text 'oc observe services --once --all-namespaces -a "{ .spec.clusterIP }"' '172.30.0.1'
3232
os::cmd::expect_success_and_text 'oc observe services --once --all-namespaces -a "{{ .spec.clusterIP }}" --output=gotemplate' '172.30.0.1'
33-
os::cmd::expect_success_and_text 'oc observe services --once --all-namespaces -a "bad{ .metadata.annotations.unset }key"' 'badkey'
34-
os::cmd::expect_failure_and_text 'oc observe services --once --all-namespaces -a "bad{ .metadata.annotations.unset }key" --strict-templates' 'annotations is not found'
33+
os::cmd::expect_success_and_text 'oc observe services --once --all-namespaces -a "bad{ .missingkey }key"' 'badkey'
34+
os::cmd::expect_failure_and_text 'oc observe services --once --all-namespaces -a "bad{ .missingkey }key" --strict-templates' 'missingkey is not found'
3535
os::cmd::expect_success_and_text 'oc observe services --once --all-namespaces -a "{{ .unknown }}" --output=gotemplate' '""'
3636
os::cmd::expect_success_and_text 'oc observe services --once --all-namespaces -a "bad{{ or (.unknown) \"\" }}key" --output=gotemplate' 'badkey'
3737
os::cmd::expect_success_and_text 'oc observe services --once --all-namespaces -a "bad{{ .unknown }}key" --output=gotemplate --strict-templates' '\<no value\>'

0 commit comments

Comments
 (0)