os/kernelhwsrv/kerneltest/e32test/property/t_prop_ldd_client.cpp
author sl
Tue, 10 Jun 2014 14:32:02 +0200
changeset 1 260cb5ec6c19
permissions -rw-r--r--
Update contrib.
     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 	}