sysstatemgmt/systemstateplugins/test/tunitadptplugin/src/trtc_adaptationplugin_step.cpp
--- a/sysstatemgmt/systemstateplugins/test/tunitadptplugin/src/trtc_adaptationplugin_step.cpp Tue Aug 31 16:29:05 2010 +0300
+++ b/sysstatemgmt/systemstateplugins/test/tunitadptplugin/src/trtc_adaptationplugin_step.cpp Wed Sep 01 12:34:26 2010 +0100
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
// All rights reserved.
// This component and the accompanying materials are made available
// under the terms of "Eclipse Public License v1.0"
@@ -20,16 +20,14 @@
*/
-#include <e32property.h>
+
#include <s32mem.h>
#include "trtc_adaptationplugin_step.h"
//
// Run the tests
//
-_LIT (KExeToDefineTestPS, "\\sys\\bin\\definetestps.exe");
-const TUint32 KRtcAdaptationPluginPropertyKey = 0x2000D76C;
-const TUid KPropertyCategory={0x2000D75B};
+
CTestRtcAdaptationPlugin::CTestRtcAdaptationPlugin()
:CAdaptationTestBase(KTCTestRtcAdaptationPlugin)
@@ -55,7 +53,7 @@
if(iSsmRtcAdaptation.Handle())
{
TEST(KErrNotSupported == status.Int());
- INFO_PRINTF3(_L("CTestRtcAdaptationPlugin::TestValidateRtc completed with %d error : expected %d>"),status.Int(),KErrNotSupported);
+ INFO_PRINTF3(_L("CTestRtcAdaptationPlugin::TestValidateRtc completed with %d error : expected %d>"),status.Int(),KErrNone);
}
else
{
@@ -76,7 +74,7 @@
if(iSsmRtcAdaptation.Handle())
{
TEST(KErrNotSupported == status.Int());
- INFO_PRINTF3(_L("CTestRtcAdaptationPlugin::TestSetWakeupAlarm completed with %d error : expected %d>"),status.Int(),KErrNotSupported);
+ INFO_PRINTF3(_L("CTestRtcAdaptationPlugin::TestSetWakeupAlarm completed with %d error : expected %d>"),status.Int(),KErrNone);
}
else
{
@@ -96,7 +94,7 @@
if(iSsmRtcAdaptation.Handle())
{
TEST(KErrNotSupported == status.Int());
- INFO_PRINTF3(_L("CTestRtcAdaptationPlugin::TestUnsetWakeupAlarm completed with %d error : expected %d>"),status.Int(),KErrNotSupported);
+ INFO_PRINTF3(_L("CTestRtcAdaptationPlugin::TestUnsetWakeupAlarm completed with %d error : expected %d>"),status.Int(),KErrNone);
}
else
{
@@ -116,29 +114,9 @@
//from CAdaptationTestBase
TVerdict CTestRtcAdaptationPlugin::doTestStepL()
{
+ TInt err = KErrNone;
+
__UHEAP_MARK;
-
- RProcess processHandle;
- CleanupClosePushL(processHandle);
-
- //Start the test exe which defines startup related property keys
-
- TInt err = processHandle.Create(KExeToDefineTestPS, KNullDesC);
- INFO_PRINTF2(_L("Process creation returned : %d"), err);
- User::LeaveIfError(err);
- processHandle.Resume();
-
- // wait for the newly created process to rendezvous
- TRequestStatus status;
- processHandle.Rendezvous(status);
- User::WaitForRequest(status);
- TInt retVal = status.Int();
- INFO_PRINTF2(_L("iStatus.Int() returned : %d"), retVal);
- TEST(KErrNone == retVal);
- CleanupStack::PopAndDestroy();
-
- err = RProperty::Set(KPropertyCategory, KRtcAdaptationPluginPropertyKey, 1);
- TEST(KErrNone == err);
TRAP(err, TestValidateRtc());
TEST(err == KErrNone);
@@ -164,8 +142,7 @@
TestCancel();
//TestRelease(); // have to test this part too ...
- err = RProperty::Set(KPropertyCategory, KRtcAdaptationPluginPropertyKey, 0);
- TEST(KErrNone == err);
+
__UHEAP_MARKEND;
return TestStepResult();