Gentoo Archives: gentoo-commits

From: "Zac Medico (zmedico)" <zmedico@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] portage r12716 - in main/trunk/pym/portage: dbapi tests/dep
Date: Fri, 27 Feb 2009 00:03:28
Message-Id: E1LcqCM-0001Ln-UY@stork.gentoo.org
1 Author: zmedico
2 Date: 2009-02-27 00:03:26 +0000 (Fri, 27 Feb 2009)
3 New Revision: 12716
4
5 Modified:
6 main/trunk/pym/portage/dbapi/porttree.py
7 main/trunk/pym/portage/tests/dep/test_src_uri.py
8 Log:
9 Fix a case in which a SRC_URI is incorrectly idendified as invalid, and add
10 a corresponding test case. Thanks to Jacob Floyd for reporting.
11
12
13 Modified: main/trunk/pym/portage/dbapi/porttree.py
14 ===================================================================
15 --- main/trunk/pym/portage/dbapi/porttree.py 2009-02-26 08:40:41 UTC (rev 12715)
16 +++ main/trunk/pym/portage/dbapi/porttree.py 2009-02-27 00:03:26 UTC (rev 12716)
17 @@ -66,6 +66,9 @@
18 "supported with EAPI='%s'") % (cpv, eapi))
19 operator = x
20 continue
21 + if operator is None:
22 + uri = x
23 + continue
24 if operator is not None:
25 if "/" in x:
26 raise portage.exception.InvalidDependString(
27
28 Modified: main/trunk/pym/portage/tests/dep/test_src_uri.py
29 ===================================================================
30 --- main/trunk/pym/portage/tests/dep/test_src_uri.py 2009-02-26 08:40:41 UTC (rev 12715)
31 +++ main/trunk/pym/portage/tests/dep/test_src_uri.py 2009-02-27 00:03:26 UTC (rev 12716)
32 @@ -23,6 +23,7 @@
33 ( "2", "http://foo/bar ->" , False ),
34 ( "2", "foo? ( http://foo/bar -> ) blah.tbz2" , False ),
35 ( "2", "http://foo/bar -> foo/blah.tbz2" , False ),
36 + ( "2", "http://foo.com/foo http://foo/bar -> blah.tbz2" , True ),
37 ]
38
39 for eapi, src_uri, valid in tests: