1
0
mirror of https://github.com/moparisthebest/wget synced 2024-07-03 16:38:41 -04:00
wget/testenv/conf
Ander Juaristi 54058d2b18 Enhancements in testsuite engine + new HSTS test.
* testenv/Makefile.am: added new test 'Test-hsts.py'.
 * testenv/Test-hsts.py: new test for HSTS.
 * testenv/conf/domains.py: new hook to override domain list.
 * testenv/test/base_test.py: (__init__): new optional parameter
   for tests 'req_protocols'.
   (get_domain_addr): set the instance variables 'addr' and 'port'.
   Return address as an array (domain, port) instead of string.
   (gen_cmd_line): take into account domain and port.
 * testenv/test/http_test.py (__init__): new optional parameter
   'req_protocols'.
   (setup): new function. Call to server_setup() decoupled from
   begin() and moved here.
   (begin): call to superclass to maintain backward compatibility.
   Removed call to server_setup().

This patch adds a new parameter to the test suite called 'req_protocols',
and a new function called 'setup'. The ability for tests to be able to set some
extra parameters such as the actual requested protocols (with 'req_protocols')
became obvious when support for HSTS was added to Wget, where the requested URI
and the actual executed URI do not have to be the same. This new parameter is optional
and if not specified, the test suite behaves as before. Also, the new function 'setup'
is provided as a means to start the test HTTP server, but not launch the test yet
(this is done when calling 'begin', as usual), in case we want to query the address
and port in which the test server listens. If 'setup' is not called, it is automatically
invoked when calling 'begin'. With these measures, we preserve backward-compatibility with
existing tests.
2015-07-20 16:06:40 +02:00
..
__init__.py PEP8'ify the Python Test Suite 2015-04-14 10:59:17 +05:30
authentication.py PEP8'ify the Python Test Suite 2015-04-14 10:59:17 +05:30
domains.py Enhancements in testsuite engine + new HSTS test. 2015-07-20 16:06:40 +02:00
expect_header.py Documentation and code cleanup in test suite 2014-08-08 17:38:11 +05:30
expected_files.py Documentation and code cleanup in test suite 2014-08-08 17:38:11 +05:30
expected_ret_code.py Documentation and code cleanup in test suite 2014-08-08 17:38:11 +05:30
files_crawled.py PEP8'ify the Python Test Suite 2015-04-14 10:59:17 +05:30
hook_sample.py PEP8'ify the Python Test Suite 2015-04-14 10:59:17 +05:30
local_files.py Implement timestamp support for local files in testenv 2015-05-22 11:08:30 +02:00
reject_header.py PEP8'ify the Python Test Suite 2015-04-14 10:59:17 +05:30
response.py Documentation and code cleanup in test suite 2014-08-08 17:38:11 +05:30
rule_sample.py Refactor the Python based test suite 2014-07-24 16:51:58 +05:30
send_header.py Documentation and code cleanup in test suite 2014-08-08 17:38:11 +05:30
server_files.py PEP8'ify the Python Test Suite 2015-04-14 10:59:17 +05:30
urls.py Documentation and code cleanup in test suite 2014-08-08 17:38:11 +05:30
wget_commands.py Documentation and code cleanup in test suite 2014-08-08 17:38:11 +05:30