Skip to content

Commit

Permalink
fix: add one more string to detect unregistered insights-client status
Browse files Browse the repository at this point in the history
Add part of the error string shown by insights-client in case the
underlying system is not registered with subscription-manager, and
insights-client is not configured for BASIC authentication.

Signed-off-by: Pino Toscano <[email protected]>
  • Loading branch information
ptoscano committed Feb 28, 2024
1 parent 5b67193 commit 0a7b109
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pytest_client_tools/insights_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ def __init__(self):
def is_registered(self):
proc = self.run("--status", check=False)
if proc.returncode in [0, 1] and any(
i in proc.stdout for i in ["NOT", "unregistered"]
i in proc.stdout for i in ["NOT", "unregistered", "401: Unauthorized"]
):
return False
if proc.returncode == 0 and any(
Expand Down

0 comments on commit 0a7b109

Please sign in to comment.