equal
deleted
inserted
replaced
1 #include "t_indevicehandler.h" |
1 #include "t_indevicehandler.h" |
2 #include "indevicehandler.h" |
2 #include "indevicehandler.h" |
3 #include <qsignalspy.h> |
3 #include <qsignalspy.h> |
4 #include <cpixdocument.h> |
4 #include <cpixdocument.h> |
|
5 #include <hbapplication.h> |
|
6 #include <hbnamespace.h> |
5 SearchInDeviceHandlerTest::SearchInDeviceHandlerTest() |
7 SearchInDeviceHandlerTest::SearchInDeviceHandlerTest() |
6 { |
8 { |
7 } |
9 } |
8 SearchInDeviceHandlerTest::~SearchInDeviceHandlerTest() |
10 SearchInDeviceHandlerTest::~SearchInDeviceHandlerTest() |
9 { |
11 { |
134 |
136 |
135 //QTEST_MAIN corrected since crashes if TRAP not in correct place. |
137 //QTEST_MAIN corrected since crashes if TRAP not in correct place. |
136 //Will be corrected in later (estimate 4.6.0) Qt release for Symbian. |
138 //Will be corrected in later (estimate 4.6.0) Qt release for Symbian. |
137 int main(int argc, char *argv[]) |
139 int main(int argc, char *argv[]) |
138 { |
140 { |
139 QCoreApplication app(argc, argv); |
141 HbApplication app(argc, argv); |
140 #ifdef __WINSCW__ |
142 SearchInDeviceHandlerTest tc; |
141 char *new_argv[3]; |
143 int ret = QTest::qExec(&tc,argc, argv); |
142 QString str = "C:\\data\\" + QFileInfo( |
144 return ret; |
143 QCoreApplication::applicationFilePath()).baseName() + ".log"; |
|
144 QByteArray bytes = str.toAscii(); |
|
145 char arg1[] = "-o"; |
|
146 new_argv[0] = argv[0]; |
|
147 new_argv[1] = arg1; |
|
148 new_argv[2] = bytes.data(); |
|
149 SearchInDeviceHandlerTest tc; |
|
150 return QTest::qExec(&tc, 3, new_argv); |
|
151 #else |
|
152 SearchInDeviceHandlerTest tc; |
|
153 return QTest::qExec(&tc, argc, argv); |
|
154 #endif |
|
155 |
|
156 } |
145 } |
157 #else //Q_OS_SYMBIAN |
146 #else //Q_OS_SYMBIAN |
158 QTEST_MAIN(SearchInDeviceHandlerTest) |
147 QTEST_MAIN(SearchInDeviceHandlerTest) |
159 #endif //Q_OS_SYMBIAN |
148 #endif //Q_OS_SYMBIAN |
160 |
149 |