ecore_con: adding test case for ecore_con_url_status_code_get.
authorSrivardhan Hebbar <sri.hebbar@samsung.com>
Tue, 10 Nov 2015 00:21:42 +0000 (16:21 -0800)
committerCedric BAIL <cedric@osg.samsung.com>
Tue, 10 Nov 2015 00:21:44 +0000 (16:21 -0800)
Summary: Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com>

Reviewers: cedric

Differential Revision: https://phab.enlightenment.org/D3289

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
src/tests/ecore_con/ecore_con_test_ecore_con_url.c

index d8b7ab1..38fb234 100644 (file)
@@ -33,12 +33,15 @@ _url_compl_cb(void *data, int type EINA_UNUSED, void *event_info)
 {
    url_test *info = data;
    Ecore_Con_Event_Url_Complete *ev = event_info;
+   int status;
 
    printf("Total downloaded bytes = %d\n",
            ecore_con_url_received_bytes_get(ev->url_con));
 
    if (info->_tmpfd)
      {
+        status = ecore_con_url_status_code_get(ev->url_con);
+        fail_if(status != 220);
         _free_url_test(info);
         ecore_con_url_free(ev->url_con);
      }