Francesco Romani has uploaded a new change for review.

Change subject: tests: fix pep8 errors
......................................................................

tests: fix pep8 errors

Commit: ff6f1bd45ddd7e019761d81aa2a338cf58e15caf
introduced a couple of pep8 errors in tests.
This patch fixes that.

Change-Id: Ieefeb049d295ed89cdfedc7ccc9daee05b7de712
Signed-off-by: Francesco Romani <[email protected]>
---
M tests/vmTests.py
1 file changed, 4 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/60/29960/1

diff --git a/tests/vmTests.py b/tests/vmTests.py
index 2be5282..45578c6 100644
--- a/tests/vmTests.py
+++ b/tests/vmTests.py
@@ -24,7 +24,7 @@
 import re
 import shutil
 import tempfile
-import xml.dom.minidom
+from xml.dom.minidom import Element as XMLElement
 import xml.etree.ElementTree as ET
 
 import libvirt
@@ -62,7 +62,7 @@
 
     def _failIfRequested(self):
         if self._virtError != libvirt.VIR_ERR_OK:
-            err =  libvirt.libvirtError(defmsg='')
+            err = libvirt.libvirtError(defmsg='')
             err.err = [self._virtError]
             raise err
 
@@ -879,15 +879,13 @@
     def testGetVmPolicySucceded(self):
         with FakeVM() as fake:
             fake._dom = FakeDomain()
-            self.assertTrue(isinstance(fake._getVmPolicy(),
-                                       xml.dom.minidom.Element))
+            self.assertTrue(isinstance(fake._getVmPolicy(), XMLElement))
 
     def testGetVmPolicyEmptyOnNoMetadata(self):
         with FakeVM() as fake:
             fake._dom = FakeDomain(
                 virtError=libvirt.VIR_ERR_NO_DOMAIN_METADATA)
-            self.assertTrue(isinstance(fake._getVmPolicy(),
-                                       xml.dom.minidom.Element))
+            self.assertTrue(isinstance(fake._getVmPolicy(), XMLElement))
 
     def testGetVmPolicyFailOnNoDomain(self):
         with FakeVM() as fake:


-- 
To view, visit http://gerrit.ovirt.org/29960
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ieefeb049d295ed89cdfedc7ccc9daee05b7de712
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Francesco Romani <[email protected]>
_______________________________________________
vdsm-patches mailing list
[email protected]
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches

Reply via email to