sysstatemgmt/systemstatemgr/test/tcmn/scripts/ssmatest_cmn_deferwocap.script
changeset 76 cb32bcc88bad
equal deleted inserted replaced
73:d38941471f1c 76:cb32bcc88bad
       
     1 // Copyright (c) 2010 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 "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: Testing for Transition Monitoring feature implemented as part of Staged Shutdown REQ for AppCentric architecture. This feature allows clients to defer acknowledgement to state change notifications during shutdown.
       
    14 //
       
    15 
       
    16 //!		@file			
       
    17 //!		@SYMTestSuiteName		DVS-SSMA-CMN-0015
       
    18 //!		@SYMScriptTestEnvironment   	Details as in below:-
       
    19 //!								1. testexecute framework(TEF3.0).
       
    20 //!								For the testing purpose define macro TEST_SSM_GRACEFUL_SHUTDOWN(For power off request feature) and SYMBIAN_INCLUDE_APP_CENTRIC(for transition monitoring feature).
       
    21 //!								Note: The system is going to be in shutdown state after executing this test and can not be restored to normal for executing other tests.
       
    22 //!								So this test has to be executed separately or at the end on overnight build machines. 
       
    23 //!		@SYMScriptPurpose		Test whether a client deferring without required capabilities results in an error
       
    24 //!		@SYMScriptCreationDate		18/08/2010
       
    25 
       
    26 RUN_PROGRAM -1 setcap tcmn_transitionmonitor.exe  00004	tcmn_transitionmonitor_wocap.exe
       
    27 LOAD_SUITE  tcmn_transitionmonitor_wocap
       
    28 
       
    29 START_TESTCASE			DVS-SSMA-CMN-0015
       
    30 //! @SYMTestCaseID		DVS-SSMA-CMN-0015
       
    31 //! @SYMPREQ 			SUB 405-5490
       
    32 //! @SYMTestType		CIT
       
    33 //! @SYMTestPriority		Critical
       
    34 //! @SYMTestStatus 		Implemented
       
    35 //! @SYMTestCaseDesc		Test the behaviour of a server which tries to defer state notification without appropriate capabilities
       
    36 //! @SYMTestActions		1.Create a thread and connect to the server with a domain Id and request for shutdown state change notification  
       
    37 //!				2.Request state change to ESsmShutdown
       
    38 //!				3.Defer acknowledgement, upon receiving state change notification to shutdown state, without WriteDeviceData and ProtServ capabilities
       
    39 //! @SYMTestExpectedResults 	Request to defer acknowledgement should fail with KErrPermissionDenied
       
    40 		
       
    41 START_TEST_BLOCK  100	tcmn_transitionmonitor_wocap	z:\ssmatest\ssmatest_cmn_transitionmonitor.ini
       
    42 	CREATE_OBJECT	RSsmStateAwareSession1  RSsmStateAwareSession1	
       
    43 	CREATE_OBJECT   RSsmStateManager	RSsmStateManager
       
    44 	COMMAND		RSsmStateAwareSession1	NewL
       
    45 	COMMAND		RSsmStateManager	NewL
       
    46 	COMMAND		RSsmStateAwareSession1	Connect	 			Domain
       
    47 	COMMAND		RSsmStateManager	Connect
       
    48 	COMMAND		RSsmStateAwareSession1	ReadIniData			DeferWoCap
       
    49 	COMMAND		!AsyncError=-46		RSsmStateAwareSession1		RequestStateNotification
       
    50 	COMMAND		RSsmStateManager	RequestStateTransition  	ShutdownTransitionCriticalSubState
       
    51 	OUTSTANDING
       
    52 	COMMAND		RSsmStateAwareSession1	Close
       
    53 	COMMAND		RSsmStateManager	Close
       
    54 	COMMAND		RSsmStateAwareSession1	~
       
    55 	COMMAND		RSsmStateManager	~
       
    56 END_TEST_BLOCK	
       
    57 END_TESTCASE			DVS-SSMA-CMN-0015