phoneplugins/infowidgetplugin/infowidgetprovider/tsrc/ut_infowidgetsathandler/src/ut_infowidgetsathandler.cpp
equal
deleted
inserted
replaced
13 * |
13 * |
14 * Description: |
14 * Description: |
15 * |
15 * |
16 */ |
16 */ |
17 #include "ut_infowidgetsathandler.h" |
17 #include "ut_infowidgetsathandler.h" |
|
18 #define private public |
18 #include "infowidgetsathandler.h" |
19 #include "infowidgetsathandler.h" |
19 #include "qtestmains60.h" |
20 #include "qtestmains60.h" |
20 |
21 |
21 /*! |
22 /*! |
22 UT_InfoWidgetSatHandler::UT_InfoWidgetSatHandler |
23 UT_InfoWidgetSatHandler::UT_InfoWidgetSatHandler |
65 /*! |
66 /*! |
66 UT_InfoWidgetSatHandler::t_satDisplayText |
67 UT_InfoWidgetSatHandler::t_satDisplayText |
67 */ |
68 */ |
68 void UT_InfoWidgetSatHandler::t_satDisplayText() |
69 void UT_InfoWidgetSatHandler::t_satDisplayText() |
69 { |
70 { |
70 const QString& satDisplayText = m_satHandler->satDisplayText(); |
71 QString satDisplayText("satDisplayText"); |
71 QVERIFY(satDisplayText == QString("SAT DISPLAY TEXT")); |
72 m_satHandler->setSatDisplayText(satDisplayText); |
|
73 QVERIFY(satDisplayText == m_satHandler->satDisplayText()); |
72 } |
74 } |
73 |
75 |
74 |
76 |
75 /*! |
77 /*! |
76 UT_InfoWidgetSatHandler::t_setSatDisplayText |
78 UT_InfoWidgetSatHandler::t_setSatDisplayText |
88 UT_InfoWidgetSatHandler::t_logCurrentInfo |
90 UT_InfoWidgetSatHandler::t_logCurrentInfo |
89 */ |
91 */ |
90 void UT_InfoWidgetSatHandler::t_logCurrentInfo() |
92 void UT_InfoWidgetSatHandler::t_logCurrentInfo() |
91 { |
93 { |
92 m_satHandler->logCurrentInfo(); |
94 m_satHandler->logCurrentInfo(); |
|
95 |
|
96 QVERIFY(verify()); |
93 } |
97 } |
94 |
98 |
|
99 void UT_InfoWidgetSatHandler::t_connect() |
|
100 { |
|
101 //}else if (!connect && m_connected){ |
|
102 m_satHandler->m_connected = 1; |
|
103 m_satHandler->connect(0); |
|
104 |
|
105 |
|
106 m_satHandler->m_connected = 1; |
|
107 m_satHandler->connect(1); |
|
108 |
|
109 //if(connect && !m_connected){ |
|
110 m_satHandler->m_connected = 0; |
|
111 m_satHandler->connect(1); |
|
112 |
|
113 QVERIFY(verify()); |
|
114 } |
|
115 void UT_InfoWidgetSatHandler::t_handleIdleModeTxtMessage() |
|
116 { |
|
117 m_satHandler->m_connected = 0; |
|
118 m_satHandler->handleIdleModeTxtMessage(0); |
|
119 m_satHandler->m_connected = 1; |
|
120 m_satHandler->handleIdleModeTxtMessage(0); |
|
121 |
|
122 QVERIFY(verify()); |
|
123 } |
|
124 void UT_InfoWidgetSatHandler::t_handleSatError() |
|
125 { |
|
126 m_satHandler->handleSatError(1,1); |
|
127 |
|
128 QVERIFY(verify()); |
|
129 } |
|
130 |
|
131 |
95 QTEST_MAIN_S60(UT_InfoWidgetSatHandler) |
132 QTEST_MAIN_S60(UT_InfoWidgetSatHandler) |