@@ -301,16 +301,12 @@ def test_sanitize_sequence():
301301fail_mapping = (
302302 ({'a' : 1 }, {'forbidden' : ('a' )}),
303303 ({'a' : 1 }, {'required' : ('b' )}),
304- ({'a' : 1 , 'b' : 2 }, {'required' : ('a' ), 'allowed' : ()})
305- )
306-
307- warn_passing_mapping = (
308- ({'a' : 1 , 'b' : 2 }, {'a' : 1 }, {'alias_mapping' : {'a' : ['b' ]}}, 1 ),
309- ({'a' : 1 , 'b' : 2 }, {'a' : 1 },
310- {'alias_mapping' : {'a' : ['b' ]}, 'allowed' : ('a' ,)}, 1 ),
311- ({'a' : 1 , 'b' : 2 }, {'a' : 2 }, {'alias_mapping' : {'a' : ['a' , 'b' ]}}, 1 ),
312- ({'a' : 1 , 'b' : 2 , 'c' : 3 }, {'a' : 1 , 'c' : 3 },
313- {'alias_mapping' : {'a' : ['b' ]}, 'required' : ('a' , )}, 1 ),
304+ ({'a' : 1 , 'b' : 2 }, {'required' : ('a' ), 'allowed' : ()}),
305+ ({'a' : 1 , 'b' : 2 }, {'alias_mapping' : {'a' : ['b' ]}}),
306+ ({'a' : 1 , 'b' : 2 }, {'alias_mapping' : {'a' : ['b' ]}, 'allowed' : ('a' ,)}),
307+ ({'a' : 1 , 'b' : 2 }, {'alias_mapping' : {'a' : ['a' , 'b' ]}}),
308+ ({'a' : 1 , 'b' : 2 , 'c' : 3 },
309+ {'alias_mapping' : {'a' : ['b' ]}, 'required' : ('a' , )}),
314310)
315311
316312pass_mapping = (
@@ -337,15 +333,6 @@ def test_normalize_kwargs_fail(inp, kwargs_to_norm):
337333 cbook .normalize_kwargs (inp , ** kwargs_to_norm )
338334
339335
340- @pytest .mark .parametrize ('inp, expected, kwargs_to_norm, warn_count' ,
341- warn_passing_mapping )
342- def test_normalize_kwargs_warn (inp , expected , kwargs_to_norm , warn_count ):
343- with warnings .catch_warnings (record = True ) as w :
344- warnings .simplefilter ("always" )
345- assert expected == cbook .normalize_kwargs (inp , ** kwargs_to_norm )
346- assert len (w ) == warn_count
347-
348-
349336@pytest .mark .parametrize ('inp, expected, kwargs_to_norm' ,
350337 pass_mapping )
351338def test_normalize_kwargs_pass (inp , expected , kwargs_to_norm ):
0 commit comments