Tim Lauridsen wrote:
Have some problems applying the patch to yum master, it is complaining about a missing file.

Ehm, true. The patches I sent yesterday are not in yet. Try the one attached here.

Florian
>From 63c4b930e8423fea486aca72a3eb735a5c656800 Mon Sep 17 00:00:00 2001
From: Florian Festi <[EMAIL PROTECTED]>
Date: Tue, 6 Nov 2007 11:51:04 +0100
Subject: [PATCH] Set arch for the depsolving/operation test cases

---
 test/testbase.py |    9 +++++++++
 1 files changed, 9 insertions(+), 0 deletions(-)

diff --git a/test/testbase.py b/test/testbase.py
index 33fa803..3c90636 100644
--- a/test/testbase.py
+++ b/test/testbase.py
@@ -17,6 +17,7 @@ from yum import packageSack
 from yum.constants import TS_INSTALL_STATES, TS_REMOVE_STATES
 from cli import YumBaseCli
 import inspect
+from rpmUtils import arch
 
 #############################################################
 ### Helper classes ##########################################
@@ -82,12 +83,19 @@ class _Container(object):
 class _DepsolveTestsBase(unittest.TestCase):
 
     res = {0 : 'empty', 2 : 'ok', 1 : 'err'}
+    canonArch = "x86_64"
 
     def __init__(self, methodName='runTest'):
         unittest.TestCase.__init__(self, methodName)
         self.pkgs = _Container()
         self.buildPkgs(self.pkgs)
 
+    def setUp(self):
+        self._canonArch = arch.canonArch
+        arch.canonArch = self.canonArch
+    def tearDown(self):
+        arch.canonArch = self._canonArch
+
     @staticmethod
     def buildPkgs(pkgs, *args):
         """Overload this staticmethod to create pkpgs that are used in several
@@ -158,6 +166,7 @@ class DepsolveTests(_DepsolveTestsBase):
 
     def setUp(self):
         """ Called at the start of each test. """
+        _DepsolveTestsBase.setUp(self)
         self.tsInfo = transactioninfo.TransactionData()
         self.rpmdb  = packageSack.PackageSack()
         self.xsack  = packageSack.PackageSack()
-- 
1.5.3.3

_______________________________________________
Yum-devel mailing list
[email protected]
https://lists.dulug.duke.edu/mailman/listinfo/yum-devel

Reply via email to