javacommons/security/javaunicertstoreplugin/tsrc/utils/testutils.h
branchRCL_3
changeset 14 04becd199f91
equal deleted inserted replaced
13:f5050f1da672 14:04becd199f91
       
     1 /*
       
     2 * Copyright (c) 2009 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 "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 *
       
    16 */
       
    17 
       
    18 #ifndef TESTUTILS_H
       
    19 #define TESTUTILS_H
       
    20 
       
    21 #include <list>
       
    22 #include <cctcertinfo.h>
       
    23 #include <ct/rmpointerarray.h>
       
    24 #include "testdata.h"
       
    25 
       
    26 class CCertAttributeFilter;
       
    27 
       
    28 class TestUtils
       
    29 {
       
    30 public :
       
    31 
       
    32     /**
       
    33      * Starts java captain.
       
    34      */
       
    35     static int StartJavaCaptain();
       
    36 
       
    37     /**
       
    38      * @return Ownership of returned object is give to the user.
       
    39      */
       
    40     static CCertAttributeFilter* GetFilterObj();
       
    41 
       
    42     /**
       
    43      * This verification based on fact that size of content of each certificate
       
    44      * is unique.
       
    45      */
       
    46     static void CheckResultOfList(std::list<CertMetaData>& aExpected,
       
    47                                   RMPointerArray<CCTCertInfo>& aResult);
       
    48 
       
    49     static void CheckContentOfCert(std::list<CertMetaData>& aExpected,
       
    50                                    HBufC8* aContent);
       
    51 
       
    52 private :
       
    53 
       
    54     static bool sCaptainRunning;
       
    55 
       
    56 };
       
    57 
       
    58 #endif // TESTUTILS_H
       
    59