[UTC][url-download][Non-ACR][Download a small size file in specific TCs] 52/254852/1
authorSeonah Moon <seonah1.moon@samsung.com>
Wed, 10 Mar 2021 04:45:10 +0000 (13:45 +0900)
committerSeonah Moon <seonah1.moon@samsung.com>
Wed, 10 Mar 2021 04:53:44 +0000 (13:53 +0900)
Some TCs should wait until download is completed.
But, according to network status, download could take a long time.
To avoid the timeout, Use a small size file in cases of below TCs.

utc_download_get_downloaded_file_path_p1
utc_download_get_http_status_p1

Change-Id: Ice38433fd64a9f905851d8ce04a81278121a8c5c
Signed-off-by: Seonah Moon <seonah1.moon@samsung.com>
src/utc/url-download/utc-download-common.h
src/utc/url-download/utc-download-get-downloaded-file-path.c
src/utc/url-download/utc-download-get-http-status.c

index e2b28703d98e5bf8839ad302c5c8d49892041b35..986aaf0c7138ba9f58cd5ae4084fc7a11fea0533 100755 (executable)
@@ -21,7 +21,7 @@
 #include <system_info.h>
 
 #define API_NAMESPACE       "URL_DOWNLOAD_UTC"
-#define DOWNLOAD_TIMEOUT    20000
+#define DOWNLOAD_TIMEOUT    25000
 
 #define DOWNLOAD_FEATURE    "tizen.org/feature/download"
 #define TELEPHONY_FEATURE   "tizen.org/feature/network.telephony"
@@ -30,6 +30,7 @@
 #define API_NAMESPACE       "URL_DOWNLOAD_UTC"
 
 #define TEST_URL "http://download.tizen.org/tct/2.2.1/Manual/Native_TBT_2.2.1_User_Guide_v1.0.pdf"
+#define TEST_URL_SMALL "http://download.tizen.org/tct/tct-download-tizen-tests-image-lq.png"
 
 typedef enum {
        DOWNLOAD_SUPPORTED_FEATURE_DOWNLOAD = 0,
index b0e5d9311e5d4c180ad2e73feb6402f0f55c57ee..6a63f070cf017c3bb63e69449cf23a92c4d67f4e 100755 (executable)
@@ -69,7 +69,7 @@ void utc_download_get_downloaded_file_path_startup(void)
        if (retcode != DOWNLOAD_ERROR_NONE)
                fprintf(stderr, "Startup error at %s:%d\n", __FILE__, __LINE__);
 
-       retcode = download_set_url(id, TEST_URL);
+       retcode = download_set_url(id, TEST_URL_SMALL);
        if (retcode != DOWNLOAD_ERROR_NONE)
                        fprintf(stderr, "Cleanup error at %s:%d\n", __FILE__, __LINE__);
 
index f69130a6516fd61051ae82c35cc5ff6f7840bd48..9a27dfcac06735978c6b1919aa9055c8c48d15e8 100755 (executable)
@@ -59,7 +59,7 @@ void utc_download_get_http_status_startup(void)
        if (retcode != DOWNLOAD_ERROR_NONE)
                fprintf(stderr, "Startup error at %s:%d\n", __FILE__, __LINE__);
 
-       retcode = download_set_url(id, TEST_URL);
+       retcode = download_set_url(id, TEST_URL_SMALL);
        if (retcode != DOWNLOAD_ERROR_NONE)
                fprintf(stderr, "Startup error at %s:%d\n", __FILE__, __LINE__);