profilesservices/ProfileEngine/tsrc/public/basic/WrapperMdlTest/inc/MT_MProEngEngine.h
changeset 0 8c5d936e5675
equal deleted inserted replaced
-1:000000000000 0:8c5d936e5675
       
     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: Module tests for Profile name array wrapper.
       
    15 *
       
    16 */
       
    17 ////////////////////////////////////////////////////////////////////////
       
    18 // MT_MProEngEngine.h
       
    19 //
       
    20 
       
    21 #ifndef MT_MPROENGENGINE_H
       
    22 #define MT_MPROENGENGINE_H
       
    23 
       
    24 //  INCLUDES
       
    25 #include <e32std.h>
       
    26 #include <f32file.h>
       
    27 #include <bamdesca.h>
       
    28 #include <cntdef.h>
       
    29 #include "MT_CSchedulerUtility.h"
       
    30 #include <CEUnitTestSuiteClass.h>
       
    31 
       
    32 // FORWARD DECLARATIONS
       
    33 class MProEngEngine;
       
    34 class MProEngProfile;
       
    35 class MProEngEngine;
       
    36 class MProfileEngineExtended;
       
    37 class MProfilesNamesArray;
       
    38 class MProfile;
       
    39 class MT_CProEngProfileObserver;
       
    40 
       
    41 // CLASS DECLARATION
       
    42 
       
    43 /**
       
    44 * Module tests for Profile name array wrapper.
       
    45 *
       
    46 */
       
    47 class MT_MProEngEngine
       
    48      : public CEUnitTestSuiteClass
       
    49     {
       
    50     public:
       
    51 
       
    52         /**
       
    53          * Two phase construction
       
    54          */
       
    55         static MT_MProEngEngine* NewL();
       
    56         static MT_MProEngEngine* NewLC();
       
    57 
       
    58         /**
       
    59         * Destructor.
       
    60         */
       
    61         virtual ~MT_MProEngEngine();
       
    62 
       
    63     private:    // Constructors and destructors
       
    64 
       
    65         MT_MProEngEngine();
       
    66         void ConstructL();
       
    67 
       
    68     private: // Setup functions
       
    69 
       
    70         void SetupL();
       
    71         void Setup0L();
       
    72         void Setup1L();
       
    73         void Setup2L();
       
    74         void Setup3L();
       
    75         void Setup4L();
       
    76 #ifdef __OFFLINE_MODE
       
    77         void Setup5L();
       
    78 #endif // __OFFLINE_MODE
       
    79 #ifdef __DRIVE_MODE
       
    80         void Setup6L();
       
    81 #endif // __DRIVE_MODE
       
    82 
       
    83 #ifdef __DYNAMIC_PROFILES
       
    84         void SetupDynamicProfilesL();
       
    85         void Setup30L();
       
    86         void Setup31L();
       
    87         void Setup32L();
       
    88         void Setup33L();
       
    89         void Setup34L();
       
    90         void Setup35L();
       
    91         void Setup36L();
       
    92         void Setup37L();
       
    93         void Setup38L();
       
    94         void Setup39L();
       
    95         void Setup40L();
       
    96         void Setup41L();
       
    97         void Setup42L();
       
    98         void Setup43L();
       
    99         void Setup44L();
       
   100         void Setup45L();
       
   101         void Setup46L();
       
   102         void Setup47L();
       
   103         void Setup48L();
       
   104         void Setup49L();
       
   105 #endif // __DYNAMIC_PROFILES
       
   106 
       
   107     private: // Teardown functions
       
   108 
       
   109         void Teardown();
       
   110 
       
   111 #ifdef __DYNAMIC_PROFILES
       
   112         void TeardownDynamicProfiles();
       
   113 #endif // __DYNAMIC_PROFILES
       
   114 
       
   115     private: // Test functions
       
   116 
       
   117         void ReleaseTestL();
       
   118         void ActiveProfileLCTestL();
       
   119         void ActiveProfileTestL();
       
   120         void ActiveProfileIdTestL();
       
   121         void ProfileNameArrayLCTestL();
       
   122         void SetActiveProfileTestL();
       
   123         void ProfileLCTestL();
       
   124         void ProfileTestL();
       
   125 
       
   126 #ifdef __DYNAMIC_PROFILES
       
   127         void SetActiveProfileDynamicProfilesTestL();
       
   128         void ProfileDynamicProfilesTestL();
       
   129 
       
   130     private: // Helper functions
       
   131 
       
   132         void ForcedLeaveL();
       
   133 
       
   134 #endif // __DYNAMIC_PROFILES
       
   135 
       
   136     private:    // Implementation
       
   137 
       
   138 		EUNIT_DECLARE_TEST_TABLE; 
       
   139 		
       
   140     private:    // Data
       
   141 
       
   142         TInt iOrigId;
       
   143         TInt iActiveId;
       
   144         // owned
       
   145         MProfileEngineExtended* iInternalEngine;
       
   146         // owned
       
   147         MProEngEngine* iEngine;
       
   148     };
       
   149 
       
   150 #endif      // MT_MPROENGENGINE_H
       
   151 
       
   152 // End of File
       
   153 
       
   154 
       
   155 
       
   156