Update contrib.
1 // Copyright (c) 2007-2010 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.
21 #include "t_wservintegstepsurface.h"
22 #include "t_wservconsts.h"
23 #include <test/t_simload.h>
26 CT_WServIntegStepSurface constructor.
29 @post CT_WServIntegStepSurface 1st stage constructor
31 CT_WServIntegStepSurface::CT_WServIntegStepSurface()
33 SetTestStepName(KT_WServIntegStepSurface);
39 @return TVerdict pass / fail
43 enum TVerdict CT_WServIntegStepSurface::doTestStepL()
49 GetConfigDataL(KSimLoadData(), KSimLoadDataName());
50 PrintConfigDataL(KSimLoadConfigFile());
54 // Semaphore created here to maintain compatibility with DSA test use of t_app1
55 RSemaphore dudSemaphore;
56 User::LeaveIfError(dudSemaphore.CreateGlobal(KWservDsaSemaphoreName(), 0));
58 GetConfigDataL(KTApp1Data(), KTApp1DataName());
59 PrintConfigDataL(KWServTApp1ConfigFile());
60 TInt err = CreateTestProcessL(KWServTApp1, EPriorityForeground);
64 GetConfigDataL(KPseudoAppData(), KPseudoAppDataName());
65 PrintConfigDataL(KWServPseudoAppConfigFile());
66 CreatePseudoAppProcL();
70 * Create a second process pseudoapp1.exe similar to pseudoapp.exe to test GCE
71 * composing two independent surfaces at different frame rates
73 TBool pseudoApp1=EFalse;
74 if ( GetBoolFromConfig(ConfigSection(),KCreatePseudoApp1, pseudoApp1) )
78 GetConfigDataL(KPseudoApp1Data(), KPseudoApp1DataName());
79 PrintConfigDataL(KWServPseudoApp1ConfigFile());
80 err=CreateTestProcessL(KWServPseudoApp1, EPriorityForeground);
84 WaitForTestL(KWServPseudoApp1FinishFile());
86 // retrieve results from pseudo app1
87 CheckResultsL(KPseudoApp1ResultData(), KPseudoApp1ResultDataName(), KWServPseudoApp1ResultFile());
88 PrintResultsL(KWServPseudoApp1ResultFile());
92 WaitForTestL(KWServPseudoAppFinishFile());
94 // retrieve results from pseudo app
95 CheckResultsL(KPseudoAppResultData(), KPseudoAppResultDataName(), KWServPseudoAppResultFile());
96 PrintResultsL(KWServPseudoAppResultFile());
103 return TestStepResult();
106 void CT_WServIntegStepSurface::CreateSimLoadProcL()
108 TInt simLoadAppErr = KErrNone;
110 TBuf<KMaxTestExecuteCommandLength> tempStore;
112 while (simLoadAppErr == KErrNone && index <= KNumSimLoadApps)
114 tempStore.Format(KSimLoadApp, index++);
116 simLoadAppErr = CreateTestProcessL(tempStore, EPriorityHigh);
120 void CT_WServIntegStepSurface::CreatePseudoAppProcL()
123 err = CreateTestProcessL(KWServPseudoApp, EPriorityForeground);