lbstest/lbstestproduct/lbsclient/scripts/lbsclientnotifyposupdate.script
author Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
Tue, 02 Feb 2010 01:50:39 +0200
changeset 0 9cfd9a3ee49c
child 57 3267d9ea3e98
permissions -rw-r--r--
Revision: 201002 Kit: 201005

// Copyright (c) 2006-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"
// which accompanies this distribution, and is available
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
//
// Initial Contributors:
// Nokia Corporation - initial contribution.
//
// Contributors:
//
// Description:
// Delete the old log file
//

//! @File
//! @SYMTestSuiteName lbsclientnotifyposupdate
//! @SYMScriptTestEnvironment TestExecute

RUN_UTILS DeleteFile c:\private\101f401d\Logdbu.dat

LOAD_SUITE LbsClientTestServer -SharedData

PRINT Run LbsClientTestServer
PRINT

// Before we start LBS, select the test A-GPS integration module and network reg status txt file to use.
PREFIX RUN_UTILS
	MkDir c:\private\10282253\
	MkDir c:\private\10282253\lbs\
	MkDir c:\private\10282253\lbs\locmods\
	CopyFile c:\testdata\configs\xtestmodule.ini c:\private\10282253\lbs\locmods\agpsintegmodule.ini
    CopyFile c:\testdata\configs\lbstestconfig.txt c:\config.txt
 	DeleteFile c:\private\10202be9\1028224b.cre
 	DeleteFile c:\private\10202be9\persists\1028224b.cre
 	DeleteFile c:\private\10282253\lbs\lbsprofile.ini
REMOVE_PREFIX

RUN_TEST_STEP 010 LbsClientTestServer LbsStep_ResetDefaultAdmin

RUN_TEST_STEP 010 LbsClientTestServer LbsStep_StartLbs
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetAutonomousMode



START_TESTCASE                LBS-Client-NotifyPosUpdate-0001
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0001
//! @SYMTestCaseDesc            Request a single location update (default options) from GPS
//! @SYMTestPriority            Critical
//! @SYMTestActions             1. Setup Test-GPS-module.
//!                             2. Set Requestor details.
//!                             3. Request Location Update.
//!                             4. Wait for location request to complete.
//!                             5. Verify that location info is returned as expected.
//!                             6. Verify that the location request is logged.
//! @SYMTestExpectedResults     Location request will complete with KErrNone and position info will be published
//! @SYMTestType                CIT
//! @SYMCreationDate            20/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_CreateVerifyPosInfos c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0001
RUN_TEST_STEP 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0001
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_VerifyPosInfos
//RUN_TEST_STEP 010 LbsClientTestServer LbsStep_VerifyLogInfo
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0001


START_TESTCASE                LBS-Client-NotifyPosUpdate-0002
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0002
//! @SYMTestCaseDesc            Request Location Update while the system-wide location on/off parameter is turned off
//! @SYMTestPriority            Critical
//! @SYMTestActions             1. Turn off self-locate in admin settings
//!                             2. Request Location Update
//!                             3. Wait for location request to complete.
//!                             4. Verify that the request completes with KErrAccessDenied
//! @SYMTestExpectedResults     Request fails with KErrArgument
//! @SYMTestType                CIT
//! @SYMCreationDate            20/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
RUN_TEST_STEP 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0005
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0002


START_TESTCASE                LBS-Client-NotifyPosUpdate-0003
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0003
//! @SYMTestCaseDesc            Request Location Update, and cancel before request completes
//! @SYMTestPriority            Critical
//! @SYMTestActions             1. Request Location Update
//!                             2. Cancel Location Update
//!                             3. Verify that the requests completes as appropriate according to result from Cancel
//! @SYMTestExpectedResults     CancelRequest completes with KErrNone and location request completes with KErrCancel or KErrNone or CancelRequest completes with KErrNotFound and location request completes with KErrNone
//! @SYMTestType                CIT
//! @SYMCreationDate            20/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_CreateVerifyPosInfos
RUN_TEST_STEP 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0006
//RUN_TEST_STEP 010 LbsClientTestServer LbsStep_VerifyLogInfo
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0003


START_TESTCASE                LBS-Client-NotifyPosUpdate-0004
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0004
//! @SYMTestCaseDesc            Request Location Update without connecting to position server - panic expected
//! @SYMTestPriority            High
//! @SYMTestActions             1. Request Location Update (without first connecting to position server)
//! @SYMTestExpectedResults     Client panics with EPositionServerBadHandle
//! @SYMTestType                CIT
//! @SYMCreationDate            20/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP !PanicCode=6 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0007
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0004


START_TESTCASE                LBS-Client-NotifyPosUpdate-0005
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0005
//! @SYMTestCaseDesc            Request Multiple Location Updates on same subsession concurrently
//! @SYMTestPriority            High
//! @SYMTestActions             1. Open a subsession
//!                             2. Request Location Update on subsession
//!                             3. Request another Location Update on subsession
//! @SYMTestExpectedResults     Client panics with EPositionDuplicateRequest
//! @SYMTestType                CIT
//! @SYMCreationDate            20/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_CreateVerifyPosInfos
RUN_TEST_STEP !PanicCode=15 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0008
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0005


START_TESTCASE                LBS-Client-NotifyPosUpdate-0006
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0006
//! @SYMTestCaseDesc            Multiple sequential Location Update requests
//! @SYMTestPriority            High
//! @SYMTestActions             1. Request Location Update
//!                             2. Wait for request to complete
//!                             3. Verify that request completed successfully
//!                             4. Repeat above a number of times (read from config)
//!                             5. Verify that location infos are as expected.
//! @SYMTestExpectedResults     All Requests complete successfully
//! @SYMTestType                CIT
//! @SYMCreationDate            20/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_CreateVerifyPosInfos	c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0019
RUN_TEST_STEP 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate 		c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0019
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_VerifyPosInfos
//RUN_TEST_STEP 010 LbsClientTestServer LbsStep_VerifyLogInfo
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0006


START_TESTCASE                LBS-Client-NotifyPosUpdate-0007
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0007
//! @SYMTestCaseDesc            Confirm that partial updates are getting at specified intervals
//! @SYMTestPriority            Critical
//! @SYMTestActions             1.Open positioner with configured required quality.
//!                             2.Configure partial Updates with ETrue.
//!                             3.Set the UpdateInterval to some non default value.
//!                             4.Call SetUpdateOptions to update position info at specified intervals.
//!                             5.Request Location Update by Calling NotifyPositionUpdate() Note: each time partial update is received we need to reissue the location request until full location received.
//!                             6.Verify that location info is returned as expected.
//! @SYMTestExpectedResults     we should get partial updates at specified intervals
//! @SYMTestType                CIT
//! @SYMCreationDate            20/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_CreateVerifyModuleData c:\testdata\configs\lbsclientupdateoptions.ini LBS-UPDATE-OPTS-020
RUN_TEST_STEP 120 LbsClientTestServer LbsClientStep_UpdateOptions c:\testdata\configs\LbsClientUpdateOptions.ini LBS-UPDATE-OPTS-020
//RUN_TEST_STEP 010 LbsClientTestServer LbsStep_VerifyLogInfo
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0007


PRINT Stop LBS
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_StopLbs

// Before we restart LBS, select lbstestprofile.ini to use for the following tests
 RUN_UTILS CopyFile c:\testdata\configs\lbstestprofile.ini c:\private\10282253\lbs\lbsprofile.ini

RUN_TEST_STEP 010 LbsClientTestServer LbsStep_StartLbs


START_TESTCASE                LBS-Client-NotifyPosUpdate-0008
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0008
//! @SYMTestCaseDesc            Request a single location update by setting required quality profile Id in admin
//! @SYMTestPriority            Critical
//! @SYMTestActions             1. Set KSettingQualityProfileSelfLocate and valid id in admin settings.
//!                             2. open Rpositioner with default positioning module
//!                             3. Request Location Update.
//!                             4. Wait for location request to complete.
//!                             5. verify Position received within the time range
//!                             6. Verify that location info is returned as expected.
//!                             7. Verify that the location request is logged.
//! @SYMTestExpectedResults     Location request will complete with KErrNone and position info will be published
//! @SYMTestType                CIT
//! @SYMCreationDate            28/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_CreateVerifyPosInfos c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0022
RUN_TEST_STEP 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0022
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_VerifyPosInfos
//RUN_TEST_STEP 010 LbsClientTestServer LbsStep_VerifyLogInfo
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0008


START_TESTCASE                LBS-Client-NotifyPosUpdate-0009
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0009
//! @SYMTestCaseDesc            Confirm that NotifyPositionUpdate will timeout after a specified period.
//! @SYMTestPriority            Critical
//! @SYMTestActions             1. Set KSettingQualityProfileSelfLocate and valid id in admin settings.
//!                             2. open Rpositioner with default positioning module
//!                             3. Request Location Update.
//!                             4. Wait for location request to complete. NOTE : Ensure NotifyPositionUpdate will return KErrTimedOut
//! @SYMTestExpectedResults     We should receive NotifyPositionUpdate will return KErrTimedOut
//! @SYMTestType                CIT
//! @SYMCreationDate            28/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_CreateVerifyPosInfos c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0024
RUN_TEST_STEP 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0024
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0009
START_TESTCASE                LBS-Client-NotifyPosUpdate-0010
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0010
//! @SYMTestCaseDesc            Confirm that NotifyPositionUpdate will timeout after a specified period as the position provide by the module is less accurate than the required
//! @SYMTestPriority            Critical
//! @SYMTestActions             1. Set an appropriate request timeout and configure the test module not to return a complete update during that time..
//!                             2. open Rpositioner with default positioning module
//!                             3. Request Location Update. Note: Make sure  the position provided by the testmodule is less accurate than the required.
//!                             4. Wait for location request to complete. NOTE : Ensure NotifyPositionUpdate will return KErrTimedOut
//! @SYMTestExpectedResults     We should receive NotifyPositionUpdate will return KErrTimedOut
//! @SYMTestType                CIT
//! @SYMCreationDate            28/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_CreateVerifyPosInfos c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0025
RUN_TEST_STEP 140 LbsClientTestServer LbsClientStep_NotifyPosUpdate c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0025
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0010



START_TESTCASE                LBS-Client-NotifyPosUpdate-0011
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0011
//! @SYMTestCaseDesc            Confirm that NotifyPositionUpdate will timeout after a specified period, and that a subsequent request is handled
//! @SYMTestPriority            Critical
//! @SYMTestActions             1. Set KSettingQualityProfileSelfLocate and valid id in admin settings.
//!                             2. Configure the update options to have a 5-second timeout and 15-second interval
//!                             3. open Rpositioner with default positioning module
//!                             4. Request Location Update.
//!                             5. Wait for location request to complete without error.
//!                             6. Configure a delay in the test AGPS Manager big enough to guarantee that the request will time out
//!                             7. On timeout (status == KErrTimeOut), reduce the AGPS Manager delay back to the original value and issue another position update request.
//!                             8. Check that the last request completes without error
//! @SYMTestExpectedResults     We should receive NotifyPositionUpdate will return KErrNone
//! @SYMTestType                CIT
//! @SYMCreationDate            28/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_CreateVerifyPosInfos c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0026
RUN_TEST_STEP 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0026
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0011



START_TESTCASE                LBS-Client-NotifyPosUpdate-0012
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0012
//! @SYMTestCaseDesc            Location update that doesn't satisfy the quality requirements from profile
//! @SYMTestPriority            Medium
//! @SYMTestActions             1. Request Location Update
//!                             2. Wait for request to complete
//!                             3. Verify that request completed successfully
//!                             4. Verify that location infos are as expected.
//!                             
//! @SYMTestExpectedResults    	Request completes with KErrNone
//! @SYMTestType                CIT
//! @SYMCreationDate            28/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_CreateVerifyPosInfos	c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0027
RUN_TEST_STEP 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate 		c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0027
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_VerifyPosInfos
//RUN_TEST_STEP 010 LbsClientTestServer LbsStep_VerifyLogInfo
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0012



START_TESTCASE                LBS-Client-NotifyPosUpdate-0013
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0013
//! @SYMTestCaseDesc            Confirm that NotifyPositionUpdate will timeout after a specified period.
//! @SYMTestPriority            Critical
//! @SYMTestActions             1. Set KSettingQualityProfileSelfLocate and valid id in admin settings.
//!                             2. open Rpositioner with default positioning module
//!                             3. Request Location Update.
//!                             4. Wait for location request to complete. NOTE : Ensure NotifyPositionUpdate will return KErrTimedOut
//! @SYMTestExpectedResults     We should receive NotifyPositionUpdate will return KErrTimedOut
//! @SYMTestType                CIT
//! @SYMCreationDate            28/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_CreateVerifyPosInfos c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0028
RUN_TEST_STEP 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0028
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0013



START_TESTCASE                LBS-Client-NotifyPosUpdate-0014
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0014
//! @SYMTestCaseDesc            Confirm that vertical accuracy will not be checked when a position is returned
//! @SYMTestPriority            Critical
//! @SYMTestActions             1. open Rpositioner with default positioning module
//!                             2. Request Location Update.
//!                             3. The module will returned a position that is accurate horizontaly, but inaccurate verticaly
//! @SYMTestExpectedResults     We should receive the returned position
//! @SYMTestType                CIT
//! @SYMCreationDate            28/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
// The test is using lbstestprofile.ini for profile and the Admin setting is picking the Profile with ID 0, so a vertical accuracy of 1000 will be expected
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_CreateVerifyPosInfos c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0029
RUN_TEST_STEP 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0029
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_VerifyPosInfos
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0014



START_TESTCASE                LBS-Client-NotifyPosUpdate-0015
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0015
//! @SYMTestCaseDesc            Confirm that vertical information doesn't need to be present
//! @SYMTestPriority            Critical
//! @SYMTestActions             1. open Rpositioner with default positioning module
//!                             2. Request Location Update.
//!                             3. The module will returned a position that doesn't have any vertical information
//! @SYMTestExpectedResults     We should receive the returned position
//! @SYMTestType                CIT
//! @SYMCreationDate            28/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
// The test is using lbstestprofile.ini for profile and the Admin setting is picking the Profile with ID 0, so a vertical accuracy of 1000 will be expected
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_CreateVerifyPosInfos c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0030
RUN_TEST_STEP 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0030
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_VerifyPosInfos
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0015


START_TESTCASE                LBS-Client-NotifyPosUpdate-0201
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0201
//! @SYMTestCaseDesc            Request a single location update (default options) from GPS
//!                             This case also tests the logging API by verifying the relevant logs are written, can be read
//!                             and as are expected, an external log, an assistance data log and a self locate log.
//! @SYMTestPriority            Critical
//! @SYMTestActions             See test case "LBS-NotifyPosUpdate-0001" for details.
//! @SYMTestExpectedResults     See test case "LBS-NotifyPosUpdate-0001" for details.
//! @SYMTestType                CIT
//! @SYMCreationDate            20/8/2008
//! @SYMAuthor                  alans
PRINT Stop LBS
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_StopLbs
RUN_UTILS DeleteFile c:\private\10282253\lbs\lbsprofile.ini
RUN_UTILS CopyFile c:\testdata\configs\lbstestprofile.ini c:\private\10282253\lbs\lbsprofile.ini
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetBehaviourModeOriginal
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_StartLbs
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_ClearLog
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_CreateVerifyPosInfos c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0201
RUN_TEST_STEP 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0201
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_VerifyPosInfos
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0201


START_TESTCASE                LBS-Client-NotifyPosUpdate-0016
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0016
//! @SYMTestCaseDesc            Request a single location update by setting required quality profile Id in admin
//! @SYMTestPriority            Critical
//! @SYMTestActions             1. Set KSettingQualityProfileSelfLocate and valid id in admin settings.
//!                             2. open Rpositioner with default positioning module
//!                             3. Request Location Update.
//!                             4. Wait for location request to complete.
//!                             5. verify Position received within the time range
//!                             6. Verify that location info is returned as expected.
//!                             7. Verify that the location request is logged.
//! @SYMTestExpectedResults     Location request will complete with KErrNone and position info will be published
//! @SYMTestType                CIT
//! @SYMCreationDate            28/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_CreateVerifyPosInfos c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0022
RUN_TEST_STEP 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0122
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0016


START_TESTCASE                LBS-Client-NotifyPosUpdate-0021
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0021
//! @SYMTestCaseDesc            When getting a cached position back after doing a second NPUD, it should return a reference position if the reference position was the last position obtained. Added as a result of DEF113370 (reference positions now added to a new bus)
//! @SYMTestPriority            Critical
//! @SYMTestActions             1. Set preferred TB mode
//!                             2. Setup netsim
//!                             3. Send the first NPUD
//!                             4. Change the MaxUpdateAge via UpdateOptions
//!                             5. Send the second NPUD
//!                             6. Verify we get a reference position back
//! @SYMTestExpectedResults     Second Loc request will complete with a KErrNone, passing back a reference position taken from the referencecache
//! @SYMTestType                CIT
//! @SYMCreationDate            28/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_ResetDefaultAdmin 
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_StartLbs
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
//  The following line is for the standard module
RUN_TEST_STEP 1002 LbsClientTestServer LbsStep_CreateVerifyPosInfos c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-1003
RUN_TEST_STEP 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-1003
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0021


PRINT Stop LBS
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_StopLbs


// Now execute a selection of the above tests with AGPS module requesting assistance data
// which will result in a initial reference network position being returned.

// Selecting the default admin values will ensure the AGPS module requests assistance data.
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_ResetDefaultAdmin
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_StartLbs

// NOTE: Moving this test to the end as it's failure currently impacts all subsequent tests and disguises true results:
PRINT Stop LBS
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_StopLbs
RUN_UTILS DeleteFile c:\private\10282253\lbs\lbsprofile.ini
RUN_UTILS CopyFile c:\testdata\configs\lbstestprofile.ini c:\private\10282253\lbs\lbsprofile.ini
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_StartLbs

START_TESTCASE                LBS-Client-NotifyPosUpdate-0020
//! @SYMTestCaseID              LBS-Client-NotifyPosUpdate-0020
//! @SYMTestCaseDesc            Request a single location update (default options) from GPS This case also tests the logging API by verifying the relevant logs are written, can be read and as are expected, an external log, an assistance data log and a self locate log.
//! @SYMTestPriority            Critical
//! @SYMTestActions             See test case "LBS-NotifyPosUpdate-0001" for details.
//! @SYMTestExpectedResults     See test case "LBS-NotifyPosUpdate-0001" for details.
//! @SYMTestType                CIT
//! @SYMCreationDate            28/8/2008
//! @SYMAuthor                  alans
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_InstallScheduler
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_SetUpPsy c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_ClearLog
RUN_TEST_STEP 020 LbsClientTestServer LbsStep_CreateVerifyPosInfos c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0101
RUN_TEST_STEP 120 LbsClientTestServer LbsClientStep_NotifyPosUpdate c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0101
RUN_TEST_STEP 010 LbsClientTestServer LbsStep_VerifyPosInfos
//DELAY 1000
//RUN_TEST_STEP 010 LbsClientTestServer LbsStep_VerifyLogInfo c:\testdata\configs\lbsclientnotifyposupdate.ini LBS-NotifyPosUpdate-0101
END_TESTCASE                  LBS-Client-NotifyPosUpdate-0020


// Re-select the real A-GPS integration module.
RUN_UTILS DeleteFile c:\private\10282253\lbs\locmods\agpsintegmodule.ini

// Delete network registration status text file
RUN_UTILS DeleteFile c:\config.txt