phonesrv_plat/call_information_api/tsrc/src/MT_CallInformation.cpp
changeset 0 ff3b6d0fd310
child 19 7d48bed6ce0c
equal deleted inserted replaced
-1:000000000000 0:ff3b6d0fd310
       
     1 /*
       
     2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). 
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:
       
    15 *
       
    16 */
       
    17 
       
    18 #include "MT_CallInformation.h"
       
    19 
       
    20 #ifdef __WINSCW__
       
    21 #include "CPhoneEngineCreator.h"
       
    22 #include "CPEMessageWaiter.h"
       
    23 #endif
       
    24 
       
    25 #include <EUnitMacros.h>
       
    26 #include <EUnitDecorators.h>
       
    27 
       
    28 #include <etelmm.h>
       
    29 
       
    30 #include <mmtsy_names.h>
       
    31 #include <MCall.h>
       
    32 #include <ccallinfoiter.h>
       
    33 #include <CPhCltEmergencyCall.h>
       
    34 #include <MPhCltEmergencyCallObserver.h>
       
    35 #include <CPhCltCommandHandler.h>
       
    36 
       
    37 //Speaking clock number when calling from NTN network.
       
    38 _LIT (KNumber, "99901");     
       
    39 _LIT( KEmergencyNumber, "112" );
       
    40 _LIT( KOtherNumber, "99999" );
       
    41 
       
    42 class CDialer : public CActive, protected MPhCltEmergencyCallObserver
       
    43     {
       
    44 public:
       
    45     
       
    46     static CDialer* NewL( RTelServer& aTelServer ) { 
       
    47         CDialer* self = CDialer::NewLC( aTelServer );
       
    48         CleanupStack::Pop( self );
       
    49         return self;
       
    50     }
       
    51     
       
    52     static CDialer* NewLC( RTelServer& aTelServer )
       
    53         {
       
    54         CDialer* self = new( ELeave )CDialer( aTelServer );
       
    55         CleanupStack::PushL( self );
       
    56         self->ConstructL();
       
    57         return self;
       
    58         }
       
    59     
       
    60     ~CDialer() {
       
    61         if( IsActive() )
       
    62             {
       
    63             WaitForRequest();
       
    64             }
       
    65         delete iEmergency;
       
    66         delete iCmdHandler;
       
    67         delete iWait;
       
    68         iCall.Close();
       
    69         }
       
    70     
       
    71     void Dial( const TDesC& aNumber ) {
       
    72         iCall.Dial( iStatus, aNumber );
       
    73         SetActive();
       
    74         }
       
    75     
       
    76     void Dial() {
       
    77         Dial( KNumber() );
       
    78         }
       
    79     
       
    80     void DialEmergency() {
       
    81         iEmergency->DialEmergencyCallL( KEmergencyNumber );
       
    82         }
       
    83     
       
    84     void Hangup() {
       
    85         iCall.HangUp(iStatus);
       
    86         SetActive();
       
    87         }
       
    88     
       
    89     void HangupEmergencyCall()
       
    90         {
       
    91         iCmdHandler->Chup( iStatus );
       
    92         SetActive();
       
    93         }
       
    94     
       
    95     void WaitForRequest() {
       
    96         if ( IsActive() || iEmergency->IsActive() )
       
    97             {
       
    98             iWait->Start();
       
    99             }
       
   100         }
       
   101     
       
   102     void WaitL( TInt aTimeoutInSeconds ) {
       
   103         RTimer timer;
       
   104         User::LeaveIfError( timer.CreateLocal() ); 
       
   105         CleanupClosePushL( timer );        
       
   106         timer.After( iStatus, aTimeoutInSeconds * 1000000 );
       
   107         SetActive();
       
   108         WaitForRequest();
       
   109         CleanupStack::PopAndDestroy( 1, &timer ); 
       
   110         }
       
   111     
       
   112 protected:
       
   113     
       
   114     void RunL() {
       
   115         if( iWait->IsStarted() )
       
   116             {
       
   117             iWait->AsyncStop();
       
   118             }
       
   119     }
       
   120     
       
   121     void DoCancel() { 
       
   122          }
       
   123     
       
   124     void HandleEmergencyDialL( const TInt /*aStatus*/ ) {
       
   125         if ( iWait->IsStarted() )
       
   126             {
       
   127             iWait->AsyncStop();
       
   128             }
       
   129     }
       
   130 private:
       
   131     
       
   132     void ConstructL() { 
       
   133         TBuf<100> name;
       
   134         name.Append( KMmTsyPhoneName );
       
   135         name.Append( _L("::") );
       
   136         name.Append( KMmTsyVoice1LineName );
       
   137         name.Append( _L("::") );
       
   138         TBuf<100> callName;
       
   139         User::LeaveIfError( iCall.OpenNewCall( iTelServer, name, callName  ) );
       
   140         iEmergency = CPhCltEmergencyCall::NewL( this );
       
   141         iCmdHandler = CPhCltCommandHandler::NewL();
       
   142         iWait = new( ELeave )CActiveSchedulerWait(); 
       
   143         }
       
   144     
       
   145     CDialer( RTelServer& aTelServer ) : CActive( EPriorityStandard ), iTelServer( aTelServer ) 
       
   146         { CActiveScheduler::Add( this ); }
       
   147     
       
   148 private:
       
   149     RTelServer iTelServer;
       
   150     RMobileCall iCall;
       
   151     CActiveSchedulerWait* iWait;
       
   152     CPhCltEmergencyCall* iEmergency;
       
   153     CPhCltCommandHandler* iCmdHandler;
       
   154     };
       
   155 
       
   156 // - Construction -----------------------------------------------------------
       
   157 
       
   158 MT_CallInformation* MT_CallInformation::NewL()
       
   159     {
       
   160     MT_CallInformation* self = MT_CallInformation::NewLC();
       
   161     CleanupStack::Pop();
       
   162     return self;
       
   163     }
       
   164 
       
   165 MT_CallInformation* MT_CallInformation::NewLC()
       
   166     {
       
   167     MT_CallInformation* self = new( ELeave ) MT_CallInformation();
       
   168     CleanupStack::PushL( self );
       
   169     self->ConstructL();
       
   170     return self;
       
   171     }
       
   172 
       
   173 MT_CallInformation::~MT_CallInformation()
       
   174     {
       
   175 #ifdef __WINSCW__
       
   176     delete iPECreator;
       
   177 #endif    
       
   178     }
       
   179 
       
   180 MT_CallInformation::MT_CallInformation()
       
   181     {
       
   182     }
       
   183 
       
   184 void MT_CallInformation::ConstructL()
       
   185     {
       
   186 #ifdef __WINSCW__
       
   187     iPECreator = CPhoneEngineCreator::NewL();    
       
   188 #endif    
       
   189     CEUnitTestSuiteClass::ConstructL();
       
   190     }
       
   191 
       
   192 
       
   193 void MT_CallInformation::CallInformationChanged()
       
   194     {
       
   195     if( iWait->IsStarted() )
       
   196         {
       
   197         iWait->AsyncStop();
       
   198         }
       
   199     }
       
   200 
       
   201 
       
   202 // - Test methods -----------------------------------------------------------
       
   203 void MT_CallInformation::SetupL(  )
       
   204     {
       
   205     EUNIT_PRINT( _L( "MT_CallInformation::SetupL in" ));
       
   206 #ifdef __WINSCW__
       
   207     iMsgWaiter = CPEMessageWaiter::NewL();
       
   208     iPhoneModel = iPECreator->CreatePhoneEngineL( *iMsgWaiter );
       
   209     
       
   210     RProperty::Define( KPSUidNetworkInfo,
       
   211                        KNWRegistrationStatus,
       
   212                        RProperty::EInt );
       
   213         
       
   214     User::LeaveIfError( RProperty::Set( KPSUidNetworkInfo,
       
   215                         KNWRegistrationStatus,
       
   216                         ENWStatusRegisteredOnHomeNetwork ) ); 
       
   217     iMsgWaiter->WaitL(1);
       
   218 #endif    
       
   219     User::LeaveIfError( iTelServer.Connect() );
       
   220     iCallInfos = CCallInformation::NewL();
       
   221     iCallInfos->NotifyCallInformationChanges( *this );
       
   222     iDialer = CDialer::NewL( iTelServer );
       
   223     iWait = new( ELeave )CActiveSchedulerWait();
       
   224     EUNIT_PRINT( _L( "MT_CallInformation::SetupL out" ));
       
   225     }
       
   226     
       
   227 
       
   228 void MT_CallInformation::Teardown(  )
       
   229     {
       
   230     EUNIT_PRINT( _L( "MT_CallInformation::Teardown in" ));
       
   231     delete iWait;
       
   232     delete iCallInfos;
       
   233     delete iDialer;
       
   234     iTelServer.Close();
       
   235 #ifdef __WINSCW__    
       
   236     delete iPhoneModel;
       
   237     iPhoneModel = NULL;
       
   238     delete iMsgWaiter;
       
   239     iMsgWaiter = NULL;    
       
   240 #endif   
       
   241     EUNIT_PRINT( _L( "MT_CallInformation::Teardown out" ));
       
   242     }
       
   243     
       
   244 
       
   245 void MT_CallInformation::TestNoCallsL(  )
       
   246     {
       
   247     CCallInfoIter& infos( iCallInfos->GetCallsL() );
       
   248     EUNIT_ASSERT_EQUALS( infos.Count(), 0 );    
       
   249     }
       
   250 
       
   251 void MT_CallInformation::TestActiveCallL()
       
   252     {
       
   253     iDialer->Dial();
       
   254     // Wait for dial to complete, timing might be different in HW and emulator
       
   255     iDialer->WaitForRequest();   
       
   256     
       
   257     CCallInformation* callInfos = CCallInformation::NewL();
       
   258     CleanupStack::PushL( callInfos );
       
   259     
       
   260     TBool dataCecked (EFalse);
       
   261     while ( !dataCecked )
       
   262         {
       
   263         CCallInfoIter& infos( callInfos->GetCallsL() );
       
   264         EUNIT_ASSERT_EQUALS( infos.Count(), 1 );
       
   265         const MCall& call( infos.Current() );
       
   266         EUNIT_ASSERT_EQUALS( call.CallType(), CCPCall::ECallTypeCSVoice );
       
   267         EUNIT_ASSERT_EQUALS( call.CallIndex(), 1 );
       
   268         EUNIT_ASSERT_EQUALS( call.ServiceId(), 1 );
       
   269         
       
   270         if ( callInfos->IsCallInState( CCPCall::EStateConnected ) == ETrue )
       
   271             {
       
   272             CCPCall::TCallState state = call.CallState();
       
   273             EUNIT_ASSERT_EQUALS( call.CallState(), CCPCall::EStateConnected );
       
   274             dataCecked = ETrue;
       
   275             }
       
   276         else
       
   277             {
       
   278             iDialer->WaitL( 1 );            
       
   279             }
       
   280         }
       
   281     
       
   282     CleanupStack::PopAndDestroy( callInfos );
       
   283     iDialer->Hangup();
       
   284     iDialer->WaitForRequest();
       
   285     
       
   286     }
       
   287 
       
   288 void MT_CallInformation::TestSingleCallL()
       
   289     {
       
   290     iDialer->Dial();
       
   291     EUNIT_PRINT( _L( "MT_CallInformation: Dial returns" ));
       
   292     
       
   293     EUNIT_PRINT( _L( "MT_CallInformation: wait for EStateDialling" ));
       
   294     iWait->Start(); // Wait for state notification.    
       
   295     
       
   296     {
       
   297         CCallInfoIter& infos( iCallInfos->GetCallsL() );
       
   298         EUNIT_ASSERT_EQUALS( infos.Count(), 1 );
       
   299         const MCall& call( infos.Current() );
       
   300         EUNIT_ASSERT_EQUALS( call.CallState(), CCPCall::EStateDialling );
       
   301         EUNIT_ASSERT_EQUALS( call.CallType(), CCPCall::ECallTypeCSVoice );
       
   302         EUNIT_ASSERT_EQUALS( call.CallIndex(), 1 );
       
   303         EUNIT_ASSERT_EQUALS( call.ServiceId(), 1 );
       
   304         EUNIT_ASSERT_EQUALS( call.IsEmergency(), EFalse );
       
   305     }
       
   306     EUNIT_PRINT( _L( "MT_CallInformation: wait for EStateConnecting" ));
       
   307     iWait->Start();    
       
   308     {
       
   309         CCallInfoIter& infos( iCallInfos->GetCallsL() );
       
   310         EUNIT_ASSERT_EQUALS( infos.Count(), 1 );
       
   311         const MCall& call( infos.Current() );
       
   312         EUNIT_ASSERT_EQUALS( call.CallState(), CCPCall::EStateConnecting );
       
   313         EUNIT_ASSERT_EQUALS( call.CallType(), CCPCall::ECallTypeCSVoice );
       
   314         EUNIT_ASSERT_EQUALS( call.CallIndex(), 1 );
       
   315         EUNIT_ASSERT_EQUALS( call.ServiceId(), 1 );
       
   316         EUNIT_ASSERT_EQUALS( call.IsEmergency(), EFalse );
       
   317     }
       
   318     EUNIT_PRINT( _L( "MT_CallInformation: wait for EStateConnected" ));
       
   319     iWait->Start();    
       
   320     {
       
   321         CCallInfoIter& infos( iCallInfos->GetCallsL() );
       
   322         EUNIT_ASSERT_EQUALS( infos.Count(), 1 );
       
   323         const MCall& call( infos.Current() );
       
   324         EUNIT_ASSERT_EQUALS( call.CallState(), CCPCall::EStateConnected );
       
   325         EUNIT_ASSERT_EQUALS( call.CallType(), CCPCall::ECallTypeCSVoice );
       
   326         EUNIT_ASSERT_EQUALS( call.CallIndex(), 1 );
       
   327         EUNIT_ASSERT_EQUALS( call.ServiceId(), 1 );
       
   328         EUNIT_ASSERT_EQUALS( call.IsEmergency(), EFalse );
       
   329     }
       
   330     if( iDialer->IsActive() )
       
   331         {
       
   332         // Wait for dial to complete
       
   333         iDialer->WaitForRequest();
       
   334         EUNIT_PRINT( _L( "MT_CallInformation: Dial completes" ));
       
   335         }
       
   336     
       
   337     iDialer->Hangup();
       
   338     EUNIT_PRINT( _L( "MT_CallInformation: Hangup returns" ));
       
   339 
       
   340     EUNIT_PRINT( _L( "MT_CallInformation: wait for EStateDisconnecting" ));
       
   341     iWait->Start();    
       
   342     {
       
   343         CCallInfoIter& infos( iCallInfos->GetCallsL() );
       
   344         EUNIT_ASSERT_EQUALS( infos.Count(), 1 );
       
   345         const MCall& call( infos.Current() );
       
   346         EUNIT_ASSERT_EQUALS( call.CallState(), CCPCall::EStateDisconnecting );
       
   347         EUNIT_ASSERT_EQUALS( call.CallType(), CCPCall::ECallTypeCSVoice );
       
   348         EUNIT_ASSERT_EQUALS( call.CallIndex(), 1 );
       
   349         EUNIT_ASSERT_EQUALS( call.ServiceId(), 1 );
       
   350         EUNIT_ASSERT_EQUALS( call.IsEmergency(), EFalse );
       
   351     }
       
   352     EUNIT_PRINT( _L( "MT_CallInformation: wait for Idle" ));
       
   353     iWait->Start();    
       
   354         {
       
   355         CCallInfoIter& infos( iCallInfos->GetCallsL() );
       
   356         EUNIT_ASSERT_EQUALS( infos.Count(), 0 );
       
   357         }
       
   358     if ( iDialer->IsActive() )
       
   359         {
       
   360         iDialer->WaitForRequest();
       
   361         EUNIT_PRINT( _L( "MT_CallInformation: Hangup completes" ));
       
   362         }
       
   363     }
       
   364 
       
   365 void MT_CallInformation::TestEmergencyCallL()
       
   366     {
       
   367     iDialer->DialEmergency();
       
   368     iWait->Start(); // Wait for state notification.
       
   369     
       
   370     {
       
   371         CCallInfoIter& infos( iCallInfos->GetCallsL() );
       
   372         EUNIT_ASSERT_EQUALS( infos.Count(), 1 );
       
   373         const MCall& call( infos.Current() );
       
   374         EUNIT_ASSERT_EQUALS( call.CallState(), CCPCall::EStateDialling );
       
   375         EUNIT_ASSERT_EQUALS( call.CallType(), CCPCall::ECallTypeCSVoice );
       
   376         EUNIT_ASSERT_EQUALS( call.CallIndex(), 1 );
       
   377         EUNIT_ASSERT_EQUALS( call.ServiceId(), 0 ); 
       
   378         EUNIT_ASSERT_EQUALS( call.IsEmergency(), ETrue );
       
   379     }
       
   380     iWait->Start();
       
   381     {
       
   382         CCallInfoIter& infos( iCallInfos->GetCallsL() );
       
   383         EUNIT_ASSERT_EQUALS( infos.Count(), 1 );
       
   384         const MCall& call( infos.Current() );
       
   385         EUNIT_ASSERT_EQUALS( call.CallState(), CCPCall::EStateConnecting );
       
   386         EUNIT_ASSERT_EQUALS( call.CallType(), CCPCall::ECallTypeCSVoice );
       
   387         EUNIT_ASSERT_EQUALS( call.CallIndex(), 1 );
       
   388         EUNIT_ASSERT_EQUALS( call.ServiceId(), 0 ); 
       
   389         EUNIT_ASSERT_EQUALS( call.IsEmergency(), ETrue );
       
   390     }
       
   391     iWait->Start();
       
   392     {
       
   393         CCallInfoIter& infos( iCallInfos->GetCallsL() );
       
   394         EUNIT_ASSERT_EQUALS( infos.Count(), 1 );
       
   395         const MCall& call( infos.Current() );
       
   396         EUNIT_ASSERT_EQUALS( call.CallState(), CCPCall::EStateConnected );
       
   397         EUNIT_ASSERT_EQUALS( call.CallType(), CCPCall::ECallTypeCSVoice );
       
   398         EUNIT_ASSERT_EQUALS( call.CallIndex(), 1 );
       
   399         EUNIT_ASSERT_EQUALS( call.ServiceId(), 0 ); 
       
   400         EUNIT_ASSERT_EQUALS( call.IsEmergency(), ETrue );
       
   401     }
       
   402     if( iDialer->IsActive() )
       
   403         {
       
   404         // Wait for dial to complete
       
   405         iDialer->WaitForRequest();
       
   406         }
       
   407     iDialer->HangupEmergencyCall();
       
   408 
       
   409     iWait->Start();
       
   410     {
       
   411         CCallInfoIter& infos( iCallInfos->GetCallsL() );
       
   412         EUNIT_ASSERT_EQUALS( infos.Count(), 1 );
       
   413         const MCall& call( infos.Current() );
       
   414         EUNIT_ASSERT_EQUALS( call.CallState(), CCPCall::EStateDisconnecting );
       
   415         EUNIT_ASSERT_EQUALS( call.CallType(), CCPCall::ECallTypeCSVoice );
       
   416         EUNIT_ASSERT_EQUALS( call.CallIndex(), 1 );
       
   417         EUNIT_ASSERT_EQUALS( call.ServiceId(), 0 ); 
       
   418         EUNIT_ASSERT_EQUALS( call.IsEmergency(), ETrue );
       
   419     }
       
   420     iWait->Start();
       
   421         {
       
   422         CCallInfoIter& infos( iCallInfos->GetCallsL() );
       
   423         EUNIT_ASSERT_EQUALS( infos.Count(), 0 );
       
   424         }
       
   425     if ( iDialer->IsActive() )
       
   426         {
       
   427         iDialer->WaitForRequest();
       
   428         }
       
   429     }
       
   430 
       
   431 void MT_CallInformation::TestMultiCallL()
       
   432     {
       
   433     EUNIT_PRINT( _L( "MT_CallInformation: TestMultiCallL" ));
       
   434     iDialer->Dial();
       
   435     iDialer->WaitForRequest(); // Waits call to go connected state
       
   436     
       
   437     CDialer* otherDialer = CDialer::NewLC( iTelServer );
       
   438     otherDialer->Dial( KNumber );
       
   439     
       
   440     while ( iCallInfos->IsCallInState( CCPCall::EStateHold ) != ETrue &&
       
   441             iCallInfos->IsCallInState( CCPCall::EStateConnected ) != ETrue )
       
   442         {
       
   443         iWait->Start(); // Wait for state notifications
       
   444         CCallInfoIter& infos( iCallInfos->GetCallsL() );
       
   445         
       
   446         if( infos.Count() == 2 )
       
   447             {
       
   448             const MCall& call_1( infos.Current() );
       
   449             infos.Next();
       
   450             const MCall& call_2( infos.Current() );
       
   451          
       
   452             EUNIT_ASSERT_EQUALS( call_1.CallIndex(), 1 );
       
   453             EUNIT_ASSERT_EQUALS( call_2.CallIndex(), 2 );
       
   454             }
       
   455         }
       
   456     EUNIT_PRINT( _L( "MT_CallInformation: held and connected call exist" ));
       
   457     
       
   458     
       
   459     if ( otherDialer->IsActive() )
       
   460         {
       
   461         otherDialer->WaitForRequest();
       
   462         }
       
   463     iDialer->Hangup();
       
   464     iDialer->WaitForRequest();
       
   465     otherDialer->Hangup();
       
   466     otherDialer->WaitForRequest();
       
   467     CleanupStack::PopAndDestroy( otherDialer );
       
   468     }
       
   469 
       
   470 
       
   471 void MT_CallInformation::TwoCallsExistL()
       
   472     {
       
   473     EUNIT_PRINT( _L( "MT_CallInformation: TwoCallsExistL" ));
       
   474     iDialer->Dial();
       
   475     iDialer->WaitForRequest(); // Waits call to go connected state
       
   476         
       
   477     CDialer* otherDialer = CDialer::NewLC( iTelServer );
       
   478     otherDialer->Dial( KNumber );  
       
   479     
       
   480     TBool TwoCallsExist = EFalse;
       
   481     while ( !TwoCallsExist )
       
   482         {
       
   483         iWait->Start(); // Wait for state notifications            
       
   484         CCallInfoIter& infos( iCallInfos->GetCallsL() );        
       
   485             
       
   486         TInt callIndex(1);                
       
   487         for( infos.First(); !infos.IsDone(); infos.Next() )
       
   488             {
       
   489             const MCall& call( infos.Current() );
       
   490             EUNIT_ASSERT_EQUALS( call.CallIndex(), callIndex );
       
   491             EUNIT_PRINT( _L( "MT_CallInformation: CallIndex()" ));
       
   492             callIndex++;
       
   493             if ( infos.Count() == 2 )
       
   494                 {
       
   495                 EUNIT_PRINT( _L( "MT_CallInformation: Count()" ));
       
   496                 TwoCallsExist = ETrue;
       
   497                 }
       
   498             }    
       
   499         }
       
   500     EUNIT_PRINT( _L( "MT_CallInformation: TwoCallsExist == ETrue" ));
       
   501         
       
   502     if ( otherDialer->IsActive() )
       
   503         {
       
   504         otherDialer->WaitForRequest();
       
   505         }
       
   506     iDialer->Hangup();
       
   507     iDialer->WaitForRequest();
       
   508     otherDialer->Hangup();
       
   509     otherDialer->WaitForRequest();
       
   510     CleanupStack::PopAndDestroy( otherDialer );    
       
   511     }
       
   512 
       
   513     
       
   514 
       
   515 // - EUnit test table -------------------------------------------------------
       
   516 
       
   517 EUNIT_BEGIN_TEST_TABLE(
       
   518     MT_CallInformation,
       
   519     "API tests for Call information api",
       
   520     "MODULE" )
       
   521 
       
   522 EUNIT_TEST(
       
   523     "No calls",
       
   524     "CCallInformation",
       
   525     "GetCallsL",
       
   526     "FUNCTIONALITY",
       
   527     SetupL, TestNoCallsL, Teardown)
       
   528     
       
   529 EUNIT_TEST(
       
   530     "Constructing API when call available",
       
   531     "CCallInformation",
       
   532     "GetCallsL",
       
   533     "FUNCTIONALITY",
       
   534     SetupL, TestActiveCallL, Teardown)
       
   535     
       
   536 EUNIT_TEST(
       
   537     "Single call states",
       
   538     "CCallInformation",
       
   539     "GetCallsL",
       
   540     "FUNCTIONALITY",
       
   541     SetupL, TestSingleCallL, Teardown)
       
   542     
       
   543 /* testing emergency call should be done only in special lab    
       
   544 EUNIT_TEST(
       
   545     "Emergency call states",
       
   546     "CCallInformation",
       
   547     "GetCallsL",
       
   548     "FUNCTIONALITY",
       
   549     SetupL, TestEmergencyCallL, Teardown)
       
   550 */
       
   551     
       
   552 EUNIT_TEST(
       
   553     "Multicall states",
       
   554     "CCallInformation",
       
   555     "GetCallsL",
       
   556     "FUNCTIONALITY",
       
   557     SetupL, TestMultiCallL, Teardown)
       
   558     
       
   559 EUNIT_TEST(
       
   560     "Two calls exist",
       
   561     "CCallInformation",
       
   562     "GetCallsL",
       
   563     "FUNCTIONALITY",
       
   564     SetupL, TwoCallsExistL, Teardown)    
       
   565 
       
   566 EUNIT_END_TEST_TABLE