Fix redirects for get_url

* fetch_url shouldn't both accept follow_redirects and support follow_redircts via module.params
* Default follow_redirects for open_url should be 'urllib2'
* Add redirect test for get_url
This commit is contained in:
Matt Martz
2016-03-07 15:35:20 -06:00
parent a302ba0ab4
commit 098333b2ec
2 changed files with 8 additions and 5 deletions

View File

@@ -145,3 +145,8 @@
- 'get_url_result["failed"]'
when: "{{ not python_has_ssl_context }}"
# End hacky SNI test section
- name: Test get_url with redirect
get_url:
url: 'http://httpbin.org/redirect/6'
dest: "{{ output_dir }}/redirect.json"