videofeeds/server/tsrc/VCXVodContentApiTest/conf/VCXVodContentApiTest.cfg
author Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
Tue, 26 Jan 2010 12:00:59 +0200
changeset 1 6711b85517b7
parent 0 96612d01cf9f
permissions -rw-r--r--
Revision: 201001 Kit: 201004

#***********************************************************************************
#
# STIF test script file for testing VOD content client API.
#
#***********************************************************************************

[StifSettings]
CapsModifier= IptvTestClientApiCapsMod.exe
[EndStifSettings]

[Define]
INCLUDE c:\testframework\VCXConsts.inc
INCLUDE c:\testframework\VCXErrors.inc
INCLUDE c:\testframework\VCXVodContentApiTest.inc
INCLUDE c:\testframework\VCXServiceNames.inc
INCLUDE c:\testframework\VCXServiceUpdating.inc
[Enddefine]

#------------------------------------------------------------------------------------
#
# Setup services in service database and delete the EPG db.
#
#------------------------------------------------------------------------------------
[Test]
title ET11099 <not a test> Setup vod test services

create VCXTestUtilModule Util
// Copies some known 3G AP to "Internet" destination with "Internet" name for the AP.
Util CopyMethod "Internet" "Internet" "Internet"
Util SetMethodPriority "Internet" 3G_AP 0
Util SetUsedDestination "Internet"
// Disable connection dialog for "Internet" destination.
Util SetConnectionMethodIntAttribute "Internet" "Internet" 507 2 // 507 is ECmSeamlessnessLevel
Util SetDefaultIapCenrep
delete Util

pause PAUSE
create VCXServiceManagementApiTest ServUtil
ServUtil Create
ServUtil DeleteAllServices SYNC

ServUtil AddHardCodedService 	SYNC SERVICE_0 	3G_AP 1 0  	// OOPS
ServUtil AddHardCodedService 	SYNC SERVICE_1 	3G_AP 1 1 		// NokiaVideos
ServUtil AddHardCodedService 	SYNC SERVICE_10 	3G_AP 1 2 		// NSeries
ServUtil AddHardCodedService 	SYNC SERVICE_2	 	3G_AP 1 3 		// Rocketboom
ServUtil AddHardCodedService 	SYNC SERVICE_3	 	3G_AP 1 4 		// YLE Mediasali
ServUtil AddHardCodedService 	SYNC SERVICE_4	 	3G_AP 1 5 		// Kärppäkanava
ServUtil AddHardCodedService 	SYNC SERVICE_5	 	3G_AP 1 6 		// Rocketboom5
ServUtil AddHardCodedService 	SYNC SERVICE_6	 	3G_AP 1 7 		// OOPS6
ServUtil AddHardCodedService 	SYNC SERVICE_7	 	3G_AP 1 8 		// NokiaVideos7
ServUtil AddHardCodedService 	SYNC SERVICE_8	 	3G_AP 1 9 		// Rocketboom8

ServUtil UpdateServiceField SYNC SERVICE_0 ESetIapList WLAN_AP 1 3G_AP 1
ServUtil UpdateServiceField SYNC SERVICE_1 ESetIapList WLAN_AP 1 3G_AP 1
ServUtil UpdateServiceField SYNC SERVICE_2 ESetIapList WLAN_AP 1 3G_AP 1
ServUtil UpdateServiceField SYNC SERVICE_3 ESetIapList WLAN_AP 1 3G_AP 1
ServUtil UpdateServiceField SYNC SERVICE_4 ESetIapList WLAN_AP 1 3G_AP 1
ServUtil UpdateServiceField SYNC SERVICE_5 ESetIapList WLAN_AP 1 3G_AP 1
ServUtil UpdateServiceField SYNC SERVICE_6 ESetIapList WLAN_AP 1 3G_AP 1
ServUtil UpdateServiceField SYNC SERVICE_7 ESetIapList WLAN_AP 1 3G_AP 1
ServUtil UpdateServiceField SYNC SERVICE_8 ESetIapList WLAN_AP 1 3G_AP 1
ServUtil UpdateServiceField SYNC SERVICE_10 ESetIapList WLAN_AP 1 3G_AP 1

// EXTRA_SERVICE_9 is reserved for cases to change it's address at will

ServUtil AddHardCodedService 	SYNC SERVICE_9	 	3G_AP 1 10 	// OOPS9
ServUtil UpdateServiceField		SYNC SERVICE_9 	EAddress 	"http:\/\/193.65.182.78/multiurl.xml"
ServUtil UpdateServiceField		SYNC SERVICE_9 	EName 	EXTRA_SERVICE_1

ServUtil AddHardCodedService 	SYNC SERVICE_9	 	3G_AP 1 10 	// OOPS9
ServUtil UpdateServiceField		SYNC SERVICE_9 	EAddress 	"http:\/\/193.65.182.78/mimetype_tests/allmimetypes.xml"
ServUtil UpdateServiceField		SYNC SERVICE_9 	EName 	EXTRA_SERVICE_2

ServUtil AddHardCodedService 	SYNC SERVICE_9	 	3G_AP 1 10
ServUtil UpdateServiceField		SYNC SERVICE_9 	EAddress 	"http:\/\/193.65.182.78/preview.xml"
ServUtil UpdateServiceField		SYNC SERVICE_9 	EName 	EXTRA_SERVICE_3

ServUtil AddHardCodedService 	SYNC SERVICE_9	 	3G_AP 1 10
ServUtil UpdateServiceField		SYNC SERVICE_9 	EAddress 	"http:\/\/193.65.182.78/ecg_parental_control.xml"
ServUtil UpdateServiceField		SYNC SERVICE_9 	EName 	EXTRA_SERVICE_4

ServUtil AddHardCodedService 	SYNC SERVICE_9	 	3G_AP 1 10
ServUtil UpdateServiceField		SYNC SERVICE_9 	EAddress 	"http:\/\/193.65.182.78/dvbtest/xmltv/xmltv_1day.xml"
ServUtil UpdateServiceField		SYNC SERVICE_9 	EName 	EXTRA_SERVICE_5

ServUtil GetServices SYNC 0 250

ServUtil Destroy
delete ServUtil
pause 30000
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that updating ecg works
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11000 UpdateEcg SERVICE_0
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test EnableThumbnails
test DeleteEpgDb
test Create SERVICE_0
test SelectIap DEFAULT_AP
test UpdateEcg
waittestclass test
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from RSS XML file and ecg db
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11001 GetEcgList SERVICE_0
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_0
test EnableVerifying ET11001
test SelectIap DEFAULT_AP
test GetEcgList 1 "" 0 10
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from RSS XML file and ecg db
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11002 EcgCategoryList SERVICE_0
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_0
test EnableVerifying ET11002
test SelectIap DEFAULT_AP
test EcgCategoryList 0
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from RSS XML file and ecg db
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11003 EcgEcgAllList SERVICE_0
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_0
test EnableVerifying ET11003
test SelectIap DEFAULT_AP
test EcgEcgAllList "" 0 5
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from RSS XML file and ecg db
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11004 CategoryDetails SERVICE_0
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_0
test EnableVerifying ET11004
test SelectIap DEFAULT_AP
test CategoryDetails 1
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient returns parentCategoryId correctly
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11005 ParentCategory SERVICE_0
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_0
test SelectIap DEFAULT_AP
test ParentCategory 0
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from RSS XML file and ecg db
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11006 ContentDetailsList SERVICE_0
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_0
test EnableVerifying ET11006
test SelectIap DEFAULT_AP
test ContentDetailsList 0
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Test CIptvVodContentClient::SetLastPositionL
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11047 SetLastPosition SERVICE_0
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_0
test SetLastPosition 0 0 0
test SetLastPosition 0 0 500
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that updating ECG again works
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11029 UpdateEcg again SERVICE_0
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_0
test SelectIap DEFAULT_AP
test UpdateEcg
waittestclass test
test EnableVerifying ET11029
test VerifyAllCategoryContent 0
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that updating ecg works
#
#------------------------------------------------------------------------------------
[Test]
title ET11007 UpdateEcg SERVICE_1
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_1
test SelectIap DEFAULT_AP
test UpdateEcg
waittestclass test
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from RSS XML file and ecg db
#
#------------------------------------------------------------------------------------
[Test]
title ET11008 GetEcgList SERVICE_1
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_1
test EnableVerifying ET11008
test SelectIap DEFAULT_AP
test GetEcgList 1 "" 0 10
test Verify ET11008
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from RSS XML file and ecg db
#
#------------------------------------------------------------------------------------
[Test]
title ET11009 EcgCategoryList SERVICE_1
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_1
test EnableVerifying ET11009
test SelectIap DEFAULT_AP
test EcgCategoryList 0
test Verify ET11009
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from RSS XML file and ecg db
#
#------------------------------------------------------------------------------------
[Test]
title ET11010 EcgEcgAllList SERVICE_1
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_1
test EnableVerifying ET11010
test SelectIap DEFAULT_AP
test EcgEcgAllList "" 0 5
test Verify ET11010
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from RSS XML file and ecg db
#
#------------------------------------------------------------------------------------
[Test]
title ET11011 CategoryDetails SERVICE_1
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_1
test EnableVerifying ET11011
test SelectIap DEFAULT_AP
test CategoryDetails 1
test Verify ET11011
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient returns parentCategoryId correctly
#
#------------------------------------------------------------------------------------
[Test]
title ET11012 ParentCategory SERVICE_1
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_1
test SelectIap DEFAULT_AP
test ParentCategory 0
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from RSS XML file and ecg db
#
#------------------------------------------------------------------------------------
[Test]
title ET11013 ContentDetailsList SERVICE_1
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_1
test EnableVerifying ET11013
test SelectIap DEFAULT_AP
test ContentDetailsList 0
test Verify ET11013
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that updating ECG again works
#
#------------------------------------------------------------------------------------
[Test]
title ET11030 UpdateEcg again SERVICE_1
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_1
test SelectIap DEFAULT_AP
test UpdateEcg
waittestclass test
test VerifyAllCategoryContent 0
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that updating ecg works
#
#------------------------------------------------------------------------------------
[Test]
title ET11014 UpdateEcg SERVICE_10 for complex RSS XML file with multiple categories
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_10
test SelectIap DEFAULT_AP
test UpdateEcg
waittestclass test
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from complex RSS XML file with multiple categories and ecg db.
#
#------------------------------------------------------------------------------------
[Test]
title ET11015 GetEcgList SERVICE_10
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_10
test SelectIap DEFAULT_AP
test GetEcgList 1 "" 0 10
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from complex RSS XML file with multiple categories and ecg db.
#
#------------------------------------------------------------------------------------
[Test]
title ET11016 AllContent SERVICE_10
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_10
test EnableVerifying ET11016
test SelectIap DEFAULT_AP
test VerifyAllCategoryContent 0
test Verify ET11016
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient request GetEcgList returns correct content when using search parameter
#
#------------------------------------------------------------------------------------
[Test]
title ET11017 GetEcgList search 1 SERVICE_10
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_10
test SelectIap DEFAULT_AP
test EnableVerifying ET11017
test GetEcgList 1 "Amazing Spaces - Adam" 0 10
test GetEcgList 3 "Nokia B" 0 10
test GetEcgList 5 "Wedding" 0 10
test Verify ET11017
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from complex RSS XML file with multiple categories and ecg db.
#
#------------------------------------------------------------------------------------
[Test]
title ET11018 EcgCategoryList SERVICE_10
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_10
test EnableVerifying ET11018
test SelectIap DEFAULT_AP
test EcgCategoryList 0
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from complex RSS XML file with multiple categories and ecg db.
#
#------------------------------------------------------------------------------------
[Test]
title ET11019 EcgEcgAllList SERVICE_10
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_10
test EnableVerifying ET11019
test SelectIap DEFAULT_AP
test EcgEcgAllList "" 0 50
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient request GetEcgAllList returns correct content when using search parameter
#
#------------------------------------------------------------------------------------
[Test]
title ET11023 EcgEcgAllList search SERVICE_10
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_10
test SelectIap DEFAULT_AP
test EcgEcgAllList "Amazing Spaces - Adam" 0 10
test EcgEcgAllList "Nokia B" 0 10
test EcgEcgAllList "Wedding" 0 10
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from complex RSS XML file with multiple categories and ecg db.
#
#------------------------------------------------------------------------------------
[Test]
title ET11020 CategoryDetails SERVICE_10
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_10
test SelectIap DEFAULT_AP
test CategoryDetails 1
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient returns parentCategoryId correctly
#
#------------------------------------------------------------------------------------
[Test]
title ET11021 ParentCategory SERVICE_10
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_10
test SelectIap DEFAULT_AP
test ParentCategory 0
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from complex RSS XML file with multiple categories and ecg db.
#
#------------------------------------------------------------------------------------
[Test]
title ET11022 ContentDetailsList SERVICE_10
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_10
test SelectIap DEFAULT_AP
test ContentDetailsList 0
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from RSS XML file and ecg db
#
#------------------------------------------------------------------------------------
[Test]
title ET11025 EcgEcgAllList video range 1 SERVICE_10
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_10
test SelectIap DEFAULT_AP
test EcgEcgAllList "" 5 2
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from RSS XML file and ecg db
#
#------------------------------------------------------------------------------------
[Test]
title ET11026 EcgEcgAllList video range 2 SERVICE_10
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_10
test SelectIap DEFAULT_AP
test EcgEcgAllList "" 15 3
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that CIptvVodContentClient parses data correctly from RSS XML file and ecg db
#
#------------------------------------------------------------------------------------
[Test]
title ET11027 EcgEcgAllList video range 3 SERVICE_10
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_10
test SelectIap DEFAULT_AP
test EcgEcgAllList "" 500 10
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that updating ECG again works
#
#------------------------------------------------------------------------------------
[Test]
title ET11031 UpdateEcg again SERVICE_10
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create SERVICE_10
test SelectIap DEFAULT_AP
test UpdateEcg
waittestclass test
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that updating ecg work
#
#------------------------------------------------------------------------------------
[Test]
title ET11024 UpdateEcg repeat request SERVICE_0
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test DeleteEpgDb
test Create SERVICE_0
test SelectIap DEFAULT_AP
test UpdateEcg
pause 100
test SetSpecialAction EIgnoreUpdateNotStarted
test UpdateEcg
waittestclass test
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that deleting the client while updating ECG works. Deleting causes cancel to the update request.
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11032 Delete client while updating ECG SERVICE_1
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
//------------------------------------------
// Delete while updating ECG
create VCXVodContentApiTest test
test DeleteEpgDb
test Create SERVICE_1
test SelectIap DEFAULT_AP
test UpdateEcg
Util WaitForConnectionActivity 3G_AP
waittestclass Util
pause 1000
test Destroy
delete test
delete Util
//------------------------------------------
// Get ECG details, fails
pause 2000
create VCXVodContentApiTest test
test Create SERVICE_1
test VerifyAllCategoryContent 0
allownextresult KIptvErrorVodNoIap // this will fail as there's no ECG in DB and no IAP selected when the client tries to start update
waittestclass test
test Destroy
delete test
//------------------------------------------
// Update ECG
pause 2000
create VCXVodContentApiTest test
test Create SERVICE_1
test SelectIap DEFAULT_AP
test UpdateEcg
waittestclass test
test Destroy
delete test
//------------------------------------------
// Delete while updating ECG
pause 2000
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
create VCXVodContentApiTest test
test Create SERVICE_1
test SelectIap DEFAULT_AP
test UpdateEcg
Util WaitForConnectionActivity 3G_AP
waittestclass Util
pause 1000
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that getting the last update time for service ECG works
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11033 GetUpdateTime SERVICE_0
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test DeleteEpgDb
test Create SERVICE_0
test GetUpdateTime // database is empty
test SelectIap DEFAULT_AP
test UpdateEcg
waittestclass test
test GetUpdateTime 1
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that updating ECG works when service changes during previous ECG update
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11034 UpdateEcg after service has changed SERVICE_0
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXServiceManagementApiTest SMUtil
SMUtil Create
create VCXVodContentApiTest test
test DeleteEpgDb

SMUtil UpdateServiceField	ASYNC SERVICE_0 	EAddress 	"http:\/\/193.65.182.78/oops.xml"

test Create SERVICE_0
pause 2000
test EnableVerifying ET11034-1
test SelectIap DEFAULT_AP
// ECG is updated with old address
test UpdateEcg
SMUtil UpdateServiceField	ASYNC SERVICE_0 	EAddress 	"http:\/\/193.65.182.78/nseries.xml"
allownextresult EIptvDlGeneral
allownextresult KERRNONE
allownextresult KERRGENERAL
waittestclass test
test VerifyAllCategoryContent 0
test Destroy

pause PAUSE

test Create SERVICE_0
test EnableVerifying ET11034-2
test SelectIap DEFAULT_AP
// try again, this time ECG is updated with new address
test UpdateEcg
waittestclass test
test VerifyAllCategoryContent 0
test Verify ET11034-2
test Destroy

delete test
SMUtil Destroy
delete SMUtil
Util CheckMobilecrashes
delete Util
[Endtest]


#------------------------------------------------------------------------------------
#
# Test updating ECG with up to 2000 characters long URLs.
#
#------------------------------------------------------------------------------------
[Test]
title ET11038 UpdateEcg service with very long video URLs
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE

create VCXServiceManagementApiTest SMUtil
SMUtil Create
SMUtil AddHardCodedService 	ASYNC SERVICE_9	 	3G_AP 1 10 	// OOPS9
SMUtil UpdateServiceField	ASYNC SERVICE_9 	EAddress 	"http:\/\/193.65.182.78/2kurls.xml"

create VCXVodContentApiTest test
test Create SERVICE_9
test SelectIap DEFAULT_AP
test UpdateEcg
waittestclass test
test Destroy
delete test

SMUtil Destroy
delete SMUtil
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Test updating ECG with 2000 characters long URLs.
#
#------------------------------------------------------------------------------------
#[Test]
#title ET11039 UpdateEcg service with 2k long service URL
#pause PAUSE

#create VCXServiceManagementApiTest SMUtil
#SMUtil Create
#SMUtil AddHardCodedService 	ASYNC SERVICE_9	 	3G_AP 1 10 	// OOPS9
#SMUtil UpdateServiceField	ASYNC SERVICE_9 	EAddress 	EAddress_2kLongUrl

#create VCXVodContentApiTest test
#test Create SERVICE_9
#test SelectIap DEFAULT_AP
#allownextresult -4 // too long url, 256 is maximum
#test UpdateEcg
#test Destroy
#delete test

#SMUtil Destroy
#delete SMUtil
#[Endtest]

#------------------------------------------------------------------------------------
#
# Test updating ECG with 2000 characters long URLs and 256 chars long service xml file name
#
#------------------------------------------------------------------------------------
#[Test]
#title ET11040 UpdateEcg service with 256 chars long service xml filename
#pause PAUSE

#create VCXServiceManagementApiTest SMUtil
#SMUtil Create
#SMUtil AddHardCodedService 	ASYNC SERVICE_9	 	3G_AP 1 10 	// OOPS9
#SMUtil UpdateServiceField	ASYNC SERVICE_9 	EAddress 	EAddress_256LongFileName
#
#create VCXVodContentApiTest test
#test Create SERVICE_9
#test SelectIap DEFAULT_AP
#test UpdateEcg
#waittestclass test
#test EnableVerifying ET11040
#test VerifyAllCategoryContent 0
#test Verify ET11040
#test Destroy
#delete test

#SMUtil Destroy
#delete SMUtil
#[Endtest]

#------------------------------------------------------------------------------------
#
# Test updating ECG for service with videos which have different full and preview contents
#
#------------------------------------------------------------------------------------
[Test]
title ET11042 Videos with different full and preview contents
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create EXTRA_SERVICE_3
test SelectIap DEFAULT_AP
test UpdateEcg
waittestclass test
test EnableVerifying ET11042
test VerifyAllCategoryContent 0
test Verify ET11042
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Test parental control
#
#------------------------------------------------------------------------------------
[Test]
title ET11043 UpdateEcg, service with media rating
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test SetParentalControlAge 0
test Create EXTRA_SERVICE_4
test SelectIap DEFAULT_AP
test UpdateEcg
waittestclass test
test EnableVerifying ET11043
test VerifyAllCategoryContent 0
test Verify ET11043
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Test updating ECG with XML which is in wrong format.
#
#------------------------------------------------------------------------------------
[Test]
title ET11044 UpdateEcg with wrong XML
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test Create EXTRA_SERVICE_5
test SelectIap DEFAULT_AP
test UpdateEcg
allownextresult KIptvRssParserError
waittestclass test
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that updating ecg works
#
#------------------------------------------------------------------------------------
[Test]
title ET11046 UpdateEcg SERVICE_0 WLAN
create VCXTestUtilModule Util
Util SetMethodPriority DEFAULT_DEST WLAN_AP 0
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
print create test
test EnableThumbnails
print enablethumbnails
test DeleteEpgDb
print deleteepgdb
test Create SERVICE_0
print create service
test SelectIap WLAN_AP
print selectiap
test UpdateEcg
print updateecg
waittestclass test
print waittestclass
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Check that updating ecg works
#
#------------------------------------------------------------------------------------
[Test]
title ET11060 UpdateEcg SERVICE_0 default IAP
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test EnableThumbnails
test DeleteEpgDb
test Create SERVICE_0
test SelectIap DEFAULT_AP
test UpdateEcg
waittestclass test
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Setup services in service database and delete the EPG db.
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title <not a test> Setup services
create VCXTestUtilModule Util
// Copies some known 3G AP to "Internet" destination with "Internet" name for the AP.
Util CopyMethod "Internet" "Internet" "Internet"
Util SetMethodPriority "Internet" 3G_AP 0
Util SetUsedDestination "Internet"
// Disable connection dialog for "Internet" destination.
Util SetConnectionMethodIntAttribute "Internet" "Internet" 507 2 // 507 is ECmSeamlessnessLevel
Util SetDefaultIapCenrep
delete Util

pause PAUSE
create VCXServiceManagementApiTest SMUtil
SMUtil Create
SMUtil DeleteAllServices SYNC

SMUtil AddHardCodedService 	    ASYNC SERVICE_1	 	3G_AP 1 10
SMUtil UpdateServiceField		ASYNC SERVICE_1 	EAddress 	"http:\/\/193.65.182.78/nokia_vod.xml"
SMUtil UpdateServiceField		ASYNC SERVICE_1 	ESearchUrl	"http:\/\/193.65.182.78/search.php?file=nokia_vod.xml&q=#search#"
SMUtil UpdateServiceField		ASYNC SERVICE_1 	EName 		EXTRA_SERVICE_1

SMUtil AddHardCodedService 	ASYNC SERVICE_0 	3G_AP 1 0  	// OOPS
SMUtil AddHardCodedService 	ASYNC SERVICE_1 	3G_AP 1 1   // NokiaVideos
SMUtil Destroy
delete SMUtil
pause 3000
[Endtest]

#------------------------------------------------------------------------------------
#
# Test CIptvVodContentClient::UpdateAvailableL
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11048 Automatic ECG update
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test EnableThumbnails
test DeleteEpgDb
test Create SERVICE_0
test SelectIap DEFAULT_AP

// This launches automatic update.
test GetEcgList 1 "" 0 10

Util WaitForConnectionActivity 3G_AP
waittestclass Util

waittestclass test
test GetEcgList 1 "" 0 10
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Test CIptvVodContentClient::UpdateAvailableL
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11049 No update done before - Is update needed
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test EnableThumbnails
test DeleteEpgDb
test Create SERVICE_1
test UpdateAvailable 1
test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Test CIptvVodContentClient::UpdateAvailableL
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11050 Last update less than hour ago - Is update needed
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test EnableThumbnails
test DeleteEpgDb
test Create SERVICE_1
test SelectIap DEFAULT_AP

// Right after update
test UpdateEcg
waittestclass test
test UpdateAvailable 0

// 59 minutes after update
Util AdvanceSystemTimeMinutes 59
test UpdateAvailable 0

test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Test CIptvVodContentClient::UpdateAvailableL
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11051 Last update over hour ago - Is update needed
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test EnableThumbnails
test DeleteEpgDb
test Create SERVICE_1
test SelectIap DEFAULT_AP

test UpdateEcg
waittestclass test

// Over hour ago
Util AdvanceSystemTimeMinutes 60
pause 1000
test UpdateAvailable 1

test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Test CIptvVodContentClient::UpdateAvailableL
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11052 Last update failed - Is update needed
create VCXTestUtilModule Util
Util SetMethodPriority DEFAULT_DEST 3G_AP 0
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test EnableThumbnails
test DeleteEpgDb
test Create SERVICE_1
test SelectIap DEFAULT_AP

// Update succeeds
test UpdateEcg
waittestclass test

pause 2000

// Failed update
test UpdateEcg

loop 3
Util WaitForConnectionActivity 3G_AP
allowerrorcodes KERRTIMEDOUT
waittestclass Util
allowerrorcodes KERRNOTFOUND
allowerrorcodes KERRALREADYEXISTS
Util Attach 3G_AP
allowerrorcodes KERRNOTREADY
Util Terminate
endloop

allownextresult EIptvDlContentNotFound
allownextresult EIptvDlConnectionFailed
allownextresult KIptvErrorEpgUpdateFailed
waittestclass test

test UpdateAvailable 0

test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Test CIptvVodContentClient::CancelUpdate
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11053 Cancel update - Update available
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test EnableThumbnails
test DeleteEpgDb
test Create SERVICE_1

test SelectIap DEFAULT_AP

test SetMsgWhichToSignal KIptvVodUpdateStarted
test UpdateEcg
allownextresult KIptvVodUpdateStarted
waittestclass test
test CancelUpdate

Util WaitUntilConnectionIsClosed 3G_AP
waittestclass Util

test EnableVerifying ET11053
test VerifyAllCategoryContent 0
test VerifyAllCategoryContent KIptvTestSearchCategoryId
test UpdateAvailable 1
test Verify ET11053

test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Test CIptvVodContentClient::CancelUpdate
#
# CaseClass: core
#------------------------------------------------------------------------------------
[Test]
title ET11054 Cancel when no update
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test EnableThumbnails
test DeleteEpgDb
test Create SERVICE_1

test CancelUpdate

test UpdateAvailable 1

test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Test CIptvVodContentClient::CancelUpdate
#
#------------------------------------------------------------------------------------
[Test]
title ET11055 Cancel update and update again - Update available
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher
pause PAUSE
create VCXVodContentApiTest test
test EnableThumbnails
test DeleteEpgDb
test Create SERVICE_1

test SelectIap DEFAULT_AP

test SetMsgWhichToSignal KIptvVodUpdateStarted
test UpdateEcg
allownextresult KIptvVodUpdateStarted
waittestclass test
test CancelUpdate

Util WaitUntilConnectionIsClosed 3G_AP
waittestclass Util
pause 1000

test UpdateEcg
waittestclass test

test UpdateAvailable 0

test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Test CIptvVodContentClient::CancelUpdate
#
#------------------------------------------------------------------------------------
[Test]
title ET11059 Cancel update and do search, update again
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher

create VCXServiceManagementApiTest SMUtil
SMUtil Create
SMUtil DeleteAllServices SYNC
SMUtil AddHardCodedService 	    ASYNC SERVICE_1	 	3G_AP 1 10
SMUtil UpdateServiceField		ASYNC SERVICE_1 	EAddress 	"http:\/\/193.65.182.78/nokia_vod.xml"
SMUtil UpdateServiceField		ASYNC SERVICE_1 	ESearchUrl	"http:\/\/193.65.182.78/search.php?file=nokia_vod.xml&q=#search#"
SMUtil UpdateServiceField		ASYNC SERVICE_1 	EName 		EXTRA_SERVICE_1
SMUtil Destroy
delete SMUtil

pause PAUSE
create VCXVodContentApiTest test
test EnableThumbnails
test DeleteEpgDb
test Create EXTRA_SERVICE_1

test SelectIap DEFAULT_AP

// Cancel update
test SetMsgWhichToSignal KIptvVodUpdateStarted
test UpdateEcg
allownextresult KIptvVodUpdateStarted
waittestclass test
test CancelUpdate
Util WaitUntilConnectionIsClosed 3G_AP
waittestclass Util

pause 2000

// Do search
test Search Bar
waittestclass test

pause 2000

// Update again
test UpdateEcg
waittestclass test

test EnableVerifying ET11059
test VerifyAllCategoryContent 0
test VerifyAllCategoryContent KIptvTestSearchCategoryId
test Verify ET11059

test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Test CIptvVodContentClient::CancelUpdate
#
#------------------------------------------------------------------------------------
[Test]
title ET11056 Cancel search and update, update again
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher

create VCXServiceManagementApiTest SMUtil
SMUtil Create
SMUtil DeleteAllServices SYNC
SMUtil AddHardCodedService 	    ASYNC SERVICE_1	 	3G_AP 1 10
SMUtil UpdateServiceField		ASYNC SERVICE_1 	EAddress 	"http:\/\/193.65.182.78/nokia_vod.xml"
SMUtil UpdateServiceField		ASYNC SERVICE_1 	ESearchUrl	"http:\/\/193.65.182.78/search.php?file=nokia_vod.xml&q=#search#"
SMUtil UpdateServiceField		ASYNC SERVICE_1 	EName 		EXTRA_SERVICE_1
SMUtil Destroy
delete SMUtil

pause PAUSE
create VCXVodContentApiTest test
test EnableThumbnails
test DeleteEpgDb
test Create EXTRA_SERVICE_1

test SelectIap DEFAULT_AP

// Cancel search
test Search Nokia
pause 500
test CancelSearch
Util WaitUntilConnectionIsClosed 3G_AP
waittestclass Util
pause 2000

// Cancel update
test SetMsgWhichToSignal KIptvVodUpdateStarted
test UpdateEcg
allownextresult KIptvVodUpdateStarted
waittestclass test
test CancelUpdate
Util WaitUntilConnectionIsClosed 3G_AP
waittestclass Util
pause 2000

// Update again
test UpdateEcg
waittestclass test

test EnableVerifying ET11056
test VerifyAllCategoryContent 0
test VerifyAllCategoryContent KIptvTestSearchCategoryId
test Verify ET11056

test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Test CIptvVodContentClient::CancelUpdate
#
#------------------------------------------------------------------------------------
[Test]
title ET11057 Cancel update when search is ongoing
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher

create VCXServiceManagementApiTest SMUtil
SMUtil Create
SMUtil DeleteAllServices SYNC
SMUtil AddHardCodedService 	    ASYNC SERVICE_1	 	3G_AP 1 10
SMUtil UpdateServiceField		ASYNC SERVICE_1 	EAddress 	"http:\/\/193.65.182.78/nokia_vod.xml"
SMUtil UpdateServiceField		ASYNC SERVICE_1 	ESearchUrl	"http:\/\/193.65.182.78/search.php?file=nokia_vod.xml&q=#search#"
SMUtil UpdateServiceField		ASYNC SERVICE_1 	EName 		EXTRA_SERVICE_1
SMUtil Destroy
delete SMUtil

pause PAUSE
create VCXVodContentApiTest test
test EnableThumbnails
test DeleteEpgDb
test Create EXTRA_SERVICE_1

test SelectIap DEFAULT_AP

// Cancel search
test Search Nokia
test CancelUpdate
waittestclass test

test EnableVerifying ET11057
test VerifyAllCategoryContent 0
test VerifyAllCategoryContent KIptvTestSearchCategoryId
test Verify ET11057

test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]

#------------------------------------------------------------------------------------
#
# Test CIptvVodContentClient::CancelUpdate
#
#------------------------------------------------------------------------------------
[Test]
title ET11058 Cancel update when 3rd party connected
create VCXTestUtilModule Util
Util CreateMobilecrashWatcher

create VCXServiceManagementApiTest SMUtil
SMUtil Create
SMUtil DeleteAllServices SYNC
SMUtil AddHardCodedService 	    ASYNC SERVICE_1	 	3G_AP 1 10
SMUtil UpdateServiceField		ASYNC SERVICE_1 	EAddress 	"http:\/\/193.65.182.78/nokia_vod.xml"
SMUtil UpdateServiceField		ASYNC SERVICE_1 	ESearchUrl	"http:\/\/193.65.182.78/search.php?file=nokia_vod.xml&q=#search#"
SMUtil UpdateServiceField		ASYNC SERVICE_1 	EName 		EXTRA_SERVICE_1
SMUtil Destroy
delete SMUtil

pause PAUSE
create VCXVodContentApiTest test
test EnableThumbnails
test DeleteEpgDb
test Create EXTRA_SERVICE_1

Util Connect 3G_AP
waittestclass Util

test SelectIap DEFAULT_AP

test SetMsgWhichToSignal KIptvVodUpdateStarted
test UpdateEcg
allownextresult KIptvVodUpdateStarted
waittestclass test
test CancelUpdate

pause 10000

Util WaitForConnectionActivity 3G_AP
waittestclass Util

test Destroy
delete test
Util CheckMobilecrashes
delete Util
[Endtest]