зеркало из https://github.com/mozilla/bedrock.git
s/allow_redirects/follow_redirects
This commit is contained in:
Родитель
93180e91de
Коммит
3ff957e8f2
|
@ -59,7 +59,7 @@ def url_test(url, location=None, status_code=requests.codes.moved_permanently,
|
|||
'req_kwargs': req_kwargs,
|
||||
'resp_headers': resp_headers,
|
||||
'query': query,
|
||||
'allow_redirects': follow_redirects,
|
||||
'follow_redirects': follow_redirects,
|
||||
'final_status_code': final_status_code,
|
||||
}
|
||||
expanded_urls = list(braceexpand(url))
|
||||
|
|
|
@ -991,8 +991,4 @@ URLS = flatten((
|
|||
# Bug 1239863
|
||||
url_test('/firefox/os/faq/',
|
||||
'https://support.mozilla.org/products/firefox-os'),
|
||||
|
||||
url_test('/firefox/brand/', '/styleguide/'),
|
||||
url_test('/firefox/channel/android/', '/en-US/firefox/channel/android/'),
|
||||
url_test('/en-US/firefox/channel/android/', '/firefox/channel/'),
|
||||
))
|
||||
|
|
|
@ -15,7 +15,7 @@ from .map_external import URLS as EXTERNAL_URLS
|
|||
@pytest.mark.parametrize('url', EXTERNAL_URLS, ids=itemgetter('url'))
|
||||
def test_external_url(url):
|
||||
del url['location']
|
||||
url['allow_redirects'] = True
|
||||
url['follow_redirects'] = True
|
||||
assert_valid_url(**url)
|
||||
|
||||
|
||||
|
@ -84,4 +84,4 @@ def test_x_robots_tag(base_url):
|
|||
'/thunderbird/releases/'
|
||||
])
|
||||
def test_url(url, base_url):
|
||||
assert_valid_url(url, base_url=base_url, allow_redirects=True)
|
||||
assert_valid_url(url, base_url=base_url, follow_redirects=True)
|
||||
|
|
Загрузка…
Ссылка в новой задаче