installationservices/swcomponentregistry/test/tscr/inc/subsessionsteps.h
branchRCL_3
changeset 25 7333d7932ef7
equal deleted inserted replaced
24:5cc91383ab1e 25:7333d7932ef7
       
     1 /*
       
     2 * Copyright (c) 2008-2010 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 the License "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: 
       
    15 * Defines the basic test step for the Software Component Registry test harness
       
    16 *
       
    17 */
       
    18 
       
    19 
       
    20 /**
       
    21  @file 
       
    22  @internalComponent
       
    23  @test
       
    24 */
       
    25 
       
    26 #ifndef SUBSESSIONSTEPS_H
       
    27 #define SUBSESSIONSTEPS_H
       
    28 
       
    29 #include "tscrstep.h"
       
    30 
       
    31 
       
    32 class CScrTestServer;
       
    33 
       
    34 _LIT(KScrComponentRegistrySubsessionStep, "ScrComponentRegistrySubsession");
       
    35 _LIT(KScrFileListSubsessionStep, "ScrFileListSubsession");
       
    36 _LIT(KScrAppViewSubsessionStep, "ScrAppViewSubsession");
       
    37 
       
    38 class CScrComponentRegistrySubsessionStep : public CScrTestStep
       
    39 /**
       
    40  	TEF test step which exercises the SCR RSoftwareComponentRegistryView interface
       
    41  */
       
    42 	{
       
    43 public:
       
    44 	 CScrComponentRegistrySubsessionStep(CScrTestServer& aParent);
       
    45 			
       
    46 protected:
       
    47 	// From CScrTestStep
       
    48 	void ImplTestStepPreambleL();
       
    49 	void ImplTestStepL();
       
    50 	void ImplTestStepPostambleL();
       
    51 private:	
       
    52 	void TestSingleModeL(const Usif::RSoftwareComponentRegistryView& aSubSession, RPointerArray<Usif::CComponentEntry>& aExpectedEntries);
       
    53 	void TestSetModeL(const Usif::RSoftwareComponentRegistryView& aSubSession, TInt aSetSize, RPointerArray<Usif::CComponentEntry>& aExpectedEntries);
       
    54 	void VerifyNonReturnedEntriesL(const RPointerArray<Usif::CComponentEntry>& aExpectedEntries);
       
    55 	void GetComponentEntriesFromConfigL(RPointerArray<Usif::CComponentEntry>& aEntries);
       
    56 	};
       
    57 
       
    58 class CScrFileListSubsessionStep : public CScrTestStep
       
    59 /**
       
    60  	TEF test step which exercises the SCR RSoftwareComponentRegistryFilesList interface
       
    61  */
       
    62 	{
       
    63 public:
       
    64 	CScrFileListSubsessionStep(CScrTestServer& aParent);
       
    65 			
       
    66 protected:
       
    67 	// From CScrTestStep
       
    68 	void ImplTestStepPreambleL();
       
    69 	void ImplTestStepL();
       
    70 	void ImplTestStepPostambleL();
       
    71 private:
       
    72 	void TestSingleModeL(const Usif::RSoftwareComponentRegistryFilesList& aSubSession, RPointerArray<HBufC>& expectedFiles);
       
    73 	void TestSetModeL(const Usif::RSoftwareComponentRegistryFilesList& aSubSession, TInt aSetSize, RPointerArray<HBufC>& expectedFiles);
       
    74 	void VerifyNonReturnedFilesL(const RPointerArray<HBufC>& aExpectedFiles);
       
    75 	void ReportUnexpectedFileL(const TDesC& aUnexpectedFileName);
       
    76 	};
       
    77 
       
    78 
       
    79 class CAppInfoView : public CScrTestStep
       
    80 /**
       
    81  	TEF test step which exercises the SCR RApplicationInfoView interface
       
    82  */
       
    83 	{
       
    84 public:
       
    85     CAppInfoView(CScrTestServer& aParent);
       
    86 			
       
    87 protected:
       
    88 	// From CScrTestStep
       
    89 	void ImplTestStepPreambleL();
       
    90 	void ImplTestStepL();
       
    91 	void ImplTestStepPostambleL();
       
    92 private:
       
    93 	//
       
    94 	void TestSessionL(TInt aNoOfEntries, const Usif::RApplicationInfoView& aSubSession, RPointerArray<Usif::TAppRegInfo>& aExpectedEntries);
       
    95 	void GetAppEntryFromConfigL(RPointerArray<Usif::TAppRegInfo>& aEntries);
       
    96 	void VerifyNonReturnedEntriesL(const RPointerArray<Usif::TAppRegInfo>& aExpectedEntries);
       
    97 	};
       
    98 
       
    99 #endif /* SUBSESSIONSTEPS_H */