os/ossrv/lowlevellibsandfws/pluginfw/Framework/SuicideTests/SuicideTransitions.h
author sl
Tue, 10 Jun 2014 14:32:02 +0200
changeset 1 260cb5ec6c19
permissions -rw-r--r--
Update contrib.
     1 // Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
     2 // All rights reserved.
     3 // This component and the accompanying materials are made available
     4 // under the terms of "Eclipse Public License v1.0"
     5 // which accompanies this distribution, and is available
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
     7 //
     8 // Initial Contributors:
     9 // Nokia Corporation - initial contribution.
    10 //
    11 // Contributors:
    12 //
    13 // Description:
    14 // This file contains the definitions for
    15 // the transition classes for testing the
    16 // CExampleInterface interface.
    17 // 
    18 //
    19 
    20 #ifndef __SUICIDETRANSITION_H__
    21 #define __SUICIDETRANSITION_H__
    22 
    23 #include <test_bed/transition.h>
    24 #include "LeakTestTransition.h"
    25 #include "Interface.h"
    26 
    27 class CExampleInterface;
    28 
    29 #define CTransitionType CLeakTestTransition
    30 
    31 // ______________________________________________________________________________
    32 //
    33 /**
    34 	Comments : The context in which the transitions will run
    35 				That is to say the container in which the transition 
    36 				parameters are passed around
    37  */
    38 class CSuicideInterface_UnitTestContext : public CUnitTestContext
    39 	{
    40 public:
    41 	inline CSuicideInterface_UnitTestContext(CDataLogger& aDataLogger, 
    42 							  MStateAccessor& aAccessor,
    43 							  MTransitionObserver& aObserver);
    44 	inline ~CSuicideInterface_UnitTestContext();
    45 
    46 	CExampleInterface* iExampleInterface;
    47 	};
    48 
    49 /**
    50 	Comments : Transition of the NewL method
    51  */
    52 class CSuicideInterfaceNewLTransition : public CTransitionType
    53 	{
    54 public:
    55 	inline CSuicideInterfaceNewLTransition( CUnitTestContext& aUTContext,
    56 											TTransitionValidator& aValidator);
    57 	inline void TransitMethodL();
    58 	inline CSuicideInterface_UnitTestContext& Context();
    59 	};
    60 
    61 /**
    62 	Comments : Transition of the destructor method
    63  */
    64 class CSuicideInterfaceDtorTransition : public CTransition
    65 	{
    66 public:
    67 	inline CSuicideInterfaceDtorTransition( CUnitTestContext& aUTContext,
    68 											TTransitionValidator& aValidator);
    69 	inline void TransitMethodL();
    70 	inline CSuicideInterface_UnitTestContext& Context();
    71 	};
    72 
    73 
    74 /**
    75 	Comments : Transition of the FireAndForget method
    76  */
    77 class CSuicideInterfaceFireAndForgetTransition : public CTransition
    78 	{
    79 public:
    80 	inline CSuicideInterfaceFireAndForgetTransition( CUnitTestContext& aUTContext,
    81 											TTransitionValidator& aValidator);
    82 	inline void TransitMethodL();
    83 	inline CSuicideInterface_UnitTestContext& Context();
    84 	};
    85 
    86 #include "SuicideTransitions.inl"
    87 
    88 #endif	// __SUICIDETRANSITION_H__