mmshplugins/mmshaoplugin/tsrc/ut_aoplugin/inc/ut_muscallmonitorbase.h
branchRCL_3
changeset 22 73a1feb507fb
parent 0 f0cf47e981f9
child 23 bc78a40cd63c
equal deleted inserted replaced
21:33a5d2bbf6fc 22:73a1feb507fb
    25 #include <digia/eunit/eunitmacros.h>
    25 #include <digia/eunit/eunitmacros.h>
    26 #include "etelmm.h"
    26 #include "etelmm.h"
    27 #include "muscallmonitorbase.h"
    27 #include "muscallmonitorbase.h"
    28 #include "mussesseioninformationapi.h"
    28 #include "mussesseioninformationapi.h"
    29 #include "mmustsypropertyobserver.h"
    29 #include "mmustsypropertyobserver.h"
       
    30 #include "mmuscallstateobserver.h"
       
    31 
    30 
    32 
    31 // Forward declaration
    33 // Forward declaration
    32 
    34 
    33 // Next row is to disable warning emerging from EUnit code.
    35 // Next row is to disable warning emerging from EUnit code.
    34 // Placement is due to a fact that most test case files
    36 // Placement is due to a fact that most test case files
    40 							
    42 							
    41     {
    43     {
    42 public:
    44 public:
    43     
    45     
    44     CMusCallMonitorMock( const RMobileCall& aCall,
    46     CMusCallMonitorMock( const RMobileCall& aCall,
    45     					MMusTsyPropertyObserver& aObserver );
    47     					MMusTsyPropertyObserver& aObserver,
       
    48     					MMusCallStateObserver& aCallStateObserver );
    46     ~CMusCallMonitorMock();
    49     ~CMusCallMonitorMock();
    47     
    50     
    48     private:
    51     private:
    49 
    52 
    50     void RunL();
    53     void RunL();
    57 /**
    60 /**
    58  * Tester class for CMusCallMonitorBase. 
    61  * Tester class for CMusCallMonitorBase. 
    59  * 
    62  * 
    60  */
    63  */
    61 NONSHARABLE_CLASS( UT_CMusCallMonitorBase ): public CEUnitTestSuiteClass,
    64 NONSHARABLE_CLASS( UT_CMusCallMonitorBase ): public CEUnitTestSuiteClass,
    62 											MMusTsyPropertyObserver
    65 											MMusTsyPropertyObserver,
       
    66 											MMusCallStateObserver
    63     {
    67     {
    64     public:
    68     public:
    65         //Two phase construction
    69         //Two phase construction
    66         static UT_CMusCallMonitorBase* NewL();
    70         static UT_CMusCallMonitorBase* NewL();
    67         static UT_CMusCallMonitorBase* NewLC();
    71         static UT_CMusCallMonitorBase* NewLC();
    76      * @param aCallName The name of the call
    80      * @param aCallName The name of the call
    77      */
    81      */
    78     virtual void NotifyCallStateChanged( NMusSessionInformationApi::TMusCallEvent aVal,
    82     virtual void NotifyCallStateChanged( NMusSessionInformationApi::TMusCallEvent aVal,
    79     									 TName& aCallName );
    83     									 TName& aCallName );
    80     
    84     
       
    85     public:    // from MMusCallStateObserver.
       
    86     virtual void MusCallStateChanged();
       
    87     
    81 
    88 
    82     private: // Constructor
    89     private: // Constructor
    83         UT_CMusCallMonitorBase();
    90         UT_CMusCallMonitorBase();
    84         void ConstructL();
    91         void ConstructL();
    85 
    92 
    90         void Teardown();
    97         void Teardown();
    91 
    98 
    92     private: // Test methdods
    99     private: // Test methdods
    93         void UT_SetStateLL();
   100         void UT_SetStateLL();
    94         void UT_SetCallInfoLL();
   101         void UT_SetCallInfoLL();
    95         void UT_RunErrorL();
   102         void UT_RunErrorL();     
    96         
   103         void UT_CMusCallMonitorBase_IsDataReadyLL();
    97         void UT_SetClirSettingL();
       
    98         void UT_SetTerminatingPrivacyL();
       
    99         void UT_RemovePrefixL();
       
   100         
   104         
   101     
   105     
   102     private:    // Data        
   106     private:    // Data        
   103         CMusCallMonitorBase* iCallMonitorBase;
   107         CMusCallMonitorBase* iCallMonitorBase;
   104         RMobileCall iCall;
   108         RMobileCall iCall;
       
   109         TBool iCallStateObserverInvoked;
   105 
   110 
   106         EUNIT_DECLARE_TEST_TABLE;
   111         EUNIT_DECLARE_TEST_TABLE;
   107 
   112 
   108     };
   113     };
   109 
   114