[libvirt PATCH 2/3] tests: Fix flake8 errors in virsh-auth

Andrea Bolognani posted 3 patches 4 years, 10 months ago
[libvirt PATCH 2/3] tests: Fix flake8 errors in virsh-auth
Posted by Andrea Bolognani 4 years, 10 months ago
Specifically

  E111 indentation is not a multiple of four

This commit is better viewed with 'git show -w'.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
---
 tests/virsh-auth | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/tests/virsh-auth b/tests/virsh-auth
index d548694190..ce3a599107 100755
--- a/tests/virsh-auth
+++ b/tests/virsh-auth
@@ -24,11 +24,11 @@ import subprocess
 
 builddir = os.getenv("abs_top_builddir")
 if builddir is None:
-   builddir = os.path.join(os.getcwd(), "..")
+    builddir = os.path.join(os.getcwd(), "..")
 
 srcdir = os.getenv("abs_top_srcdir")
 if srcdir is None:
-   srcdir = os.path.abspath(os.path.join(os.path.dirname(__file__), ".."))
+    srcdir = os.path.abspath(os.path.join(os.path.dirname(__file__), ".."))
 
 uri = "test://" + os.path.join(srcdir, "tests", "virsh-auth.xml")
 
@@ -43,15 +43,15 @@ proc = subprocess.Popen([virsh, "-c", uri, "uri"],
 out, err = proc.communicate("astrochicken")
 
 if proc.returncode != 0:
-   print("virsh failed with code %d" % proc.returncode, file=sys.stderr)
-   if out != "":
-      print("stdout=%s" % out)
-   if err != "":
-      print("stderr=%s" % err)
-   sys.exit(1)
+    print("virsh failed with code %d" % proc.returncode, file=sys.stderr)
+    if out != "":
+        print("stdout=%s" % out)
+    if err != "":
+        print("stderr=%s" % err)
+    sys.exit(1)
 
 if uri not in out:
-   print("Expected '%s' in '%s'" % (uri, out), file=sys.stderr)
-   sys.exit(1)
+    print("Expected '%s' in '%s'" % (uri, out), file=sys.stderr)
+    sys.exit(1)
 
 sys.exit(0)
-- 
2.26.3

Re: [libvirt PATCH 2/3] tests: Fix flake8 errors in virsh-auth
Posted by Erik Skultety 4 years, 10 months ago
On Fri, Mar 19, 2021 at 06:39:30PM +0100, Andrea Bolognani wrote:
> Specifically
> 
>   E111 indentation is not a multiple of four
> 
> This commit is better viewed with 'git show -w'.
> 
> Signed-off-by: Andrea Bolognani <abologna@redhat.com>
> ---
Reviewed-by: Erik Skultety <eskultet@redhat.com>