From fe1194b25031f40e51d1a82352bb7d79bcafe912 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Thu, 3 Jan 2013 20:35:40 -0800 Subject: test_paren_reduce: disable deprecation warning --- pym/portage/dep/__init__.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pym/portage/dep') diff --git a/pym/portage/dep/__init__.py b/pym/portage/dep/__init__.py index 916d5ea66..67383e882 100644 --- a/pym/portage/dep/__init__.py +++ b/pym/portage/dep/__init__.py @@ -255,7 +255,7 @@ def strip_empty(myarr): ('portage.dep.strip_empty',), DeprecationWarning, stacklevel=2) return [x for x in myarr if x] -def paren_reduce(mystr): +def paren_reduce(mystr, _deprecation_warn=True): """ Take a string and convert all paren enclosed entities into sublists and split the list elements by spaces. All redundant brackets are removed. @@ -269,7 +269,7 @@ def paren_reduce(mystr): @rtype: Array @return: The reduced string in an array """ - if portage._internal_caller: + if portage._internal_caller and _deprecation_warn: warnings.warn(_("%s is deprecated and will be removed without replacement.") % \ ('portage.dep.paren_reduce',), DeprecationWarning, stacklevel=2) mysplit = mystr.split() -- cgit v1.2.3-1-g7c22