equal
deleted
inserted
replaced
1 // Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies). |
1 // Copyright (c) 2002-2010 Nokia Corporation and/or its subsidiary(-ies). |
2 // All rights reserved. |
2 // All rights reserved. |
3 // This component and the accompanying materials are made available |
3 // This component and the accompanying materials are made available |
4 // under the terms of the License "Eclipse Public License v1.0" |
4 // under the terms of the License "Eclipse Public License v1.0" |
5 // which accompanies this distribution, and is available |
5 // which accompanies this distribution, and is available |
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
39 #include <e32test.h> |
39 #include <e32test.h> |
40 #include <e32kpan.h> |
40 #include <e32kpan.h> |
41 #include <f32file.h> |
41 #include <f32file.h> |
42 #include <e32ldr.h> |
42 #include <e32ldr.h> |
43 #include <e32ldr_private.h> |
43 #include <e32ldr_private.h> |
|
44 #include "testexclusions.h" |
44 |
45 |
45 LOCAL_D RTest test(_L(" T_POWER ")); |
46 LOCAL_D RTest test(_L(" T_POWER ")); |
46 |
47 |
47 void SetAbsoluteTimeout(RTimer& aTimer, TUint aUs, TRequestStatus& aStatus) |
48 void SetAbsoluteTimeout(RTimer& aTimer, TUint aUs, TRequestStatus& aStatus) |
48 { |
49 { |
53 } |
54 } |
54 |
55 |
55 void PowerTests() |
56 void PowerTests() |
56 { |
57 { |
57 test.Next(_L("test PowerDown()")); |
58 test.Next(_L("test PowerDown()")); |
|
59 |
|
60 TInt testExclusions = 0; |
|
61 test_KErrNone(GetTestExclusionSettings(testExclusions)); |
|
62 |
|
63 if (testExclusions & KDisableControllerShutdown) |
|
64 { |
|
65 UserSvr::HalFunction(EHalGroupPower, EPowerHalPowerManagerTestMode, (TAny*)KDisableControllerShutdown, NULL); |
|
66 } |
58 |
67 |
59 TInt r = Power::PowerDown(); |
68 TInt r = Power::PowerDown(); |
60 test (r == KErrNotReady); |
69 test (r == KErrNotReady); |
61 |
70 |
62 for (int i = 0; i < 4; ++i) |
71 for (int i = 0; i < 4; ++i) |