Skip to content

urlencoded_params_matcher doesn't have strict_match #792

@o-alquimista

Description

@o-alquimista

Other matchers have strict_match, which lets you either match the whole thing (True) or just a few arguments (False). Why doesn't urlencoded_params_matcher have it?

I'm unable to match a request because of this. It contains dozens of request parameters, but I should be able to match by only one.

        stories_mock = responses.post(
            url='https://www.instagram.com/graphql/query',
            match=[matchers.urlencoded_params_matcher({'doc_id': '9342251469147045'}, strict_match=False)],
            json=stories_data,
            status=200
        )
TypeError: urlencoded_params_matcher() got an unexpected keyword argument 'strict_match'

responses 0.26.0
requests 2.33.0

Metadata

Metadata

Assignees

No one assigned
    No fields configured for issues without a type.

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions