os/graphics/graphicsresourceservices/graphicsresourceimplementation/test/inc/tgraphicsresourceinternalteststepbase.h
Update contrib.
1 // Copyright (c) 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".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
15 #ifndef TGRAPHICSRESOURCEINTERNALTESTSTEPBASE_H
16 #define TGRAPHICSRESOURCEINTERNALTESTSTEPBASE_H
18 #include <test/ttmsgraphicsstep.h>
19 #include <sgresource/sgresource.h>
20 #include "tgraphicsresourcemultiprocessthread.h"
21 #include "tgraphicsresourceinternalsecondprocessenums.h"
24 Base Class for the Graphics Resource internal tests; contains helper functions
25 for creating second processes and retrieving test results or checking panics.
27 class CTGraphicsResourceInternalBase : public CTTMSGraphicsStep
30 CTGraphicsResourceInternalBase();
31 ~CTGraphicsResourceInternalBase();
33 inline void testBooleanTrue(TBool aCondition, const TText8* aFile, TInt aLine);
34 inline void testBooleanTrueWithErrorCode(TBool aCondition, TInt aErrorCode, const TText8* aFile, TInt aLine);
36 TInt CreateSecondProcessAndDoTestL(const TDesC &aProcessName, TSgResIntTestInfo& aTestInfo);
37 void CreateSecondProcessAndCheckAllocPanicL(const TDesC &aProcessName, TSgResIntTestInfo& aTestInfo, const TDesC &aAllocType);
40 inline void CTGraphicsResourceInternalBase::testBooleanTrue(TBool aCondition, const TText8* aFile, TInt aLine)
42 MQCTest(aCondition, aFile, aLine);
45 inline void CTGraphicsResourceInternalBase::testBooleanTrueWithErrorCode(TBool aCondition, TInt aErrorCode, const TText8* aFile, TInt aLine)
47 MQCTestWithErrorCode(aCondition, aErrorCode, aFile, aLine);
50 #endif // TGRAPHICSRESOURCEINTERNALTESTSTEPBASE_H