Blame SOURCES/0005-Drop-an-unnecessary-Python-2-vs-3-incompatibility-fr.patch

ed184b
From 98470eccf09b80ed11528ac893852d649c50be72 Mon Sep 17 00:00:00 2001
ed184b
Message-Id: <98470eccf09b80ed11528ac893852d649c50be72.1571920849.git.pmatilai@redhat.com>
ed184b
In-Reply-To: <6b6c4d881dc6fc99f949dac4aaf9a513542f9956.1571920849.git.pmatilai@redhat.com>
ed184b
References: <6b6c4d881dc6fc99f949dac4aaf9a513542f9956.1571920849.git.pmatilai@redhat.com>
ed184b
From: Panu Matilainen <pmatilai@redhat.com>
ed184b
Date: Fri, 5 Oct 2018 14:05:27 +0300
ed184b
Subject: [PATCH 5/5] Drop an unnecessary Python 2 vs 3 incompatibility from
ed184b
 the test
ed184b
ed184b
Python 2 speaks about 'type' whereas 3 speaks about 'class', which from
ed184b
our perspective is just unnecessary pain with no gain.
ed184b
ed184b
(cherry picked from commit ff3d8ac2e5cb4456ad1355f227f3ccef08e01972)
ed184b
---
ed184b
 tests/rpmpython.at | 3 +--
ed184b
 1 file changed, 1 insertion(+), 2 deletions(-)
ed184b
ed184b
diff --git a/tests/rpmpython.at b/tests/rpmpython.at
ed184b
index ae020ae95..bc42e49e4 100644
ed184b
--- a/tests/rpmpython.at
ed184b
+++ b/tests/rpmpython.at
ed184b
@@ -92,7 +92,7 @@ h['arch'] = 'noarch'
ed184b
 myprint(h['nevra'])
ed184b
 del h['epoch']
ed184b
 myprint(h['nevra'])
ed184b
-for a in ['name', 'bugurl', '__class__', '__foo__', ]:
ed184b
+for a in ['name', 'bugurl', '__foo__', ]:
ed184b
     try:
ed184b
         x = getattr(h, a)
ed184b
         myprint(x)
ed184b
@@ -103,7 +103,6 @@ for a in ['name', 'bugurl', '__class__', '__foo__', ]:
ed184b
 testpkg-1.0-1.noarch
ed184b
 testpkg
ed184b
 None
ed184b
-<type 'rpm.hdr'>
ed184b
 'rpm.hdr' object has no attribute '__foo__']
ed184b
 )
ed184b
 
ed184b
-- 
ed184b
2.21.0
ed184b