kerneltest/e32test/property/t_prop_ldd_client.cpp
changeset 0 a41df078684a
equal deleted inserted replaced
-1:000000000000 0:a41df078684a
       
     1 // Copyright (c) 2002-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 the License "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".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 //
       
    15 
       
    16 #include "t_prop_ldd.h"
       
    17 #include "t_property.h"
       
    18 
       
    19 _LIT(KPropLddClientName, "RPropertyRef Basics");
       
    20  
       
    21 CPropLddClient::CPropLddClient(TUid aCategory, TUint aKey, RProperty::TType aType) : 
       
    22 	  CTestProgram(KPropLddClientName), iCategory(aCategory), iKey(aKey), iType(aType)
       
    23 	{
       
    24 	}
       
    25 
       
    26 void CPropLddClient::Run(TUint aCount)
       
    27 	{
       
    28 	TInt r = User::LoadLogicalDevice(KPropLddFileName);
       
    29 	TF_ERROR(r, (r == KErrNone) || (r == KErrAlreadyExists));
       
    30 
       
    31 	RPropChannel ch;
       
    32 
       
    33 	r = ch.Open();
       
    34 	TF_ERROR(r, r == KErrNone);
       
    35 
       
    36 	TBool ok = ch.BasicTests(aCount, iCategory, iKey, iType);
       
    37 	TF_ERROR(ok, ok);
       
    38 
       
    39 	ch.Close();
       
    40 	}