def test_nvp(): eq_(paypal._nvp_dump({'foo': 'bar'}), 'foo=bar') eq_(paypal._nvp_dump({'foo': 'ba r'}), 'foo=ba%20r') eq_(paypal._nvp_dump({'foo': 'bar', 'bar': 'foo'}), 'bar=foo&foo=bar') eq_(paypal._nvp_dump({'foo': ['bar', 'baa']}), 'foo(0)=bar&foo(1)=baa')
def test_nvp(): eq_(paypal._nvp_dump({"foo": "bar"}), "foo=bar") eq_(paypal._nvp_dump({"foo": "ba r"}), "foo=ba%20r") eq_(paypal._nvp_dump({"foo": "bar", "bar": "foo"}), "bar=foo&foo=bar") eq_(paypal._nvp_dump({"foo": ["bar", "baa"]}), "foo(0)=bar&foo(1)=baa")