From f30d61201d0b01b04d3e204c727ad070fc6b8e32 Mon Sep 17 00:00:00 2001 From: Michel Alexandre Salim Date: Fri, 9 Jul 2010 19:41:38 +0100 Subject: [PATCH] Unit-tests only passed on x86_64 systems In the testPorts function, the machine type was hardcoded to x86_64, even though self.feed.implementations' entry would have a machine type that corresponded to the host machine's machine type, and not always x86_64. --- tests/testdistro.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/testdistro.py b/tests/testdistro.py index 962ee0b..05f6a7e 100755 --- a/tests/testdistro.py +++ b/tests/testdistro.py @@ -207,9 +207,9 @@ class TestDistro(BaseTest): factory = self.make_factory(ports) ports.get_package_info('zeroinstall-injector', factory) self.assertEquals(1, len(self.feed.implementations)) - impl = self.feed.implementations['package:ports:zeroinstall-injector:0.41-2:x86_64'] + impl = self.feed.implementations['package:ports:zeroinstall-injector:0.41-2:' + distro.host_machine] self.assertEquals('0.41-2', impl.get_version()) - self.assertEquals('x86_64', impl.machine) + self.assertEquals(distro.host_machine, impl.machine) def testCleanVersion(self): self.assertEquals('0.3.1-1', distro.try_cleanup_distro_version('1:0.3.1-1')) -- 2.11.4.GIT