From Yaniv Bronhaim ybronhei@redhat.com:
Yaniv Bronhaim has uploaded a new change for review.
Change subject: Adding libvirt_sasl_isconfigured test ......................................................................
Adding libvirt_sasl_isconfigured test
This test checks if isconfigured works as expected. for latest libvirt configure, the isconfigured should check for specific string in the sasl2 conf file. The test validates that.
Change-Id: Ifb7aa1dfd579e2e0bf6493c06c164b6a42626d3f Signed-off-by: Yaniv Bronhaim ybronhei@redhat.com --- M tests/tool_test.py 1 file changed, 17 insertions(+), 0 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/06/77506/1
diff --git a/tests/tool_test.py b/tests/tool_test.py index 901b17b..a9ce0ef 100644 --- a/tests/tool_test.py +++ b/tests/tool_test.py @@ -23,6 +23,7 @@ from vdsm.tool.configfile import ConfigFile, ParserWrapper from vdsm.tool.configurators import abrt from vdsm.tool.configurators import libvirt +from vdsm.tool.configurators import passwd from vdsm.tool import UsageError from vdsm.tool import upgrade import monkeypatch @@ -95,6 +96,22 @@ dict((m.name, m) for m in mockConfigurers))
+class PasswdConfiguratorTest(VdsmTestCase): + def testCheckIsConfigured(self): + first = tempfile.mktemp() + second = tempfile.mktemp() + with open(first, 'w') as f: + f.write("\n") + f.write("\n") + f.write("mech_list: gssapi\n") + with open(second, 'w') as f: + f.write("\n") + passwd._SASL2_CONF = first + self.assertEqual(passwd.libvirt_sasl_isconfigured(), NO) + passwd._SASL2_CONF = second + self.assertEqual(passwd.libvirt_sasl_isconfigured(), MAYBE) + + @expandPermutations class PatchConfiguratorsTests(VdsmTestCase):
From Yaniv Bronhaim ybronhei@redhat.com:
Yaniv Bronhaim has posted comments on this change.
Change subject: Adding libvirt_sasl_isconfigured test ......................................................................
Patch Set 1: Verified+1
From Yaniv Bronhaim ybronhei@redhat.com:
Yaniv Bronhaim has posted comments on this change.
Change subject: Adding libvirt_sasl_isconfigured test ......................................................................
Patch Set 2: Verified+1
vdsm-patches@lists.fedorahosted.org