calendarui/tsrc/unittest_calencommonutils/src/main.cpp
changeset 81 ce92091cbd61
parent 45 b6db4fd4947b
equal deleted inserted replaced
75:7ac58b2aae6f 81:ce92091cbd61
    21 
    21 
    22 // User includes
    22 // User includes
    23 #include "test_calenagendautils.h"
    23 #include "test_calenagendautils.h"
    24 #include "test_calendateutils.h"
    24 #include "test_calendateutils.h"
    25 
    25 
    26 int main(int argc, char *argv[])
    26 //int main(int argc, char *argv[])
    27 {
    27 //{
    28 	HbApplication app(argc, argv);
    28 //	HbApplication app(argc, argv);
    29 	
    29 //	
    30 	TestCalenDateUtils testDateUtils;
    30 //	TestCalenDateUtils testDateUtils;
    31 	
    31 //	
    32 	 char *args[3];	
    32 //	 char *args[3];	
    33 	 args[0] = argv[0];
    33 //	 args[0] = argv[0];
    34 	 args[1] = "-o";	
    34 //	 args[1] = "-o";	
    35 	 args[2] = "c:\\data\\TestCalenDateUtils.txt";
    35 //	 args[2] = "c:\\data\\TestCalenDateUtils.txt";
    36  
    36 // 
    37 	int retDateUtils = QTest::qExec(&testDateUtils, 3, args);
    37 //	int retDateUtils = QTest::qExec(&testDateUtils, 3, args);
    38 	
    38 //	
    39 	
    39 //	
    40 	TestCalenAgendaUtils testAgendaUtils;
    40 //	TestCalenAgendaUtils testAgendaUtils;
    41 	
    41 //	
    42 	args[2] = "c:\\data\\TestCalenAgendaUtils.txt";
    42 //	args[2] = "c:\\data\\TestCalenAgendaUtils.txt";
    43 	
    43 //	
    44 	int retAgendaUtils = QTest::qExec(&testAgendaUtils, 3, args);
    44 //	int retAgendaUtils = QTest::qExec(&testAgendaUtils, 3, args);
    45 	
    45 //	
    46 	// Core dump if HbIconLoader instance is not destroyed before the
    46 //	// Core dump if HbIconLoader instance is not destroyed before the
    47 	// application instance. HbIconLoader uses QCoreApplication::aboutToQuit()
    47 //	// application instance. HbIconLoader uses QCoreApplication::aboutToQuit()
    48 	// signal to destroy itself. app.exec() where the signal is normally emitted
    48 //	// signal to destroy itself. app.exec() where the signal is normally emitted
    49 	// is not called here. So, invoking the signal explicitly.
    49 //	// is not called here. So, invoking the signal explicitly.
    50 	QMetaObject::invokeMethod(&app, "aboutToQuit", Qt::DirectConnection);
    50 //	QMetaObject::invokeMethod(&app, "aboutToQuit", Qt::DirectConnection);
    51 	
    51 //	
    52 	return (retDateUtils && retAgendaUtils);
    52 //	return (retDateUtils && retAgendaUtils);
    53 }
    53 //}
       
    54 
       
    55 QTEST_MAIN ( TestCalenDateUtils )
    54 
    56 
    55 // End of file	--Don't remove this.
    57 // End of file	--Don't remove this.