Move remaining util functions to tasks module

https://pagure.io/freeipa/issue/6798
Signed-off-by: Christian Heimes <cheimes@redhat.com>
Reviewed-By: Milan Kubik <mkubik@redhat.com>
This commit is contained in:
Christian Heimes
2017-03-21 16:33:34 +01:00
committed by Tomas Krizek
parent 5587a37e23
commit 24161a6190
4 changed files with 38 additions and 61 deletions

View File

@@ -21,8 +21,7 @@ import pytest
from ipatests.test_integration.base import IntegrationTest
from ipatests.pytest_plugins.integration.tasks import (
clear_sssd_cache, modify_sssd_conf)
from ipatests.test_integration import util
clear_sssd_cache, get_host_ip_with_hostmask, modify_sssd_conf)
class TestSudo(IntegrationTest):
@@ -299,7 +298,7 @@ class TestSudo(IntegrationTest):
def test_sudo_rule_restricted_to_one_hostmask_setup(self):
# We need to detect the hostmask first
full_ip = util.get_host_ip_with_hostmask(self.client)
full_ip = get_host_ip_with_hostmask(self.client)
# Make a note for the next test, which needs to be skipped
# if hostmask detection failed
@@ -342,7 +341,7 @@ class TestSudo(IntegrationTest):
raise pytest.skip("Hostmask could not be detected")
# Detect the hostmask first to delete the hostmask based rule
full_ip = util.get_host_ip_with_hostmask(self.client)
full_ip = get_host_ip_with_hostmask(self.client)
# Remove the client's hostmask from the rule
self.master.run_command(['ipa', '-n', 'sudorule-remove-host',