164 // - Test methods ----------------------------------------------------------- |
164 // - Test methods ----------------------------------------------------------- |
165 |
165 |
166 void ut_cphonesingleandwaiting::TestBubbleAndUICommandsAreUpdatedWhenCallIsPutToHoldL() |
166 void ut_cphonesingleandwaiting::TestBubbleAndUICommandsAreUpdatedWhenCallIsPutToHoldL() |
167 { |
167 { |
168 TInt callId( 1 ); |
168 TInt callId( 1 ); |
169 iMockContext->ExpectCallL("CPhoneState::UpdateUiCommands"); |
169 iMockContext->ExpectCallL("CPhoneState::UpdateCallHeaderAndUiCommandsL"); |
170 iMockContext->ExpectCallL("CPhoneViewCommandHandleMock::ExecuteCommandL"). |
|
171 WithL<TPhoneViewCommandId,TInt>(EPhoneViewUpdateBubble, callId); |
|
172 |
170 |
173 iState->HandlePhoneEngineMessageL( MEngineMonitor::EPEMessageHeld, callId ); |
171 iState->HandlePhoneEngineMessageL( MEngineMonitor::EPEMessageHeld, callId ); |
174 EUNIT_ASSERT_EQUALS( KErrNone, iMockContext->VerifyExpectations() ); |
172 EUNIT_ASSERT_EQUALS( KErrNone, iMockContext->VerifyExpectations() ); |
175 } |
173 } |
176 |
174 |
177 void ut_cphonesingleandwaiting::TestBubbleAndUICommandsAreUpdatedWhenCallIsResumedL() |
175 void ut_cphonesingleandwaiting::TestBubbleAndUICommandsAreUpdatedWhenCallIsResumedL() |
178 { |
176 { |
179 TInt callId( 0 ); |
177 TInt callId( 0 ); |
180 iMockContext->ExpectCallL("CPhoneState::UpdateUiCommands"); |
178 iMockContext->ExpectCallL("CPhoneState::UpdateCallHeaderAndUiCommandsL"); |
181 iMockContext->ExpectCallL("CPhoneViewCommandHandleMock::ExecuteCommandL"). |
|
182 WithL<TPhoneViewCommandId,TInt>(EPhoneViewUpdateBubble, callId); |
|
183 |
179 |
184 iState->HandlePhoneEngineMessageL( MEngineMonitor::EPEMessageConnected, callId ); |
180 iState->HandlePhoneEngineMessageL( MEngineMonitor::EPEMessageConnected, callId ); |
185 EUNIT_ASSERT_EQUALS( KErrNone, iMockContext->VerifyExpectations() ); |
181 EUNIT_ASSERT_EQUALS( KErrNone, iMockContext->VerifyExpectations() ); |
186 } |
182 } |
187 |
183 |