Skip to content

Commit

Permalink
client registration with capsule based on setting value, fixed error
Browse files Browse the repository at this point in the history
  • Loading branch information
vijaysawant committed Jun 19, 2024
1 parent f5b556f commit 76563bb
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/foreman/cli/test_host.py
Original file line number Diff line number Diff line change
Expand Up @@ -2734,8 +2734,8 @@ def test_positive_host_registration_with_capsule(
assert result.status == 0, f'Failed to register host: {result.stderr}'

# Check output for "HTTP error code 422: Validation failed: Content view environment content facets is invalid"
assert "Validation failed" in str(result.stderr[1]), f"Error is: {result.stderr}"
assert "HTTP error code 422" in str(result.stderr[1]), f"Error is: {result.stderr}"
assert "Validation failed" in str(result.stderr), f"Error is: {result.stderr}"
assert "HTTP error code 422" in str(result.stderr), f"Error is: {result.stderr}"
rhel_contenthost.unregister()

# Re-register client with settings "validate_host_lce_content_source_coherence" is set to No
Expand All @@ -2748,6 +2748,6 @@ def test_positive_host_registration_with_capsule(
assert result.status == 0, f'Failed to register host: {result.stderr}'

# Check output there should not any error like "Validation failed" or "HTTP error code 422"
assert "Validation failed" not in str(result.stderr[1]), f"Error is: {result.stderr}"
assert "HTTP error code 422" not in str(result.stderr[1]), f"Error is: {result.stderr}"
assert "Validation failed" not in str(result.stderr), f"Error is: {result.stderr}"
assert "HTTP error code 422" not in str(result.stderr), f"Error is: {result.stderr}"
rhel_contenthost.unregister()

0 comments on commit 76563bb

Please sign in to comment.