Skip to content

Commit

Permalink
[6.16.z] less fragile string comparison in negative domain test (#17513)
Browse files Browse the repository at this point in the history
  • Loading branch information
Satellite-QE authored Feb 5, 2025
1 parent a0fe930 commit 229c370
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/foreman/cli/test_domain.py
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,9 @@ def test_negative_create_with_invalid_dns_id(module_target_sat):
module_target_sat.cli_factory.make_domain({'name': gen_string('alpha'), 'dns-id': -1})
valid_messages = ['Invalid smart-proxy id', 'Invalid capsule id']
exception_string = str(context.value)
messages = [message for message in valid_messages if message in exception_string]
messages = [
message for message in valid_messages if message.lower() in exception_string.lower()
]
assert len(messages) > 0


Expand Down

0 comments on commit 229c370

Please sign in to comment.