

@responses.activate
def test_googl_expand_method_bad_status_code():
    body = "{'badkey': 'test'}"
    param = urlencode({
        'key': api_key,
        'shortUrl': short_url,
    })
    url = '{}?{}'.format(s.api_url, param)
    responses.add(responses.GET, url, body=param, status=400, match_querystring=True)
    with pytest.raises(ExpandingErrorException):
        s.expand(short_url)

dataset/ETHPy150Open ellisonleao/pyshorteners/tests/test_googl.py test_googl_expand_method_bad_status_code/VarMisuse@62/89 `body`->`param`