|
1 // Copyright (c) 2006-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 "Symbian Foundation License v1.0" |
|
5 // which accompanies this distribution, and is available |
|
6 // at the URL "http://www.symbianfoundation.org/legal/sfl-v10.html". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // @file ctlbsstep_installscheduler.cpp |
|
15 // This is the class implementation for the Install Active Scheduler Test Step |
|
16 // |
|
17 // |
|
18 |
|
19 |
|
20 |
|
21 /** |
|
22 @file |
|
23 @internalTechnology |
|
24 @test |
|
25 */ |
|
26 |
|
27 #include "ctlbsstepinstallscheduler.h" |
|
28 |
|
29 CT_LbsStep_InstallScheduler::CT_LbsStep_InstallScheduler(CT_LbsServer& aParent) : CT_LbsStep(aParent) |
|
30 { |
|
31 SetTestStepName(KLbsStep_InstallScheduler); |
|
32 } |
|
33 |
|
34 /** |
|
35 Static Constructor |
|
36 */ |
|
37 CT_LbsStep_InstallScheduler* CT_LbsStep_InstallScheduler::New(CT_LbsServer& aParent) |
|
38 { |
|
39 return new CT_LbsStep_InstallScheduler(aParent); |
|
40 // Note the lack of ELeave. |
|
41 // This means that having insufficient memory will return NULL; |
|
42 } |
|
43 |
|
44 /** |
|
45 @pre No Active Scheduler installed in the worker test thread |
|
46 @return Test verdict |
|
47 @post Test server's Active Scheduler member installed in worker thread |
|
48 */ |
|
49 TVerdict CT_LbsStep_InstallScheduler::doTestStepL() |
|
50 { |
|
51 INFO_PRINTF1(_L(">>CT_LbsStep_InstallScheduler::doTestStepL()")); |
|
52 |
|
53 if( CActiveScheduler::Current() ) |
|
54 { |
|
55 INFO_PRINTF1(_L("Test Warning: Scheduler already installed in worker thread")); |
|
56 |
|
57 return TestStepResult(); |
|
58 } |
|
59 CActiveScheduler::Install( iParent.iScheduler ); |
|
60 |
|
61 INFO_PRINTF1(_L("<<CT_LbsStep_InstallScheduler::doTestStepL()")); |
|
62 |
|
63 return TestStepResult(); |
|
64 } |