def test_associate_tag_is_written_to_url(self):
        tag = 'ABC12345'
        api = API('XXX', 'XXX', 'de', associate_tag=tag)
        url = api._build_url(Operation='ItemSearch', SearchIndex='Books')

        qs = parse_qs(urlparse(url)[4])
        assert qs['AssociateTag'][0] == tag
Ejemplo n.º 2
0
    def test_associate_tag_is_written_to_url(self):
        tag = "ABC12345"
        api = API("XXX", "XXX", "de", associate_tag=tag)
        url = api._build_url(Operation="ItemSearch", SearchIndex="Books")

        qs = parse_qs(urlparse(url)[4])
        assert qs["AssociateTag"][0] == tag
Ejemplo n.º 3
0
    def test_associate_tag_is_written_to_url(self):
        tag = 'ABC12345'
        api = API('XXX', 'XXX', 'de', associate_tag=tag)
        url = api._build_url(Operation='ItemSearch', SearchIndex='Books')

        qs = parse_qs(urlparse(url)[4])
        assert qs['AssociateTag'][0] == tag
 def _build_url(self, **qargs):
     qargs['Style'] = self.STYLE_SHEET
     return  API._build_url(self, **qargs)
 def test_responsegroups_as_list(self):
     api = API(locale='de')
     url = api._build_url(ResponseGroup=['ItemAttributes', 'Images'])
     qs = parse_qs(urlparse(url)[4])
     assert qs['ResponseGroup'][0] == 'ItemAttributes,Images'
Ejemplo n.º 6
0
 def test_responsegroups_as_list(self):
     api = API(locale='de')
     url = api._build_url(ResponseGroup=['ItemAttributes', 'Images'])
     qs = parse_qs(urlparse(url)[4])
     assert qs['ResponseGroup'][0] == 'ItemAttributes,Images'