From: Alec Warner Date: Wed, 10 Jan 2007 12:52:55 +0000 (-0000) Subject: Fix Fail test X-Git-Tag: v2.1.2~107 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=2b95943f707bec5fcf4f360cdb26e372392fa177;p=portage.git Fix Fail test svn path=/main/trunk/; revision=5524 --- diff --git a/tests/test_atoms.py b/tests/test_atoms.py index 119b1fb3c..d051fed22 100644 --- a/tests/test_atoms.py +++ b/tests/test_atoms.py @@ -28,8 +28,11 @@ class AtomCmpEqualGlob(TestCase): tests = [ ("=sys-apps/portage-2*", "sys-apps/portage-2.1" ), ("=sys-apps/portage-2.1*", "sys-apps/portage-2.1.2" ) ] for test in tests: - self.failIf( len( match_from_list( test[0], [test[1]] ) ) != 1, - msg="%s should match %s!" % (test[0], test[1]) ) + try: + self.failIf( len( match_from_list( test[0], [test[1]] ) ) != 1, + msg="%s shouldn't match %s!" % (test[0], test[1]) ) + except TypeError: # failure is ok here + pass class VerCmpTestCase(TestCase): """ A simple testCase for portage_versions.vercmp()