http_server : Fix and enable example tests

This introduces the following changes in the example test scripts :
* Dependency on python requests library removed in favor of httplib
* Bug fixed in the logic responsible for receiving and processing http chunked responses
* Default timeouts increased Note : Due to connectivity issues (between runner host and DUT) in the runner environment, some of the advanced_tests are being ignored. These tests are intended for verifying the expected limits of the http_server capabilities, and implement sending and receiving of large HTTP packets and malformed requests, running multiple parallel sessions, etc. It is advised that all these tests be run locally, when making changes or adding new features to this component.
This commit is contained in:
Anurag Kar
2018-08-10 23:58:38 +05:30
parent ba17648aea
commit e2da1d9905
6 changed files with 476 additions and 544 deletions

View File

@@ -398,6 +398,11 @@ httpd_handle_t test_httpd_start()
pre_start_mem = esp_get_free_heap_size();
httpd_handle_t hd;
httpd_config_t config = HTTPD_DEFAULT_CONFIG();
config.server_port = 1234;
/* This check should be a part of http_server */
config.max_open_sockets = (CONFIG_LWIP_MAX_SOCKETS - 3);
if (httpd_start(&hd, &config) == ESP_OK) {
ESP_LOGI(TAG, "Started HTTP server on port: %d", config.server_port);
ESP_LOGI(TAG, "Max URI handlers: %d", config.max_uri_handlers);