utilitylibraries/libutils/tsrc/src/integration_test_scenario19.cpp
changeset 22 ddc455616bd6
parent 0 e4d67989cc36
child 45 4b03adbd26ca
child 71 28ccaba883f4
equal deleted inserted replaced
18:47c74d1534e1 22:ddc455616bd6
    18 #include <stdio.h>
    18 #include <stdio.h>
    19 #include<e32std.h>
    19 #include<e32std.h>
    20 #include "libutils.h"
    20 #include "libutils.h"
    21 #include"std_log_result.h"
    21 #include"std_log_result.h"
    22 #define LOG_FILENAME_LINE __FILE__, __LINE__
    22 #define LOG_FILENAME_LINE __FILE__, __LINE__
    23 void main()
    23 int main()
    24 {
    24 {
    25     __UHEAP_MARK;
    25     __UHEAP_MARK;
    26     {
    26     {
    27     wchar_t* mycharstring = L"hellohello";
    27     wchar_t* mycharstring = L"hellohello";
    28     int retval[10];
    28     int retval[10];
    50     retval[7]= WstringToTbuf8(str1,tbuf1);
    50     retval[7]= WstringToTbuf8(str1,tbuf1);
    51 
    51 
    52     buf8.Close();
    52     buf8.Close();
    53     int size8=35;
    53     int size8=35;
    54     retval[8]= Tbuf8ToWchar(tbuf1,myfinalstring,size8);
    54     retval[8]= Tbuf8ToWchar(tbuf1,myfinalstring,size8);
       
    55     
       
    56     for(int i=1; i<=8; i++)
       
    57         {
       
    58         if (retval[i]!= 0)
       
    59                 printf("Conversion failed for retval\n",retval[i]);
       
    60         }
    55 
    61 
    56     if(!wcscmp(mycharstring,myfinalstring))
    62     if(!wcscmp(mycharstring,myfinalstring))
    57     {
    63     {
    58     printf("integration_test_scenario19 case passed\n");
    64     printf("integration_test_scenario19 case passed\n");
    59     }
    65     }
    64     }
    70     }
    65     delete[] myfinalstring;
    71     delete[] myfinalstring;
    66     }
    72     }
    67     __UHEAP_MARKEND;
    73     __UHEAP_MARKEND;
    68     testResultXml("integration_test_scenario19");
    74     testResultXml("integration_test_scenario19");
       
    75     return 0;
    69 }
    76 }