ipatests: check that the output of sudo -V is not displayed

During client installation, the installer calls sudo -V
to check if sudo command is installed. The output must not
be displayed in stdout.

Related: https://pagure.io/freeipa/issue/8767
Reviewed-By: Rob Crittenden <rcritten@redhat.com>
This commit is contained in:
Florence Blanc-Renaud 2021-04-13 10:28:26 +02:00
parent ec8d72cf7c
commit 058a9c01c7

View File

@ -1561,6 +1561,7 @@ class TestInstallWithoutSudo(IntegrationTest):
num_clients = 1
num_replicas = 1
no_sudo_str = "The sudo binary does not seem to be present on this"
sudo_version_str = "Sudo version"
@classmethod
def install(cls, mh):
@ -1622,3 +1623,4 @@ class TestInstallWithoutSudo(IntegrationTest):
assert tasks.is_package_installed(self.clients[0], pkg)
result = tasks.install_client(self.master, self.clients[0])
assert self.no_sudo_str not in result.stderr_text
assert self.sudo_version_str not in result.stdout_text