Skip flaky yaml output test
There seems to be little point in comparing YAML output as plain text, which is also subject to fields being listed in a different order, when the parsed output (which should be all that matters) is subsequently being compared.
This commit is contained in:
parent
29588c2967
commit
c18f1ec67f
@ -19,6 +19,8 @@ Patch0: ruamel-yaml-0.17.32.patch
|
|||||||
Patch1: python312.patch
|
Patch1: python312.patch
|
||||||
# fix incorrect assertions in TestKubeconfigLoader
|
# fix incorrect assertions in TestKubeconfigLoader
|
||||||
Patch2: assertions.patch
|
Patch2: assertions.patch
|
||||||
|
# skip flaky test which compares yaml output as plain text
|
||||||
|
Patch3: test-yaml.patch
|
||||||
|
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
|
|
||||||
|
16
test-yaml.patch
Normal file
16
test-yaml.patch
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
The raw YAML output fields are sometimes printed in non-alphabetical
|
||||||
|
order, causing the raw text comparison to sometimes fail. The parsed
|
||||||
|
output is subsequently compared, and that should be all that matters.
|
||||||
|
|
||||||
|
diff --git a/tests/unit/output/test_yaml_output.py b/tests/unit/output/test_yaml_output.py
|
||||||
|
index b5e3a0a..88132f7 100644
|
||||||
|
--- a/tests/unit/output/test_yaml_output.py
|
||||||
|
+++ b/tests/unit/output/test_yaml_output.py
|
||||||
|
@@ -62,7 +62,6 @@ class TestYAMLOutput(BaseAWSCommandParamsTest):
|
||||||
|
" UserId: EXAMPLEUSERID\n"
|
||||||
|
" UserName: testuser-51\n"
|
||||||
|
)
|
||||||
|
- self.assertEqual(stdout, expected)
|
||||||
|
parsed_output = self.yaml.load(stdout)
|
||||||
|
self.assertEqual(self.parsed_response, parsed_output)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user