os/ossrv/lowlevellibsandfws/pluginfw/Test_Bed/DefaultLogOutputTest/DefaultLogOutputTransitionValidation.h
changeset 0 bde4ae8d615e
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/os/ossrv/lowlevellibsandfws/pluginfw/Test_Bed/DefaultLogOutputTest/DefaultLogOutputTransitionValidation.h	Fri Jun 15 03:10:57 2012 +0200
     1.3 @@ -0,0 +1,292 @@
     1.4 +// Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
     1.5 +// All rights reserved.
     1.6 +// This component and the accompanying materials are made available
     1.7 +// under the terms of "Eclipse Public License v1.0"
     1.8 +// which accompanies this distribution, and is available
     1.9 +// at the URL "http://www.eclipse.org/legal/epl-v10.html".
    1.10 +//
    1.11 +// Initial Contributors:
    1.12 +// Nokia Corporation - initial contribution.
    1.13 +//
    1.14 +// Contributors:
    1.15 +//
    1.16 +// Description:
    1.17 +// The definitions of the transition classes upon the CDefaultLogOutput class methods.
    1.18 +// 
    1.19 +//
    1.20 +
    1.21 +#ifndef __DEFAULTLOGOUTPUTTRANSITIONVALIDATION_H__
    1.22 +#define __DEFAULTLOGOUTPUTTRANSITIONVALIDATION_H__
    1.23 +
    1.24 +#include "DefaultLogOutputTransitions.h"
    1.25 +
    1.26 +// ______________________________________________________________________________
    1.27 +//
    1.28 +/**
    1.29 +	@internalComponent
    1.30 +
    1.31 +	Comments : Provide all the CtorUnit Test's specific
    1.32 +	validatation for the state of a transition before and after its execution.
    1.33 +	on the CDefaultLogOutput test class for a transition.
    1.34 + */
    1.35 +class TDefaultLogOutput_Ctor_TransitionValidator : public TTransitionValidator
    1.36 +	{
    1.37 +public:
    1.38 +	/**
    1.39 +		@fn				TDefaultLogOutput_Ctor_TransitionValidator(CUnitTestContext& aUTContext)
    1.40 +		Intended Usage	:	
    1.41 +		@leave  		KErrNoMemory
    1.42 +		@since			7.0
    1.43 +		@param			aUTContext The context within which this transition is executing
    1.44 +	 */
    1.45 +	inline TDefaultLogOutput_Ctor_TransitionValidator(CUnitTestContext& aUTContext);
    1.46 +
    1.47 +	/**
    1.48 +		@fn				ValidatePreConditions()
    1.49 +		Intended Usage	: Implemented by the developer to check the
    1.50 +						end state of the transition behaviour.
    1.51 +		Error Condition	: Invalid pre-conditions
    1.52 +		@since			7.0
    1.53 +		@return			TBool ETrue if the pre-conditions were valid, EFalse otherwise.
    1.54 +		@pre 			TDefaultLogOutput_Ctor_TransitionValidator is fully constructed.
    1.55 +		@post			No change to the iUTContext class.
    1.56 +	*/
    1.57 +	virtual inline TBool ValidatePreConditions();
    1.58 +
    1.59 +	/**
    1.60 +		@fn				ValidatePostConditions(TTestBedAsyncState aAsyncState)
    1.61 +		Intended Usage	:	Implemented by the developer to check the
    1.62 +						end state of the transition behaviour.
    1.63 +						When overriding, if the transition calls an asynchronous function
    1.64 +						ValidatePostConditions will be called twice. Firstly, after the
    1.65 +						asynchronous function has been called and, secondly, after the 
    1.66 +						asynchronous request has completed. The parameter aAsyncState can
    1.67 +						be used to distinguish between these two cases.
    1.68 +		Error Condition	: Invalid post-conditions.
    1.69 +		@since			7.0
    1.70 +		@param			aAsyncState EAsyncCalled if the async function has been just been called,
    1.71 +						EAsyncCompleted if the function has completed.
    1.72 +		@return			TBool ETrue if the post-conditions were valid, EFalse otherwise.
    1.73 +		@pre 			TDefaultLogOutput_Ctor_TransitionValidator is fully constructed.
    1.74 +		@post			No change to the iUTContext class.
    1.75 +	*/
    1.76 +	virtual inline TBool ValidatePostConditions(TTestBedAsyncState aAsyncState);
    1.77 +	};	// TDefaultLogOutput_Ctor_TransitionValidator
    1.78 +
    1.79 +// ______________________________________________________________________________
    1.80 +//
    1.81 +/**
    1.82 +	@internalComponent
    1.83 +
    1.84 +	Comments : Provide all the DtorUnit Test's specific
    1.85 +	validatation for the state of a transition before and after its execution.
    1.86 +	on the CDefaultLogOutput test class for a transition.
    1.87 + */
    1.88 +class TDefaultLogOutput_Dtor_TransitionValidator : public TTransitionValidator
    1.89 +	{
    1.90 +public:
    1.91 +	/**
    1.92 +		@fn				TDefaultLogOutput_Dtor_TransitionValidator(CUnitTestContext& aUTContext)
    1.93 +		Intended Usage	:	
    1.94 +		@leave  		KErrNoMemory
    1.95 +		@since			7.0
    1.96 +		@param			aUTContext The context within which this transition is executing
    1.97 +	 */
    1.98 +	inline TDefaultLogOutput_Dtor_TransitionValidator(CUnitTestContext& aUTContext);
    1.99 +
   1.100 +	/**
   1.101 +		@fn				ValidatePreConditions()
   1.102 +		Intended Usage	: Implemented by the developer to check the
   1.103 +						end state of the transition behaviour.
   1.104 +		Error Condition	: Invalid pre-conditions
   1.105 +		@since			7.0
   1.106 +		@return			TBool ETrue if the pre-conditions were valid, EFalse otherwise.
   1.107 +		@pre 			TDefaultLogOutput_Dtor_TransitionValidator is fully constructed.
   1.108 +		@post			No change to the iUTContext class.
   1.109 +	*/
   1.110 +	virtual inline TBool ValidatePreConditions();
   1.111 +
   1.112 +	/**
   1.113 +		@fn				ValidatePostConditions(TTestBedAsyncState aAsyncState)
   1.114 +		Intended Usage	:	Implemented by the developer to check the
   1.115 +						end state of the transition behaviour.
   1.116 +						When overriding, if the transition calls an asynchronous function
   1.117 +						ValidatePostConditions will be called twice. Firstly, after the
   1.118 +						asynchronous function has been called and, secondly, after the 
   1.119 +						asynchronous request has completed. The parameter aAsyncState can
   1.120 +						be used to distinguish between these two cases.
   1.121 +		Error Condition	: Invalid post-conditions.
   1.122 +		@since			7.0
   1.123 +		@param			aAsyncState EAsyncCalled if the async function has been just been called,
   1.124 +						EAsyncCompleted if the function has completed.
   1.125 +		@return			TBool ETrue if the post-conditions were valid, EFalse otherwise.
   1.126 +		@pre 			TDefaultLogOutput_Dtor_TransitionValidator is fully constructed.
   1.127 +		@post			No change to the iUTContext class.
   1.128 +	*/
   1.129 +	virtual inline TBool ValidatePostConditions(TTestBedAsyncState aAsyncState);
   1.130 +	};	// TDefaultLogOutput_Dtor_TransitionValidator
   1.131 +
   1.132 +// ______________________________________________________________________________
   1.133 +//
   1.134 +/**
   1.135 +	@internalComponent
   1.136 +
   1.137 +	Comments : Provide all the OpenUnit Test's specific
   1.138 +	validatation for the state of a transition before and after its execution.
   1.139 +	on the CDefaultLogOutput test class for a transition.
   1.140 + */
   1.141 +class TDefaultLogOutput_Open_TransitionValidator : public TTransitionValidator
   1.142 +	{
   1.143 +public:
   1.144 +	/**
   1.145 +		@fn				TDefaultLogOutput_Open_TransitionValidator(CUnitTestContext& aUTContext)
   1.146 +		Intended Usage	:	
   1.147 +		@leave  		KErrNoMemory
   1.148 +		@since			7.0
   1.149 +		@param			aUTContext The context within which this transition is executing
   1.150 +	 */
   1.151 +	inline TDefaultLogOutput_Open_TransitionValidator(CUnitTestContext& aUTContext);
   1.152 +
   1.153 +	/**
   1.154 +		@fn				ValidatePreConditions()
   1.155 +		Intended Usage	: Implemented by the developer to check the
   1.156 +						end state of the transition behaviour.
   1.157 +		Error Condition	: Invalid pre-conditions
   1.158 +		@since			7.0
   1.159 +		@return			TBool ETrue if the pre-conditions were valid, EFalse otherwise.
   1.160 +		@pre 			TDefaultLogOutput_Open_TransitionValidator is fully constructed.
   1.161 +		@post			No change to the iUTContext class.
   1.162 +	*/
   1.163 +	virtual inline TBool ValidatePreConditions();
   1.164 +
   1.165 +	/**
   1.166 +		@fn				ValidatePostConditions(TTestBedAsyncState aAsyncState)
   1.167 +		Intended Usage	:	Implemented by the developer to check the
   1.168 +						end state of the transition behaviour.
   1.169 +						When overriding, if the transition calls an asynchronous function
   1.170 +						ValidatePostConditions will be called twice. Firstly, after the
   1.171 +						asynchronous function has been called and, secondly, after the 
   1.172 +						asynchronous request has completed. The parameter aAsyncState can
   1.173 +						be used to distinguish between these two cases.
   1.174 +		Error Condition	: Invalid post-conditions.
   1.175 +		@since			7.0
   1.176 +		@param			aAsyncState EAsyncCalled if the async function has been just been called,
   1.177 +						EAsyncCompleted if the function has completed.
   1.178 +		@return			TBool ETrue if the post-conditions were valid, EFalse otherwise.
   1.179 +		@pre 			TDefaultLogOutput_Open_TransitionValidator is fully constructed.
   1.180 +		@post			No change to the iUTContext class.
   1.181 +	*/
   1.182 +	virtual inline TBool ValidatePostConditions(TTestBedAsyncState aAsyncState);
   1.183 +	};	// TDefaultLogOutput_Open_TransitionValidator
   1.184 +
   1.185 +// ______________________________________________________________________________
   1.186 +//
   1.187 +/**
   1.188 +	@internalComponent
   1.189 + 
   1.190 +	Comments : Provide all the CloseUnit Test's specific
   1.191 +	validatation for the state of a transition before and after its execution.
   1.192 +	on the CDefaultLogOutput test class for a transition.
   1.193 + */
   1.194 +class TDefaultLogOutput_Close_TransitionValidator : public TTransitionValidator
   1.195 +	{
   1.196 +public:
   1.197 +	/**
   1.198 +		@fn				TDefaultLogOutput_Close_TransitionValidator(CUnitTestContext& aUTContext)
   1.199 +		Intended Usage	:	
   1.200 +		@leave  		KErrNoMemory
   1.201 +		@since			7.0
   1.202 +		@param			aUTContext The context within which this transition is executing
   1.203 +	 */
   1.204 +	inline TDefaultLogOutput_Close_TransitionValidator(CUnitTestContext& aUTContext);
   1.205 +
   1.206 +	/**
   1.207 +		@fn				ValidatePreConditions()
   1.208 +		Intended Usage	: Implemented by the developer to check the
   1.209 +						end state of the transition behaviour.
   1.210 +		Error Condition	: Invalid pre-conditions
   1.211 +		@since			7.0
   1.212 +		@return			TBool ETrue if the pre-conditions were valid, EFalse otherwise.
   1.213 +		@pre 			TDefaultLogOutput_Close_TransitionValidator is fully constructed.
   1.214 +		@post			No change to the iUTContext class.
   1.215 +	*/
   1.216 +	virtual inline TBool ValidatePreConditions();
   1.217 +
   1.218 +	/**
   1.219 +		@fn				ValidatePostConditions(TTestBedAsyncState aAsyncState)
   1.220 +		Intended Usage	:	Implemented by the developer to check the
   1.221 +						end state of the transition behaviour.
   1.222 +						When overriding, if the transition calls an asynchronous function
   1.223 +						ValidatePostConditions will be called twice. Firstly, after the
   1.224 +						asynchronous function has been called and, secondly, after the 
   1.225 +						asynchronous request has completed. The parameter aAsyncState can
   1.226 +						be used to distinguish between these two cases.
   1.227 +		Error Condition	: Invalid post-conditions.
   1.228 +		@since			7.0
   1.229 +		@param			aAsyncState EAsyncCalled if the async function has been just been called,
   1.230 +						EAsyncCompleted if the function has completed.
   1.231 +		@return			TBool ETrue if the post-conditions were valid, EFalse otherwise.
   1.232 +		@pre 			TDefaultLogOutput_Close_TransitionValidator is fully constructed.
   1.233 +		@post			No change to the iUTContext class.
   1.234 +	*/
   1.235 +	virtual inline TBool ValidatePostConditions(TTestBedAsyncState aAsyncState);
   1.236 +	};	// TDefaultLogOutput_Close_TransitionValidator
   1.237 +
   1.238 +// ______________________________________________________________________________
   1.239 +//
   1.240 +/**
   1.241 +	@internalComponent
   1.242 +
   1.243 +	Comments : Provide all the WriteUnit Test's specific
   1.244 +	validatation for the state of a transition before and after its execution.
   1.245 +	on the CDefaultLogOutput test class for a transition.
   1.246 + */
   1.247 +class TDefaultLogOutput_Write_TransitionValidator : public TTransitionValidator
   1.248 +	{
   1.249 +public:
   1.250 +	/**
   1.251 +		@fn				TDefaultLogOutput_Write_TransitionValidator(CUnitTestContext& aUTContext)
   1.252 +		Intended Usage	:	
   1.253 +		@leave  		KErrNoMemory
   1.254 +		@since			7.0
   1.255 +		@param			aUTContext The context within which this transition is executing
   1.256 +	 */
   1.257 +	inline TDefaultLogOutput_Write_TransitionValidator(CUnitTestContext& aUTContext);
   1.258 +
   1.259 +	/**
   1.260 +		@fn				ValidatePreConditions()
   1.261 +		Intended Usage	: Implemented by the developer to check the
   1.262 +						end state of the transition behaviour.
   1.263 +		Error Condition	: Invalid pre-conditions
   1.264 +		@since			7.0
   1.265 +		@return			TBool ETrue if the pre-conditions were valid, EFalse otherwise.
   1.266 +		@pre 			TDefaultLogOutput_Write_TransitionValidator is fully constructed.
   1.267 +		@post			No change to the iUTContext class.
   1.268 +	*/
   1.269 +	virtual inline TBool ValidatePreConditions();
   1.270 +
   1.271 +	/**
   1.272 +		@fn				ValidatePostConditions(TTestBedAsyncState aAsyncState)
   1.273 +		Intended Usage	:	Implemented by the developer to check the
   1.274 +						end state of the transition behaviour.
   1.275 +						When overriding, if the transition calls an asynchronous function
   1.276 +						ValidatePostConditions will be called twice. Firstly, after the
   1.277 +						asynchronous function has been called and, secondly, after the 
   1.278 +						asynchronous request has completed. The parameter aAsyncState can
   1.279 +						be used to distinguish between these two cases.
   1.280 +		Error Condition	: Invalid post-conditions.
   1.281 +		@since			7.0
   1.282 +		@param			aAsyncState EAsyncCalled if the async function has been just been called,
   1.283 +						EAsyncCompleted if the function has completed.
   1.284 +		@return			TBool ETrue if the post-conditions were valid, EFalse otherwise.
   1.285 +		@pre 			TDefaultLogOutput_Write_TransitionValidator is fully constructed.
   1.286 +		@post			No change to the iUTContext class.
   1.287 +	*/
   1.288 +	virtual inline TBool ValidatePostConditions(TTestBedAsyncState aAsyncState);
   1.289 +	};	// TDefaultLogOutput_Write_TransitionValidator
   1.290 +
   1.291 +
   1.292 +#include "DefaultLogOutputTransitionValidation.inl"
   1.293 +
   1.294 +#endif // __DEFAULTLOGOUTPUTTRANSITIONVALIDATION_H__
   1.295 +