Skip to content

Instantly share code, notes, and snippets.

@divamtbf
Created February 15, 2017 22:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save divamtbf/33242c33787f5cdbeaf51e3bb90062fc to your computer and use it in GitHub Desktop.
Save divamtbf/33242c33787f5cdbeaf51e3bb90062fc to your computer and use it in GitHub Desktop.
DIVA_MTBF_SPR_RubyRunGenerated
loadTestDB
module DIVA_MTBF_SPR
def self.Browser_05_01_04_01(loopTime)
tcase = TestCase.new("Browser_05_01_04_01")
tcase << TestAction.new(:scriptAction_2) do
logStartTest("Browser_05_01_04_01")
end
tcase << TestAction.new(:gotoApp_2) do
gotoApp('Chrome')
end
tcase << TestAction.new(:Button_TermsAccept_2) do
$ruiObj = RUIObject.new.with('objectid', -731197748).with('selfid', 659232449).with('textdescid', 1426387421).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'Button')
.with('resource-id', 'com.android.chrome:id/terms_accept')
.with('text', 'Accept continue')
$ruiObj.click
noFailCheck
end
tcase << TestAction.new(:Button_PositiveButton_4) do
$ruiObj = RUIObject.new.with('objectid', 608181399).with('selfid', 780691289).with('textdescid', -1851914588).with('uniqueparentid', 0)
.with('uitreeindex', 5)
.with('classname', 'Button')
.with('resource-id', 'com.android.chrome:id/positive_button')
.with('text', 'Next')
$ruiObj.click
noFailCheck
end
tcase << TestAction.new(:Button_PositiveButton_6) do
$ruiObj = RUIObject.new.with('objectid', -255474603).with('selfid', 780402664).with('textdescid', -1721638605).with('uniqueparentid', 0)
.with('uitreeindex', 7)
.with('classname', 'Button')
.with('resource-id', 'com.android.chrome:id/positive_button')
.with('text', 'Done')
$ruiObj.click
noFailCheck
end
tcase << TestAction.new(:EditText_UrlBar_24) do
$ruiObj = RUIObject.new.with('objectid', 882195433).with('selfid', 613381324).with('textdescid', 1578254679).with('uniqueparentid', 0)
.with('uitreeindex', 138)
.with('classname', 'EditText')
.with('resource-id', 'com.android.chrome:id/url_bar')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:EditText_UrlBar_2) do
$ruiObj = RUIObject.new.with('objectid', 882195433).with('selfid', 613381324).with('textdescid', 1578254679).with('uniqueparentid', 0)
.with('uitreeindex', 21)
.with('classname', 'EditText')
.with('resource-id', 'com.android.chrome:id/url_bar')
$ruiObj.inputtext('m.att.com')
waitsecond(1)
end
tcase << TestAction.new(:pressEnter_5) do
pressEnter
waitsecond(2)
end
tcase << TestAction.new(:wait4second_2) do
waitsecond(4)
end
tcase << TestAction.new(:scriptAction_1_1) do
$reload = RUIObject.new.with('objectid', -1298956826).with('selfid', 1403544531).with('textdescid', 1877548115).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'Button')
.with('resource-id', 'reload-button')
.with('content-desc', 'RELOAD').exists?
$progressBar = RUIObject.new.with('objectid', 1158061653).with('selfid', 1366906829).with('textdescid', 1540172907).with('uniqueparentid', 0)
.with('uitreeindex', 18)
.with('classname', 'ImageView')
.with('resource-id', 'com.android.chrome:id/progress').exists?
if ($progressBar || $reload) == true
$myTestResult = false
else
$myTestResult = true
end
if $myTestResult == false
$myFailReason = "Page not loaded."
end
logStopTest("Browser_05_01_04_01")
end
tcase << TestAction.new(:pressBack_1) do
pressBack
end
tcase << TestAction.new(:pressHome_1) do
pressHome
end
tcase.run(loopTime)
end
def self.Browser_05_01_04_02(loopTime)
tcase = TestCase.new("Browser_05_01_04_02")
tcase << TestAction.new(:scriptAction_2_1) do
logStartTest("Browser_05_01_04_02")
end
tcase << TestAction.new(:gotoApp_21) do
gotoApp('Chrome')
end
tcase << TestAction.new(:EditText_UrlBar_2) do
$ruiObj = RUIObject.new.with('objectid', 882195433).with('selfid', 613381324).with('textdescid', 1578254679).with('uniqueparentid', 0)
.with('uitreeindex', 40)
.with('classname', 'EditText')
.with('resource-id', 'com.android.chrome:id/url_bar')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:EditText_UrlBar_2_1) do
$ruiObj = RUIObject.new.with('objectid', 882195433).with('selfid', 613381324).with('textdescid', 1578254679).with('uniqueparentid', 0)
.with('uitreeindex', 40)
.with('classname', 'EditText')
.with('resource-id', 'com.android.chrome:id/url_bar')
$ruiObj.inputtext('www.naver.com')
waitsecond(1)
end
tcase << TestAction.new(:pressEnter_6) do
pressEnter
waitsecond(4)
end
tcase << TestAction.new(:clickXY_154_500_3) do
click(154,500)
waitsecond(4)
end
tcase << TestAction.new(:swipeDown_9) do
swipe_vertical 500
end
tcase << TestAction.new(:scriptAction_1_1_1) do
$reload = RUIObject.new.with('objectid', -1298956826).with('selfid', 1403544531).with('textdescid', 1877548115).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'Button')
.with('resource-id', 'reload-button')
.with('content-desc', 'RELOAD').exists?
$progressBar = RUIObject.new.with('objectid', 1158061653).with('selfid', 1366906829).with('textdescid', 1540172907).with('uniqueparentid', 0)
.with('uitreeindex', 18)
.with('classname', 'ImageView')
.with('resource-id', 'com.android.chrome:id/progress').exists?
if ($progressBar || $reload) == true
$myTestResult = false
else
$myTestResult = true
end
if $myTestResult == false
$myFailReason = "Page not loaded."
end
logStopTest("Browser_05_01_04_01")
end
tcase << TestAction.new(:pressBack_10) do
pressBack
end
tcase << TestAction.new(:pressBack_1) do
pressBack
end
tcase << TestAction.new(:pressHome_4) do
pressHome
end
tcase.run(loopTime)
end
def self.Browser_05_01_04_03(loopTime)
tcase = TestCase.new("Browser_05_01_04_03")
tcase << TestAction.new(:scriptAction_2_1_1_1) do
logStartTest("Browser_05_01_04_03")
end
tcase << TestAction.new(:gotoApp_2) do
gotoApp('Chrome')
end
tcase << TestAction.new(:EditText_UrlBar_27) do
$ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'EditText')
.with('resource-id', 'com.android.chrome:id/url_bar')
$ruiObj.click
noFailCheck
waitsecond(1)
end
tcase << TestAction.new(:EditText_UrlBar_27_1) do
$ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'EditText')
.with('resource-id', 'com.android.chrome:id/url_bar')
$ruiObj.inputtext('www.ebay.com')
noFailCheck
waitsecond(1)
end
tcase << TestAction.new(:pressEnter_10) do
pressEnter
waitsecond(4)
end
tcase << TestAction.new(:EditText_UrlBar_27_1) do
$ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'EditText')
.with('resource-id', 'com.android.chrome:id/url_bar')
$ruiObj.click
noFailCheck
waitsecond(1)
end
tcase << TestAction.new(:EditText_UrlBar_4) do
$ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'EditText')
.with('resource-id', 'com.android.chrome:id/url_bar')
$ruiObj.inputtext('www.yahoo.com')
noFailCheck
waitsecond(1)
end
tcase << TestAction.new(:pressEnter_12) do
pressEnter
waitsecond(4)
end
tcase << TestAction.new(:EditText_UrlBar_27_1_1) do
$ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'EditText')
.with('resource-id', 'com.android.chrome:id/url_bar')
$ruiObj.click
noFailCheck
waitsecond(1)
end
tcase << TestAction.new(:EditText_UrlBar_5) do
$ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'EditText')
.with('resource-id', 'com.android.chrome:id/url_bar')
$ruiObj.inputtext('www.amazon.com')
noFailCheck
waitsecond(1)
end
tcase << TestAction.new(:pressEnter_14) do
pressEnter
waitsecond(4)
end
tcase << TestAction.new(:EditText_UrlBar_27_1_1_1) do
$ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'EditText')
.with('resource-id', 'com.android.chrome:id/url_bar')
$ruiObj.click
noFailCheck
waitsecond(1)
end
tcase << TestAction.new(:EditText_UrlBar_3) do
$ruiObj = RUIObject.new.with('objectid', 882195433).with('selfid', 613381324).with('textdescid', 1578254679).with('uniqueparentid', 0)
.with('uitreeindex', 177)
.with('classname', 'EditText')
.with('resource-id', 'com.android.chrome:id/url_bar')
$ruiObj.inputtext('www.youtube.com')
waitsecond(1)
end
tcase << TestAction.new(:pressEnter_16) do
pressEnter
waitsecond(4)
end
tcase << TestAction.new(:EditText_UrlBar_27_1_1_1_1) do
$ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'EditText')
.with('resource-id', 'com.android.chrome:id/url_bar')
$ruiObj.click
noFailCheck
waitsecond(1)
end
tcase << TestAction.new(:EditText_UrlBar_7) do
$ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'EditText')
.with('resource-id', 'com.android.chrome:id/url_bar')
$ruiObj.inputtext('www.nytimes.com')
noFailCheck
waitsecond(1)
end
tcase << TestAction.new(:pressEnter_18) do
pressEnter
waitsecond(4)
end
tcase << TestAction.new(:wait2second_2) do
waitsecond(2)
end
tcase << TestAction.new(:scriptAction_1_1_1_1) do
$reload = RUIObject.new.with('objectid', -1298956826).with('selfid', 1403544531).with('textdescid', 1877548115).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'Button')
.with('resource-id', 'reload-button')
.with('content-desc', 'RELOAD').exists?
$progressBar = RUIObject.new.with('objectid', 1158061653).with('selfid', 1366906829).with('textdescid', 1540172907).with('uniqueparentid', 0)
.with('uitreeindex', 18)
.with('classname', 'ImageView')
.with('resource-id', 'com.android.chrome:id/progress').exists?
if ($progressBar || $reload) == true
$myTestResult = false
else
$myTestResult = true
end
if $myTestResult == false
$myFailReason = "Page not loaded."
end
logStopTest("Browser_05_01_04_01")
end
tcase << TestAction.new(:pressHome_8) do
pressHome
end
tcase.run(loopTime)
end
def self.mainLoop(loopTime)
WebSocketXServer.setAutoUpdate(false)
index = $mainResumeMainLoop
$mainResumeMainLoop = 0
writelog("mainLoop::#{index}::Resume") if index > 0
while index < loopTime
$curMainLoopNum = index
$saveLogToGist = false
$POWERLOG = true
if Build::PRODUCT.include? "spr"
$Messaging = 'Messenger'
else
$Messaging = 'Messaging'
end
waitsecond(2)
if rand(100) < 0
for mode in db('ModemMode')
puts "Change to #{mode}"
if mode == 'LTE'
writelog("Telephony_05_01_01_01_LTE")
change_LTE 1
Telephony_05_01_01_01 60
elsif mode == '3G'
writelog("Telephony_05_01_01_01_3G")
change_3G 1
Telephony_05_01_01_01 20
end
end
end
if rand(100) < 0
for mode in db('ModemMode')
puts "Change to #{mode}"
if mode == 'LTE'
writelog("Telephony_05_01_01_03_LTE")
change_LTE 1
Telephony_05_01_01_03 60
elsif mode == '3G'
writelog("Telephony_05_01_01_03_3G")
change_3G 1
Telephony_05_01_01_03 20
end
end
end
$actionParamInput = "none"
Telephony_05_01_01_01 100
$actionParamInput = "none"
Telephony_05_01_01_03 100
$actionParamInput = "none"
Telephony_05_01_01_05 100
$actionParamInput = "none"
Telephony_05_01_01_07 20
$actionParamInput = "none"
Telephony_05_01_01_06 20
if rand(100) < 0
for mode in db('ModemMode')
puts "Change to #{mode}"
if mode == 'LTE'
writelog("Messaging_05_01_02_03_LTE")
change_LTE 1
Messaging_05_01_02_03 30
elsif mode == '3G'
writelog("Messaging_05_01_02_03_3G")
change_3G 1
Messaging_05_01_02_03 20
end
end
end
if rand(100) < 0
for mode in db('ModemMode')
puts "Change to #{mode}"
if mode == 'LTE'
writelog("Messaging_05_01_02_05_LTE")
change_LTE 1
Messaging_05_01_02_05 30
elsif mode == '3G'
writelog("Messaging_05_01_02_05_3G")
change_3G 1
Messaging_05_01_02_05 20
end
end
end
if rand(100) < 0
$actionParamInput = "none"
Messaging_05_01_02_03 50
end
if rand(100) < 0
$actionParamInput = "none"
Messaging_05_01_02_05 50
end
if rand(100) < 0
$actionParamInput = "none"
Messaging_05_01_02_06 50
end
if rand(100) < 0
for mode in db('ModemMode')
puts "Change to #{mode}"
if mode == 'LTE'
writelog("Gmail_05_01_03_01_LTE")
change_LTE 1
Gmail_05_01_03_01 30
elsif mode == '3G'
writelog("Gmail_05_01_03_01_3G")
change_3G 1
Gmail_05_01_03_01 20
end
end
end
if rand(100) < 0
for mode in db('ModemMode')
puts "Change to #{mode}"
if mode == 'LTE'
writelog("Gmail_05_01_03_02_LTE")
change_LTE 1
Gmail_05_01_03_02 30
elsif mode == '3G'
writelog("Gmail_05_01_03_02_3G")
change_3G 1
Gmail_05_01_03_02 20
end
end
end
$actionParamInput = "none"
Gmail_05_01_03_01 50
$actionParamInput = "none"
Gmail_05_01_03_02 50
$actionParamInput = "none"
Gmail_05_01_03_03 50
if rand(100) < 0
for mode in db('ModemMode')
puts "Change to #{mode}"
if mode == 'LTE'
writelog("Browser_05_01_04_01_LTE")
change_LTE 1
Browser_05_01_04_01 30
elsif mode == '3G'
writelog("Browser_05_01_04_01_3G")
change_3G 1
Browser_05_01_04_01 20
end
end
end
if rand(100) < 0
for mode in db('ModemMode')
puts "Change to #{mode}"
if mode == 'LTE'
writelog("Browser_05_01_04_02_LTE")
change_LTE 1
Browser_05_01_04_02 30
elsif mode == '3G'
writelog("Browser_05_01_04_02_3G")
change_3G 1
Browser_05_01_04_02 20
end
end
end
if rand(100) < 0
for mode in db('ModemMode')
puts "Change to #{mode}"
if mode == 'LTE'
writelog("Browser_05_01_04_03_LTE")
change_LTE 1
Browser_05_01_04_03 6
elsif mode == '3G'
writelog("Browser_05_01_04_03_3G")
change_3G 1
Browser_05_01_04_03 4
end
end
end
$actionParamInput = "none"
Browser_05_01_04_01 50
$actionParamInput = "none"
Browser_05_01_04_02 50
$actionParamInput = "none"
Browser_05_01_04_03 10
$actionParamInput = "none"
StoreFrontDownload_05_01_05_01 20
$actionParamInput = "none"
StoreFrontDownload_05_01_05_02 10
$actionParamInput = "none"
StoreFrontDownload_05_01_05_04 1
$actionParamInput = "none"
StoreFrontDownload_05_01_05_05 10
$actionParamInput = "none"
StoreFrontDownload_05_01_05_06 10
$actionParamInput = "none"
StoreFrontDownload_05_01_05_07 1
if rand(100) < 0
$actionParamInput = "none"
PIM_05_01_06_01 5
end
if rand(100) < 0
$actionParamInput = "none"
PIM_05_01_06_02 1
end
if rand(100) < 0
$actionParamInput = "none"
PIM_05_01_06_03 5
end
if rand(100) < 0
$actionParamInput = "none"
PIM_05_01_06_04 1
end
$actionParamInput = "none"
MultiMedia_05_01_07_01 1
$actionParamInput = "none"
MultiMedia_05_01_07_02 1
$actionParamInput = "none"
MultiMedia_05_01_07_03 1
$actionParamInput = "none"
MultiMedia_05_01_07_04 20
$actionParamInput = "none"
MultiMedia_05_01_07_05 20
$actionParamInput = "none"
MultiMedia_05_01_07_06 20
$actionParamInput = "none"
MultiMedia_05_01_07_10 10
$actionParamInput = "none"
MultiTasking_05_01_08_01 1
$actionParamInput = "none"
MultiTasking_05_01_08_02 50
$actionParamInput = "none"
MultiTasking_05_01_08_03 1
$actionParamInput = "none"
MultiTasking_05_01_08_04 1
$actionParamInput = "none"
MultiTasking_05_01_08_05 50
$actionParamInput = "none"
MultiTasking_05_01_08_06 1
$actionParamInput = "none"
MenuNavigation_05_01_09_01 1
$actionParamInput = "none"
WiFi_05_01_10_01 20
$actionParamInput = "none"
WiFi_05_01_10_02 20
$actionParamInput = "none"
NFC_05_01_11_01 1
$actionParamInput = "none"
VideoCall_01 20
sendStatus("Done::mainLoop::Loop::#{index}")
writelog("Finish::Loop::#{$curMainLoopNum}")
saveLogFileToGist if $saveLogToGist
index += 1
end
$engineStatus = "Idle"
resetStatus
sendStatus("Finish::mainLoop::END")
end
def self.Gmail_05_01_03_01(loopTime)
tcase = TestCase.new("Gmail_05_01_03_01")
tcase << TestAction.new(:pressHome_2) do
pressHome
end
tcase << TestAction.new(:scriptAction_12_1) do
logStartTest("Email_05_01_03_01")
end
tcase << TestAction.new(:gotoApp_3) do
gotoApp('Google')
end
tcase << TestAction.new(:TextView_Gmail_3) do
$ruiObj = RUIObject.new.with('objectid', -665293804).with('selfid', 720372874).with('textdescid', 1410473424).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'TextView')
.with('content-desc', 'Gmail')
.with('text', 'Gmail')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:ImageButton_ComposeButton_2) do
$ruiObj = RUIObject.new.with('objectid', 2010391035).with('selfid', 1808564263).with('textdescid', -481574643).with('uniqueparentid', 0)
.with('uitreeindex', 26)
.with('classname', 'ImageButton')
.with('resource-id', 'com.google.android.gm:id/compose_button')
.with('content-desc', 'Compose')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:MultiAutoCompleteTextView_To_5) do
$ruiObj = RUIObject.new.with('objectid', 1308296701).with('selfid', 678761455).with('textdescid', 1902492099).with('uniqueparentid', 0).with('classresourceid', 1488875515)
.with('uitreeindex', 9)
.with('classname', 'MultiAutoCompleteTextView')
.with('resource-id', 'com.google.android.gm:id/to')
$ruiObj.inputtext('dvgats1@gmail.com')
waitsecond(2)
end
tcase << TestAction.new(:pressEnter_3) do
pressEnter
end
tcase << TestAction.new(:EditText_Subject_6) do
$ruiObj = RUIObject.new.with('objectid', 1144045145).with('selfid', -477614756).with('textdescid', 1105661159).with('uniqueparentid', 0).with('classresourceid', 927865352)
.with('uitreeindex', 12)
.with('classname', 'EditText')
.with('resource-id', 'com.google.android.gm:id/subject')
$ruiObj.inputtext('Email Test')
waitsecond(1)
end
tcase << TestAction.new(:EditText_Body_8) do
$ruiObj = RUIObject.new.with('objectid', -947933892).with('selfid', 132829042).with('textdescid', 678820452).with('uniqueparentid', 0).with('classresourceid', 52429382)
.with('uitreeindex', 14)
.with('classname', 'EditText')
.with('resource-id', 'com.google.android.gm:id/body')
$ruiObj.inputtext('')
end
tcase << TestAction.new(:scriptAction_14) do
$ruiObj.inputtext('Testing UiEngine Email Test!!!')
end
tcase << TestAction.new(:TextView_Send_10) do
$ruiObj = RUIObject.new.with('objectid', 1131985907).with('selfid', 2103341243).with('textdescid', -1405558155).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.gm:id/send')
.with('content-desc', 'Send')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_ComposeButton_12) do
$ruiObj = RUIObject.new.with('objectid', 2010391035).with('selfid', 1808564263).with('textdescid', -481574643).with('uniqueparentid', 0)
.with('uitreeindex', 26)
.with('classname', 'ImageButton')
.with('resource-id', 'com.google.android.gm:id/compose_button')
.with('content-desc', 'Compose')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_Navigate_14) do
$ruiObj = RUIObject.new.with('objectid', -387960062).with('selfid', -123872605).with('textdescid', -1698616212).with('uniqueparentid', 0)
.with('uitreeindex', 0)
.with('classname', 'ImageButton')
.with('content-desc', 'Navigate up')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:clickXY_388_1968_16) do
click(388,1968)
waitsecond(1)
end
tcase << TestAction.new(:clickXY_428_768_19) do
click(428,768)
waitsecond(1)
end
tcase << TestAction.new(:TextView_Delete_4) do
$ruiObj = RUIObject.new.with('objectid', 1211721173).with('selfid', -390800203).with('textdescid', -538482442).with('uniqueparentid', 0)
.with('uitreeindex', 1)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.gm:id/delete')
.with('content-desc', 'Delete')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:scriptAction_8) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "Email not sent"
end
logStopTest("Email_05_01_03_01")
end
tcase << TestAction.new(:pressBack_3) do
pressBack
end
tcase << TestAction.new(:pressBack_4) do
pressBack
end
tcase << TestAction.new(:pressHome_21) do
pressHome
waitsecond(2)
end
tcase.run(loopTime)
end
def self.Gmail_05_01_03_02(loopTime)
tcase = TestCase.new("Gmail_05_01_03_02")
tcase << TestAction.new(:scriptAction_12) do
logStartTest("Email_05_01_03_02")
end
tcase << TestAction.new(:gotoApp_3) do
gotoApp('Google')
end
tcase << TestAction.new(:TextView_Gmail_2) do
$ruiObj = RUIObject.new.with('objectid', -665293804).with('selfid', 720372874).with('textdescid', 1410473424).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'TextView')
.with('content-desc', 'Gmail')
.with('text', 'Gmail')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:ImageButton_ComposeButton_2) do
$ruiObj = RUIObject.new.with('objectid', 2010391035).with('selfid', 1808564263).with('textdescid', -481574643).with('uniqueparentid', 0)
.with('uitreeindex', 24)
.with('classname', 'ImageButton')
.with('resource-id', 'com.google.android.gm:id/compose_button')
.with('content-desc', 'Compose')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:MultiAutoCompleteTextView_To_49) do
$ruiObj = RUIObject.new.with('objectid', 1308296701).with('selfid', 678761455).with('textdescid', 1902492099).with('uniqueparentid', 0).with('classresourceid', 1488875515)
.with('uitreeindex', 9)
.with('classname', 'MultiAutoCompleteTextView')
.with('resource-id', 'com.google.android.gm:id/to')
$ruiObj.inputtext('dvgats1@gmail.com')
waitsecond(2)
end
tcase << TestAction.new(:pressEnter_7) do
pressEnter
waitsecond(1)
end
tcase << TestAction.new(:EditText_Subject_9) do
$ruiObj = RUIObject.new.with('objectid', 1144045145).with('selfid', -477614756).with('textdescid', 1105661159).with('uniqueparentid', 0).with('classresourceid', 927865352)
.with('uitreeindex', 12)
.with('classname', 'EditText')
.with('resource-id', 'com.google.android.gm:id/subject')
$ruiObj.inputtext('Email Test')
waitsecond(1)
end
tcase << TestAction.new(:EditText_Body_11) do
$ruiObj = RUIObject.new.with('objectid', -947933892).with('selfid', 132829042).with('textdescid', 678820452).with('uniqueparentid', 0).with('classresourceid', 52429382)
.with('uitreeindex', 14)
.with('classname', 'EditText')
.with('resource-id', 'com.google.android.gm:id/body')
$ruiObj.inputtext('')
end
tcase << TestAction.new(:scriptAction_14) do
$ruiObj.inputtext('Testing UiEngine Email Test!!!')
end
tcase << TestAction.new(:TextView_AddAttachment_13) do
$ruiObj = RUIObject.new.with('objectid', 915724844).with('selfid', 1566257663).with('textdescid', -1753719389).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.gm:id/add_attachment')
.with('content-desc', 'Attach file')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_4) do
$ruiObj = RUIObject.new.with('objectid', 665784376).with('selfid', -1478650284).with('textdescid', 1395090321).with('uniqueparentid', 0).with('classresourceid', -1261418567)
.with('uitreeindex', 0)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.gm:id/title')
.with('text', 'Attach file')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_Show_2) do
$ruiObj = RUIObject.new.with('objectid', -1807230859).with('selfid', -929198491).with('textdescid', 629574489).with('uniqueparentid', 0)
.with('uitreeindex', 0)
.with('classname', 'ImageButton')
.with('content-desc', 'Show roots')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_21) do
$ruiObj = RUIObject.new.with('objectid', 942770025).with('selfid', -192133575).with('textdescid', 790630097).with('uniqueparentid', 0).with('classresourceid', 490183159)
.with('uitreeindex', 38)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'Images')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_2) do
pressDPadDown
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_2_1) do
pressDPadDown
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_2_1_1) do
pressDPadRight
waitsecond(1)
end
tcase << TestAction.new(:pressEnter_6) do
pressEnter
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_81) do
pressDPadDown
waitsecond(1)
end
tcase << TestAction.new(:pressEnter_6_1) do
pressEnter
waitsecond(1)
end
tcase << TestAction.new(:Button_PermissionAllowButton_11) do
$ruiObj = RUIObject.new.with('objectid', -886457929).with('selfid', 1443382411).with('textdescid', 270556320).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'Button')
.with('resource-id', 'com.android.packageinstaller:id/permission_allow_button')
.with('text', 'ALLOW')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Send_23) do
$ruiObj = RUIObject.new.with('objectid', 1131985907).with('selfid', 2103341243).with('textdescid', -1405558155).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.gm:id/send')
.with('content-desc', 'Send')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_ComposeButton_25) do
$ruiObj = RUIObject.new.with('objectid', 2010391035).with('selfid', 1808564263).with('textdescid', -481574643).with('uniqueparentid', 0)
.with('uitreeindex', 23)
.with('classname', 'ImageButton')
.with('resource-id', 'com.google.android.gm:id/compose_button')
.with('content-desc', 'Compose')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_Navigate_27) do
$ruiObj = RUIObject.new.with('objectid', -387960062).with('selfid', -123872605).with('textdescid', -1698616212).with('uniqueparentid', 0)
.with('uitreeindex', 0)
.with('classname', 'ImageButton')
.with('content-desc', 'Navigate up')
$ruiObj.click
end
tcase << TestAction.new(:TextView_Name_6) do
$ruiObj = RUIObject.new.with('objectid', -630461263).with('selfid', -610816808).with('textdescid', 727067449).with('uniqueparentid', 0).with('classresourceid', 790406410)
.with('uitreeindex', 22)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.gm:id/name')
.with('text', 'Sent')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:clickXY_340_748_38) do
click(340,748)
waitsecond(1)
end
tcase << TestAction.new(:TextView_Delete_36) do
$ruiObj = RUIObject.new.with('objectid', -15615667).with('selfid', -390800203).with('textdescid', -1373012866).with('uniqueparentid', 0)
.with('uitreeindex', 1)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.gm:id/delete')
.with('content-desc', 'Delete')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_8) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "Email not sent"
end
logStopTest("Email_05_01_03_02")
end
tcase << TestAction.new(:pressBack_3) do
pressBack
end
tcase << TestAction.new(:pressBack_4) do
pressBack
end
tcase << TestAction.new(:pressHome_2) do
pressHome
end
tcase.run(loopTime)
end
def self.Gmail_05_01_03_03(loopTime)
tcase = TestCase.new("Gmail_05_01_03_03")
tcase << TestAction.new(:scriptAction_3) do
logStartTest("Email_05_01_03_03")
end
tcase << TestAction.new(:gotoApp_3) do
gotoApp('Google')
end
tcase << TestAction.new(:TextView_Gmail_2) do
$ruiObj = RUIObject.new.with('objectid', -665293804).with('selfid', 720372874).with('textdescid', 1410473424).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'TextView')
.with('content-desc', 'Gmail')
.with('text', 'Gmail')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:ImageButton_Navigate_4) do
$ruiObj = RUIObject.new.with('objectid', -387960062).with('selfid', -123872605).with('textdescid', -1698616212).with('uniqueparentid', 0)
.with('uitreeindex', 0)
.with('classname', 'ImageButton')
.with('content-desc', 'Navigate up')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Name_2) do
$ruiObj = RUIObject.new.with('objectid', -630461263).with('selfid', -610816808).with('textdescid', 727067449).with('uniqueparentid', 0).with('classresourceid', 790406410)
.with('uitreeindex', 26)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.gm:id/name')
.with('text', 'Sent')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:clickXY_204_882_4_1) do
click(204,882)
waitsecond(1)
end
tcase << TestAction.new(:TextView_Delete_10) do
$ruiObj = RUIObject.new.with('objectid', -15615667).with('selfid', -390800203).with('textdescid', -1373012866).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.gm:id/delete')
.with('content-desc', 'Delete')
$ruiObj.isExist
end
tcase << TestAction.new(:scriptAction_8_1_1) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "Email not opened"
end
logStopTest("Email_05_01_03_03")
end
tcase << TestAction.new(:pressBack_1) do
pressBack
end
tcase << TestAction.new(:pressBack_2) do
pressBack
end
tcase << TestAction.new(:pressHome_4) do
pressHome
waitsecond(2)
end
tcase.run(loopTime)
end
def self.MenuNavigation_05_01_09_01(loopTime)
tcase = TestCase.new("MenuNavigation_05_01_09_01")
tcase << TestAction.new(:pressHome_1) do
pressHome
end
tcase << TestAction.new(:scriptAction_off) do
$ignoreDefaultExpHandler = true
waitsecond(2)
end
tcase << TestAction.new(:scriptAction_StartTestLog) do
logStartTest("05_01_09_01_Menu_Navigation")
waitsecond(2)
end
tcase << TestAction.new(:scriptAction_resetCounter) do
$appCounter = 0
waitsecond(2)
end
tcase << TestAction.new(:scriptAction_loop) do
until $appCounter > 31
$appCounter += 1
gotoApp(db('NavApp')[$appCounter-1])
waitsecond(2)
allow_popup
waitsecond(2)
pressHome
$ruiObj = RUIObject.new.with('objectid', -1351376744).with('selfid', -1318451484).with('textdescid', -1794026948).with('uniqueparentid', 0)
.with('uitreeindex', 1)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'OK')
$ruiObj.click
end
waitsecond(2)
end
tcase << TestAction.new(:scriptAction_StopLogTest) do
if $appCounter == 26
$myTestResult = true
else
$myTestRsult = false
$myFailReason = "Failed"
end
logStopTest("05_01_09_01_Menu_Navigation")
waitsecond(2)
end
tcase.run(loopTime)
end
def self.Messaging_05_01_02_03(loopTime)
tcase = TestCase.new("Messaging_05_01_02_03")
tcase << TestAction.new(:scriptAction_28) do
logStartTest("Messaging_05_01_02_03")
end
tcase << TestAction.new(:gotoApp_2) do
gotoApp('Messenger')
waitsecond(1)
end
tcase << TestAction.new(:ImageView_StartNewConversationButton_2) do
$ruiObj = RUIObject.new.with('objectid', -274740130).with('selfid', 916878134).with('textdescid', -2118059933).with('uniqueparentid', 0)
.with('uitreeindex', 7)
.with('classname', 'ImageView')
.with('resource-id', 'com.google.android.apps.messaging:id/start_new_conversation_button')
.with('content-desc', 'Start new conversation')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:MultiAutoCompleteTextView_2) do
$ruiObj = RUIObject.new.with('objectid', -2030797265).with('selfid', -1346021293).with('textdescid', 1469794257).with('uniqueparentid', 0).with('classresourceid', -1346021293)
.with('uitreeindex', 0)
.with('classname', 'MultiAutoCompleteTextView')
$ruiObj.inputtext('A01 a01')
waitsecond(1)
end
tcase << TestAction.new(:clickXY_660_652_6) do
click(660,652)
waitsecond(1)
end
tcase << TestAction.new(:EditText_ComposeMessageText_8) do
$ruiObj = RUIObject.new.with('objectid', 1578981159).with('selfid', -1932318364).with('textdescid', 1703775705).with('uniqueparentid', 0)
.with('uitreeindex', 9)
.with('classname', 'EditText')
.with('resource-id', 'com.google.android.apps.messaging:id/compose_message_text')
$ruiObj.inputtext('')
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_141_1) do
$ruiObj.inputtext('Abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzaaaaaaaaaabbbbbbbbbbcccccccccc')
waitsecond(4)
end
tcase << TestAction.new(:ImageButton_SendMessageButton_10) do
$ruiObj = RUIObject.new.with('objectid', -1329122643).with('selfid', -1857249780).with('textdescid', 1740568962).with('uniqueparentid', 0)
.with('uitreeindex', 8)
.with('classname', 'ImageButton')
.with('resource-id', 'com.google.android.apps.messaging:id/send_message_button')
.with('content-desc', 'Send Message')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:pressBack_5) do
pressBack
end
tcase << TestAction.new(:pressBack_6) do
pressBack
end
tcase << TestAction.new(:clickXY_628_424_12) do
click(628,424)
waitsecond(1)
end
tcase << TestAction.new(:TextView_TimestampView_2) do
$ruiObj = RUIObject.new.with('objectid', 780859453).with('selfid', -108293667).with('textdescid', -1097305943).with('uniqueparentid', 0).with('classresourceid', 1659956455)
.with('uitreeindex', 8)
.with('classname', 'TextView')
.with('resource-id', 'com.android.mms:id/timestamp_view')
.with('text', 'Sending')
$ruiObj.isNotExist
end
tcase << TestAction.new(:scriptAction_30) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "Message not sent"
end
logStopTest("Messaging_05_01_02_03")
end
tcase << TestAction.new(:pressBack_53) do
pressBack
waitsecond(1)
end
tcase << TestAction.new(:pressBack_26) do
pressBack
waitsecond(1)
end
tcase.run(loopTime)
end
def self.Messaging_05_01_02_05(loopTime)
tcase = TestCase.new("Messaging_05_01_02_05")
tcase << TestAction.new(:scriptAction_28) do
logStartTest("Messaging_05_01_02_05")
end
tcase << TestAction.new(:gotoApp_2) do
gotoApp('Messenger')
waitsecond(1)
end
tcase << TestAction.new(:ImageView_StartNewConversationButton_2) do
$ruiObj = RUIObject.new.with('objectid', -274740130).with('selfid', 916878134).with('textdescid', -2118059933).with('uniqueparentid', 0)
.with('uitreeindex', 12)
.with('classname', 'ImageView')
.with('resource-id', 'com.google.android.apps.messaging:id/start_new_conversation_button')
.with('content-desc', 'Start new conversation')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:MultiAutoCompleteTextView_2) do
$ruiObj = RUIObject.new.with('objectid', -2030797265).with('selfid', -1346021293).with('textdescid', 1469794257).with('uniqueparentid', 0).with('classresourceid', -1346021293)
.with('uitreeindex', 0)
.with('classname', 'MultiAutoCompleteTextView')
$ruiObj.inputtext('A01 a01')
waitsecond(1)
end
tcase << TestAction.new(:clickXY_548_652_4) do
click(548,652)
waitsecond(1)
end
tcase << TestAction.new(:EditText_ComposeMessageText_6) do
$ruiObj = RUIObject.new.with('objectid', 1578981159).with('selfid', -1932318364).with('textdescid', 1703775705).with('uniqueparentid', 0)
.with('uitreeindex', 19)
.with('classname', 'EditText')
.with('resource-id', 'com.google.android.apps.messaging:id/compose_message_text')
$ruiObj.inputtext('')
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_141_1) do
$ruiObj.inputtext('Abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzaaaaaaaaaabbbbbbbbbbcccccccccc')
waitsecond(4)
end
tcase << TestAction.new(:ImageButton_AttachMediaButton_2) do
$ruiObj = RUIObject.new.with('objectid', 840041021).with('selfid', -952088716).with('textdescid', -438944396).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'ImageButton')
.with('resource-id', 'com.google.android.apps.messaging:id/attach_media_button')
.with('content-desc', 'Add an attachment')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_Choose_4) do
$ruiObj = RUIObject.new.with('objectid', 1408822083).with('selfid', 538927602).with('textdescid', 531479902).with('uniqueparentid', 0)
.with('uitreeindex', 23)
.with('classname', 'ImageButton')
.with('content-desc', 'Choose images from this device')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_MissingPermissionEnable_12) do
$ruiObj = RUIObject.new.with('objectid', -655699299).with('selfid', -1852985786).with('textdescid', -1480420102).with('uniqueparentid', 0)
.with('uitreeindex', 14)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.apps.messaging:id/missing_permission_enable')
.with('text', 'ALLOW')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_PermissionAllowButton_14) do
$ruiObj = RUIObject.new.with('objectid', -886457929).with('selfid', 1443382411).with('textdescid', 270556320).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'Button')
.with('resource-id', 'com.android.packageinstaller:id/permission_allow_button')
.with('text', 'ALLOW')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageView_Image_16) do
$ruiObj = RUIObject.new.with('objectid', 210721229).with('selfid', -1447729616).with('textdescid', -2055736335).with('uniqueparentid', 0)
.with('uitreeindex', 13)
.with('classname', 'ImageView')
.with('resource-id', 'com.google.android.apps.messaging:id/image')
.with('content-desc', 'Choose image from document library')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_Show_18) do
$ruiObj = RUIObject.new.with('objectid', 1571666208).with('selfid', -929198491).with('textdescid', 2010273934).with('uniqueparentid', 0)
.with('uitreeindex', 0)
.with('classname', 'ImageButton')
.with('content-desc', 'Show roots')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_20) do
$ruiObj = RUIObject.new.with('objectid', -1941383373).with('selfid', 176439065).with('textdescid', 1098848187).with('uniqueparentid', 0).with('classresourceid', 490183159)
.with('uitreeindex', 33)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'Videos')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_2) do
pressDPadDown
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_2_1) do
pressDPadDown
waitsecond(1)
end
tcase << TestAction.new(:pressEnter_4) do
pressEnter
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_2_1_1) do
pressDPadDown
waitsecond(1)
end
tcase << TestAction.new(:pressEnter_4_1) do
pressEnter
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_SendMessageButton_25) do
$ruiObj = RUIObject.new.with('objectid', -1329122643).with('selfid', -1857249780).with('textdescid', 1740568962).with('uniqueparentid', 0)
.with('uitreeindex', 9)
.with('classname', 'ImageButton')
.with('resource-id', 'com.google.android.apps.messaging:id/send_message_button')
.with('content-desc', 'Send Message')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:pressBack_5) do
pressBack
end
tcase << TestAction.new(:pressBack_5_1) do
pressBack
end
tcase << TestAction.new(:clickXY_700_468_27) do
click(700,468)
waitsecond(4)
end
tcase << TestAction.new(:LinearLayout_StatusIcons_10) do
$ruiObj = RUIObject.new.with('objectid', 84459867).with('selfid', 906570047).with('textdescid', -1676711387).with('uniqueparentid', 0).with('classresourceid', 1331229891)
.with('classname', 'LinearLayout')
.with('resource-id', 'com.android.mms:id/status_icons')
$ruiObj.isNotExist
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_30_1) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "Message not sent"
end
logStopTest("Messaging_05_01_02_05")
end
tcase << TestAction.new(:pressBack_53) do
pressBack
waitsecond(1)
end
tcase << TestAction.new(:pressBack_26) do
pressBack
waitsecond(1)
end
tcase.run(loopTime)
end
def self.Messaging_05_01_02_06(loopTime)
tcase = TestCase.new("Messaging_05_01_02_06")
tcase << TestAction.new(:scriptAction_28) do
logStartTest("Messaging_05_01_02_06")
end
tcase << TestAction.new(:gotoApp_2) do
gotoApp('Messenger')
waitsecond(1)
end
tcase << TestAction.new(:ImageView_StartNewConversationButton_2) do
$ruiObj = RUIObject.new.with('objectid', -274740130).with('selfid', 916878134).with('textdescid', -2118059933).with('uniqueparentid', 0)
.with('uitreeindex', 18)
.with('classname', 'ImageView')
.with('resource-id', 'com.google.android.apps.messaging:id/start_new_conversation_button')
.with('content-desc', 'Start new conversation')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:MultiAutoCompleteTextView_2) do
$ruiObj = RUIObject.new.with('objectid', -2030797265).with('selfid', -1346021293).with('textdescid', 1469794257).with('uniqueparentid', 0).with('classresourceid', -1346021293)
.with('uitreeindex', 0)
.with('classname', 'MultiAutoCompleteTextView')
$ruiObj.inputtext('A01 a01')
waitsecond(1)
end
tcase << TestAction.new(:clickXY_584_640_4) do
click(584,640)
waitsecond(1)
end
tcase << TestAction.new(:EditText_ComposeMessageText_6) do
$ruiObj = RUIObject.new.with('objectid', 1578981159).with('selfid', -1932318364).with('textdescid', 1703775705).with('uniqueparentid', 0)
.with('uitreeindex', 10)
.with('classname', 'EditText')
.with('resource-id', 'com.google.android.apps.messaging:id/compose_message_text')
$ruiObj.inputtext('')
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_141_1) do
$ruiObj.inputtext('Abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzaaaaaaaaaabbbbbbbbbbcccccccccc')
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_AttachMediaButton_8) do
$ruiObj = RUIObject.new.with('objectid', 840041021).with('selfid', -952088716).with('textdescid', -438944396).with('uniqueparentid', 0)
.with('uitreeindex', 6)
.with('classname', 'ImageButton')
.with('resource-id', 'com.google.android.apps.messaging:id/attach_media_button')
.with('content-desc', 'Add an attachment')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:ImageButton_Choose_10) do
$ruiObj = RUIObject.new.with('objectid', 1408822083).with('selfid', 538927602).with('textdescid', 531479902).with('uniqueparentid', 0)
.with('uitreeindex', 26)
.with('classname', 'ImageButton')
.with('content-desc', 'Choose images from this device')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_PermissionAllowButton_6) do
$ruiObj = RUIObject.new.with('objectid', 973397371).with('selfid', 1444367499).with('textdescid', -1740624804).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'Button')
.with('resource-id', 'com.android.packageinstaller:id/permission_allow_button')
.with('text', 'Allow')
$ruiObj.click
end
tcase << TestAction.new(:ImageView_Image_12) do
$ruiObj = RUIObject.new.with('objectid', 210721229).with('selfid', -1447729616).with('textdescid', -2055736335).with('uniqueparentid', 0)
.with('uitreeindex', 12)
.with('classname', 'ImageView')
.with('resource-id', 'com.google.android.apps.messaging:id/image')
.with('content-desc', 'Choose image from document library')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_Show_6) do
$ruiObj = RUIObject.new.with('objectid', -1807230859).with('selfid', -929198491).with('textdescid', 629574489).with('uniqueparentid', 0)
.with('uitreeindex', 0)
.with('classname', 'ImageButton')
.with('content-desc', 'Show roots')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_14) do
$ruiObj = RUIObject.new.with('objectid', -1941383373).with('selfid', -192133575).with('textdescid', -1736969061).with('uniqueparentid', 1190204722).with('classresourceid', 490183159)
.with('uitreeindex', 13)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'Images')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_2) do
pressDPadDown
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_2_1) do
pressDPadDown
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_2_1_1) do
pressDPadRight
waitsecond(1)
end
tcase << TestAction.new(:pressEnter_6) do
pressEnter
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_8) do
pressDPadDown
waitsecond(1)
end
tcase << TestAction.new(:pressEnter_6_1) do
pressEnter
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_SendMessageButton_20) do
$ruiObj = RUIObject.new.with('objectid', -1329122643).with('selfid', -1857249780).with('textdescid', 1740568962).with('uniqueparentid', 0)
.with('uitreeindex', 8)
.with('classname', 'ImageButton')
.with('resource-id', 'com.google.android.apps.messaging:id/send_message_button')
.with('content-desc', 'Send Message')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:pressBack_5) do
pressBack
end
tcase << TestAction.new(:pressBack_6) do
pressBack
end
tcase << TestAction.new(:clickXY_628_436_22) do
click(628,436)
waitsecond(4)
end
tcase << TestAction.new(:ProgressBar_Progressbar_6) do
$ruiObj = RUIObject.new.with('objectid', -1692373424).with('selfid', 1538496395).with('textdescid', -923968560).with('uniqueparentid', 0).with('classresourceid', 225978681)
.with('uitreeindex', 10)
.with('classname', 'ProgressBar')
.with('resource-id', 'com.android.mms:id/progressbar')
$ruiObj.isNotExist
end
tcase << TestAction.new(:scriptAction_30_1) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "End button not found"
end
logStopTest("Messaging_05_01_02_06")
end
tcase << TestAction.new(:pressBack_53) do
pressBack
waitsecond(1)
end
tcase << TestAction.new(:pressBack_26) do
pressBack
waitsecond(1)
end
tcase.run(loopTime)
end
def self.MultiMedia_05_01_07_01(loopTime)
tcase = TestCase.new("MultiMedia_05_01_07_01")
tcase << TestAction.new(:scriptAction_1) do
logStartTest("05_01_07_01_MultiMedia")
end
tcase << TestAction.new(:gotoApp_1) do
gotoApp('Camera')
end
tcase << TestAction.new(:Button_CancelButton_2) do
$ruiObj = RUIObject.new.with('objectid', 2138780457).with('selfid', 765132311).with('textdescid', -782727157).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'Button')
.with('resource-id', 'com.lge.camera:id/cancel_button')
.with('text', 'LATER')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:Button_CancelButton_4) do
$ruiObj = RUIObject.new.with('objectid', 2138780457).with('selfid', 765132311).with('textdescid', -782727157).with('uniqueparentid', 0)
.with('uitreeindex', 19)
.with('classname', 'Button')
.with('resource-id', 'com.lge.camera:id/cancel_button')
.with('text', 'LATER')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:ImageView_Thumbnail_2) do
$ruiObj = RUIObject.new.with('objectid', -2123601541).with('selfid', -135259702).with('textdescid', 357252685).with('uniqueparentid', 0)
.with('uitreeindex', 17)
.with('classname', 'ImageView')
.with('resource-id', 'com.lge.camera:id/thumbnail')
.with('content-desc', 'Gallery')
$ruiObj.isNotExist
ifFailJumpTo(:shutter)
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_QuickButtonCleanView_2) do
$ruiObj = RUIObject.new.with('objectid', 579583575).with('selfid', -1659256094).with('textdescid', -1654112402).with('uniqueparentid', 0)
.with('uitreeindex', 1)
.with('classname', 'ImageButton')
.with('resource-id', 'com.lge.camera:id/quick_button_clean_view')
.with('content-desc', 'View')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:shutter) do
$ruiObj = RUIObject.new.with('objectid', -1799776401).with('selfid', -1818636331).with('textdescid', -839551902).with('uniqueparentid', 0)
.with('uitreeindex', 13)
.with('classname', 'ImageButton')
.with('resource-id', 'com.lge.camera:id/shutter_top_comp')
.with('content-desc', 'Start recording')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:wait30second_14) do
waitsecond(30)
end
tcase << TestAction.new(:ImageButton_ShutterTopComp_6) do
$ruiObj = RUIObject.new.with('objectid', -1799776401).with('selfid', -1930433243).with('textdescid', 415097668).with('uniqueparentid', 0)
.with('uitreeindex', 5)
.with('pretext', '000008')
.with('classname', 'ImageButton')
.with('resource-id', 'com.lge.camera:id/shutter_top_comp')
.with('content-desc', 'Stop recording')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageView_Thumbnail_8) do
$ruiObj = RUIObject.new.with('objectid', -2123601541).with('selfid', -135259702).with('textdescid', 357252685).with('uniqueparentid', 0)
.with('uitreeindex', 14)
.with('classname', 'ImageView')
.with('resource-id', 'com.lge.camera:id/thumbnail')
.with('content-desc', 'Gallery')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_AllowButton_2) do
$ruiObj = RUIObject.new.with('objectid', -1049422851).with('selfid', -808516471).with('textdescid', -374437087).with('uniqueparentid', 0).with('classresourceid', 771022871)
.with('uitreeindex', 8)
.with('classname', 'Button')
.with('resource-id', 'com.lge:id/allow_button')
.with('text', 'OK')
$ruiObj.click
end
tcase << TestAction.new(:ImageButton_PhotosVideoplayerPlayButton_2) do
$ruiObj = RUIObject.new.with('objectid', 1557522096).with('selfid', -44944040).with('textdescid', 882455647).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'ImageButton')
.with('resource-id', 'com.google.android.apps.photos:id/photos_videoplayer_play_button')
.with('content-desc', 'Play video')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:clickXY_720_1576_4) do
click(720,1576)
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_PhotosVideoplayerPauseButton_6) do
$ruiObj = RUIObject.new.with('objectid', 843031060).with('selfid', -1751474194).with('textdescid', -989780891).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'ImageButton')
.with('resource-id', 'com.google.android.apps.photos:id/photos_videoplayer_pause_button')
.with('content-desc', 'Pause video')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_5) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason == "Video does not exist"
end
logStopTest("05_01_07_01_MultiMedia")
end
tcase << TestAction.new(:pressBack_6) do
pressBack
end
tcase << TestAction.new(:pressBack_7) do
pressBack
end
tcase << TestAction.new(:pressHome_8) do
pressHome
end
tcase.run(loopTime)
end
def self.MultiMedia_05_01_07_02(loopTime)
tcase = TestCase.new("MultiMedia_05_01_07_02")
tcase << TestAction.new(:scriptAction_1) do
logStartTest("05_01_07_02_MultiMedia")
end
tcase << TestAction.new(:gotoApp_1) do
gotoApp('Photos')
waitsecond(4)
end
tcase << TestAction.new(:Button_GetStarted_2) do
$ruiObj = RUIObject.new.with('objectid', -8992099).with('selfid', -1488261887).with('textdescid', 410629676).with('uniqueparentid', 0)
.with('uitreeindex', 0)
.with('classname', 'Button')
.with('resource-id', 'com.google.android.apps.photos:id/get_started')
.with('text', 'GET STARTED')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_DoneButton_4) do
$ruiObj = RUIObject.new.with('objectid', -82767090).with('selfid', -544460817).with('textdescid', -540247732).with('uniqueparentid', 0)
.with('uitreeindex', 12)
.with('classname', 'Button')
.with('resource-id', 'com.google.android.apps.photos:id/done_button')
.with('text', 'DONE')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageView_NextButton_6) do
$ruiObj = RUIObject.new.with('objectid', 808045513).with('selfid', 2472703).with('textdescid', 1170277002).with('uniqueparentid', 0)
.with('uitreeindex', 28)
.with('classname', 'ImageView')
.with('resource-id', 'com.google.android.apps.photos:id/next_button')
.with('content-desc', 'Next')
$ruiObj.click
end
tcase << TestAction.new(:ImageView_NextButton_8) do
$ruiObj = RUIObject.new.with('objectid', 808045513).with('selfid', 2472703).with('textdescid', 1170277002).with('uniqueparentid', 0)
.with('uitreeindex', 32)
.with('classname', 'ImageView')
.with('resource-id', 'com.google.android.apps.photos:id/next_button')
.with('content-desc', 'Next')
$ruiObj.click
end
tcase << TestAction.new(:clickXY_248_728_10) do
click(248,728)
waitsecond(1)
end
tcase << TestAction.new(:clickXY_248_728_10_1) do
click(248,728)
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_PhotosVideoplayerAccessibleFastRewindButton_13) do
$ruiObj = RUIObject.new.with('objectid', -1956582969).with('selfid', -4218830).with('textdescid', -1326807313).with('uniqueparentid', 0)
.with('uitreeindex', 1)
.with('classname', 'ImageButton')
.with('resource-id', 'com.google.android.apps.photos:id/photos_videoplayer_accessible_fast_rewind_button')
.with('content-desc', 'Rewind video')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:wait20second_4) do
waitsecond(20)
end
tcase << TestAction.new(:ImageButton_Pause_10) do
$ruiObj = RUIObject.new.with('objectid', 321323694).with('selfid', -485281624).with('textdescid', 2077043940).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('pretext', 'Videos')
.with('classname', 'ImageButton')
.with('resource-id', 'com.lge.videoplayer:id/pause')
.with('content-desc', 'Pause')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_7) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "Video did not play successfuly"
end
logStopTest("05_01_07_02_MultiMedia")
end
tcase << TestAction.new(:pressBack_8) do
pressBack
end
tcase << TestAction.new(:pressBack_9) do
pressBack
end
tcase << TestAction.new(:pressHome_10) do
pressHome
end
tcase.run(loopTime)
end
def self.MultiMedia_05_01_07_03(loopTime)
tcase = TestCase.new("MultiMedia_05_01_07_03")
tcase << TestAction.new(:scriptAction_1) do
logStartTest("05_01_07_03_MultiMedia")
end
tcase << TestAction.new(:gotoApp_1) do
gotoApp('Camera')
waitsecond(2)
end
tcase << TestAction.new(:ImageView_Thumbnail_2) do
$ruiObj = RUIObject.new.with('objectid', -2123601541).with('selfid', -135259702).with('textdescid', 357252685).with('uniqueparentid', 0)
.with('uitreeindex', 15)
.with('classname', 'ImageView')
.with('resource-id', 'com.lge.camera:id/thumbnail')
.with('content-desc', 'Gallery')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:ImageView_DeleteDeviceCopy_2) do
$ruiObj = RUIObject.new.with('objectid', -1082987894).with('selfid', 1093172219).with('textdescid', 252665825).with('uniqueparentid', 0)
.with('uitreeindex', 14)
.with('classname', 'ImageView')
.with('resource-id', 'com.google.android.apps.photos:id/delete_device_copy')
.with('content-desc', 'Delete')
$ruiObj.isExist
end
tcase << TestAction.new(:ImageView_DeleteDeviceCopy_4) do
$ruiObj = RUIObject.new.with('objectid', -1082987894).with('selfid', 1093172219).with('textdescid', 252665825).with('uniqueparentid', 0)
.with('uitreeindex', 14)
.with('classname', 'ImageView')
.with('resource-id', 'com.google.android.apps.photos:id/delete_device_copy')
.with('content-desc', 'Delete')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:Button_Button1_6) do
$ruiObj = RUIObject.new.with('objectid', -767191037).with('selfid', -525061855).with('textdescid', 6820052).with('uniqueparentid', 0).with('classresourceid', 1834539358)
.with('uitreeindex', 4)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'ALLOW')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:Button_Button1_8) do
$ruiObj = RUIObject.new.with('objectid', 606123187).with('selfid', -525061855).with('textdescid', -35369436).with('uniqueparentid', 0).with('classresourceid', 1834539358)
.with('uitreeindex', 2)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'ALLOW')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:Button_Button1_10) do
$ruiObj = RUIObject.new.with('objectid', -767191037).with('selfid', 982364851).with('textdescid', -1621738312).with('uniqueparentid', 0).with('classresourceid', 1834539358)
.with('uitreeindex', 4)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'DELETE')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:scriptAction_4) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason == "Video fail to delete"
end
logStopTest("05_01_07_03_MultiMedia")
end
tcase << TestAction.new(:pressBack_5) do
pressBack
end
tcase << TestAction.new(:pressBack_6) do
pressBack
end
tcase << TestAction.new(:pressHome_7) do
pressHome
end
tcase.run(loopTime)
end
def self.MultiMedia_05_01_07_04(loopTime)
tcase = TestCase.new("MultiMedia_05_01_07_04")
tcase << TestAction.new(:scriptAction_1) do
logStartTest("05_01_07_04_MultiMedia")
end
tcase << TestAction.new(:gotoApp_1) do
gotoApp('Camera')
end
tcase << TestAction.new(:Button_OkButton_2_1) do
$ruiObj = RUIObject.new.with('objectid', -658747592).with('selfid', 659685775).with('textdescid', -384972794).with('uniqueparentid', 0)
.with('uitreeindex', 22)
.with('classname', 'Button')
.with('resource-id', 'com.lge.camera:id/ok_button')
.with('text', 'Turn on')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_PermissionAllowButton_4_1) do
$ruiObj = RUIObject.new.with('objectid', 973397371).with('selfid', 1444367499).with('textdescid', -1740624804).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'Button')
.with('resource-id', 'com.android.packageinstaller:id/permission_allow_button')
.with('text', 'Allow')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_ShutterBottomCompType_2) do
$ruiObj = RUIObject.new.with('objectid', 215322368).with('selfid', -857985467).with('textdescid', -1914941152).with('uniqueparentid', 0)
.with('uitreeindex', 9)
.with('classname', 'ImageButton')
.with('resource-id', 'com.lge.camera:id/shutter_bottom_comp_type')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:scriptAction_10) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason == "Take picture FAILED"
end
logStopTest("05_01_07_04_MultiMedia")
end
tcase << TestAction.new(:pressBack_11) do
pressBack
end
tcase << TestAction.new(:pressBack_12) do
pressBack
end
tcase << TestAction.new(:pressHome_13) do
pressHome
end
tcase.run(loopTime)
end
def self.MultiMedia_05_01_07_05(loopTime)
tcase = TestCase.new("MultiMedia_05_01_07_05")
tcase << TestAction.new(:scriptAction_1) do
logStartTest("05_01_07_05_MultiMedia")
end
tcase << TestAction.new(:gotoApp_1) do
gotoApp('Camera')
waitsecond(2)
end
tcase << TestAction.new(:ImageView_Thumbnail_20) do
$ruiObj = RUIObject.new.with('objectid', -2123601541).with('selfid', -135259702).with('textdescid', 357252685).with('uniqueparentid', 0)
.with('uitreeindex', 13)
.with('classname', 'ImageView')
.with('resource-id', 'com.lge.camera:id/thumbnail')
.with('content-desc', 'Gallery')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:scriptAction_8) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason == "Picutre not open"
end
logStopTest("05_01_07_05_MultiMedia")
end
tcase << TestAction.new(:pressBack_9) do
pressBack
end
tcase << TestAction.new(:pressBack_10) do
pressBack
end
tcase << TestAction.new(:pressHome_11) do
pressHome
end
tcase.run(loopTime)
end
def self.MultiMedia_05_01_07_06(loopTime)
tcase = TestCase.new("MultiMedia_05_01_07_06")
tcase << TestAction.new(:scriptAction_1) do
logStartTest("05_01_07_06_MultiMedia")
end
tcase << TestAction.new(:gotoApp_1) do
gotoApp('Camera')
waitsecond(2)
end
tcase << TestAction.new(:ImageView_Thumbnail_2) do
$ruiObj = RUIObject.new.with('objectid', -2123601541).with('selfid', -135259702).with('textdescid', 357252685).with('uniqueparentid', 0)
.with('uitreeindex', 14)
.with('classname', 'ImageView')
.with('resource-id', 'com.lge.camera:id/thumbnail')
.with('content-desc', 'Gallery')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageView_DeleteDeviceCopy_2) do
$ruiObj = RUIObject.new.with('objectid', -1082987894).with('selfid', 1093172219).with('textdescid', 252665825).with('uniqueparentid', 0)
.with('uitreeindex', 9)
.with('classname', 'ImageView')
.with('resource-id', 'com.google.android.apps.photos:id/delete_device_copy')
.with('content-desc', 'Delete')
$ruiObj.isExist
waitsecond(2)
end
tcase << TestAction.new(:ImageView_DeleteDeviceCopy_4) do
$ruiObj = RUIObject.new.with('objectid', -1082987894).with('selfid', 1093172219).with('textdescid', 252665825).with('uniqueparentid', 0)
.with('uitreeindex', 9)
.with('classname', 'ImageView')
.with('resource-id', 'com.google.android.apps.photos:id/delete_device_copy')
.with('content-desc', 'Delete')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:Button_Button1_6) do
$ruiObj = RUIObject.new.with('objectid', -767191037).with('selfid', 982364851).with('textdescid', -1621738312).with('uniqueparentid', 0).with('classresourceid', 1834539358)
.with('uitreeindex', 4)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'DELETE')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:scriptAction_5) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason == "Picture is not found"
end
logStopTest("05_01_07_06_MultiMedia")
end
tcase << TestAction.new(:pressBack_6) do
pressBack
end
tcase << TestAction.new(:pressBack_7) do
pressBack
end
tcase << TestAction.new(:pressHome_8) do
pressHome
end
tcase.run(loopTime)
end
def self.MultiMedia_05_01_07_10(loopTime)
tcase = TestCase.new("MultiMedia_05_01_07_10")
tcase << TestAction.new(:scriptAction_1) do
logStartTest("05_01_07_10_MultiMedia")
end
tcase << TestAction.new(:gotoApp_1) do
gotoApp('YouTube')
waitsecond(2)
end
tcase << TestAction.new(:TextView_LaterButton_2) do
$ruiObj = RUIObject.new.with('objectid', 949353906).with('selfid', 702590847).with('textdescid', -874020510).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.youtube:id/later_button')
.with('text', 'LATER')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:TextView_Dismiss_2) do
$ruiObj = RUIObject.new.with('objectid', 118887004).with('selfid', 517159).with('textdescid', 1827199643).with('uniqueparentid', 0)
.with('uitreeindex', 5)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.youtube:id/dismiss')
.with('text', 'Not now')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_Image_2) do
$ruiObj = RUIObject.new.with('objectid', 875876029).with('selfid', 1315484302).with('textdescid', 1788421122).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'Button')
.with('resource-id', 'com.google.android.youtube:id/image')
.with('content-desc', 'Home')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageView_Thumbnail_3) do
$ruiObj = RUIObject.new.with('objectid', 875683821).with('selfid', -2120336906).with('textdescid', 1376394707).with('uniqueparentid', 0)
.with('uitreeindex', 10)
.with('pretext', 'WATCH MORE')
.with('classname', 'ImageView')
.with('resource-id', 'com.google.android.youtube:id/thumbnail')
$ruiObj.select('Similiar').click
end
tcase << TestAction.new(:wait10second_3) do
waitsecond(10)
end
tcase << TestAction.new(:TextView_SubscribeButton_4) do
$ruiObj = RUIObject.new.with('objectid', 1730328459).with('selfid', 1783143723).with('textdescid', -408811077).with('uniqueparentid', 0).with('classresourceid', -757100379)
.with('uitreeindex', 10)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.youtube:id/subscribe_button')
.with('content-desc', 'Subscribe to this channel')
.with('text', 'Subscribe')
$ruiObj.isExist
end
tcase << TestAction.new(:scriptAction_9) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason == "Video Streaming does not work"
end
logStopTest("05_01_07_10_MultiMedia")
end
tcase << TestAction.new(:pressBack_10) do
pressBack
end
tcase << TestAction.new(:pressBack_11) do
pressBack
end
tcase << TestAction.new(:pressHome_12) do
pressHome
end
tcase.run(loopTime)
end
def self.MultiTasking_05_01_08_01(loopTime)
tcase = TestCase.new("MultiTasking_05_01_08_01")
tcase << TestAction.new(:scriptAction_StartTest) do
logStartTest("05_01_08_01_MultiTasking")
end
tcase << TestAction.new(:gotoApp_1_1) do
gotoApp('Phone')
end
tcase << TestAction.new(:TextView_Tabtext_21) do
$ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 566119687).with('textdescid', 1861262411).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'TextView')
.with('resource-id', 'com.android.contacts:id/tabText')
.with('text', 'Dial')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:EditText_Digits_4) do
$ruiObj = RUIObject.new.with('objectid', 477485968).with('selfid', -1326421482).with('textdescid', 1917163152).with('uniqueparentid', 0)
.with('uitreeindex', 7)
.with('classname', 'EditText')
.with('resource-id', 'com.android.contacts:id/digits')
$ruiObj.inputtext('18003310500')
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_Btnlogscall_6) do
$ruiObj = RUIObject.new.with('objectid', -1934426254).with('selfid', -2053967649).with('textdescid', -911487124).with('uniqueparentid', 0)
.with('uitreeindex', 21)
.with('classname', 'ImageButton')
.with('resource-id', 'com.android.contacts:id/btnLogsCall')
.with('content-desc', 'Call')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:wait10second_3) do
waitsecond(10)
end
tcase << TestAction.new(:Button_Endbutton_2) do
$ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
.with('uitreeindex', 10)
.with('classname', 'Button')
.with('resource-id', 'com.android.incallui:id/endButton')
.with('text', 'End')
$ruiObj.isExist
end
tcase << TestAction.new(:scriptAction_4) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "End button not found"
end
logStopTest("05_01_08_01_MultiTasking")
end
tcase << TestAction.new(:pressHome_2) do
pressHome
end
tcase.run(loopTime)
end
def self.MultiTasking_05_01_08_02(loopTime)
tcase = TestCase.new("MultiTasking_05_01_08_02")
tcase << TestAction.new(:scriptAction_StartTestLog) do
logStartTest("05_01_08_02_MultiTasking")
end
tcase << TestAction.new(:gotoApp_1_1) do
gotoApp('Contacts')
waitsecond(2)
end
tcase << TestAction.new(:gotoApp_1_2) do
gotoApp('Messenger')
waitsecond(2)
end
tcase << TestAction.new(:gotoApp_1_3) do
gotoApp('Phone')
waitsecond(2)
end
tcase << TestAction.new(:gotoApp_1_4) do
gotoApp('Play Store')
waitsecond(2)
end
tcase << TestAction.new(:gotoApp_2) do
gotoApp('Camera')
waitsecond(2)
end
tcase << TestAction.new(:gotoApp_1_5_1) do
gotoApp('Chrome')
waitsecond(2)
end
tcase << TestAction.new(:ImageButton_MenuButton_2) do
$ruiObj = RUIObject.new.with('objectid', 554731264).with('selfid', -17041368).with('textdescid', 1097269587).with('uniqueparentid', 0)
.with('uitreeindex', 19)
.with('classname', 'ImageButton')
.with('resource-id', 'com.android.chrome:id/menu_button')
.with('content-desc', 'More options')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_LogStopTest) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "Apps not loaded"
end
logStopTest("05_01_08_02_MultiTasking")
end
tcase << TestAction.new(:pressBack_6) do
pressBack
end
tcase << TestAction.new(:pressBack_7) do
pressBack
end
tcase.run(loopTime)
end
def self.MultiTasking_05_01_08_03(loopTime)
tcase = TestCase.new("MultiTasking_05_01_08_03")
tcase << TestAction.new(:scriptAction_3) do
wakeUp()
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_StartTestLog_1) do
logStartTest("05_01_08_03_MultiTasking")
end
tcase << TestAction.new(:gotoApp_1_1) do
gotoApp('Phone')
end
tcase << TestAction.new(:Button_Endbutton_2_1_1) do
$ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
.with('uitreeindex', 8)
.with('classname', 'Button')
.with('resource-id', 'com.android.incallui:id/endButton')
.with('text', 'End')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_4_1) do
$UIDev.swipe(200,
$UIDev.getDisplayHeight-300,
$UIDev.getDisplayWidth-50,
$UIDev.getDisplayHeight-300,
10)
end
tcase << TestAction.new(:Button_Endbutton_6_1) do
$ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
.with('uitreeindex', 12)
.with('classname', 'Button')
.with('resource-id', 'com.android.incallui:id/endButton')
.with('text', 'End')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_LogStopTest) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "End button not found"
end
logStopTest("05_01_08_03_MultiTasking")
end
tcase << TestAction.new(:pressHome_20) do
pressHome
end
tcase.run(loopTime)
end
def self.MultiTasking_05_01_08_04(loopTime)
tcase = TestCase.new("MultiTasking_05_01_08_04")
tcase << TestAction.new(:scriptAction_StartTestLog) do
logStartTest("05_01_08_04_MultiTasking")
end
tcase << TestAction.new(:gotoApp_1_1) do
gotoApp('Chrome')
end
tcase << TestAction.new(:Button_TermsAccept_5) do
$ruiObj = RUIObject.new.with('objectid', 1131623741).with('selfid', 659232449).with('textdescid', -1120600562).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'Button')
.with('resource-id', 'com.android.chrome:id/terms_accept')
.with('text', 'Accept continue')
$ruiObj.click
end
tcase << TestAction.new(:Button_PositiveButton_6) do
$ruiObj = RUIObject.new.with('objectid', -1302979962).with('selfid', 780691289).with('textdescid', 1735628115).with('uniqueparentid', 0)
.with('uitreeindex', 5)
.with('classname', 'Button')
.with('resource-id', 'com.android.chrome:id/positive_button')
.with('text', 'Next')
$ruiObj.click
end
tcase << TestAction.new(:Button_PositiveButton_7) do
$ruiObj = RUIObject.new.with('objectid', -953817212).with('selfid', 780402664).with('textdescid', 1478534434).with('uniqueparentid', 0)
.with('uitreeindex', 7)
.with('classname', 'Button')
.with('resource-id', 'com.android.chrome:id/positive_button')
.with('text', 'Done')
$ruiObj.click
end
tcase << TestAction.new(:EditText_UrlBar_8) do
$ruiObj = RUIObject.new.with('objectid', 882195433).with('selfid', 613381324).with('textdescid', 1578254679).with('uniqueparentid', 0)
.with('uitreeindex', 7)
.with('classname', 'EditText')
.with('resource-id', 'com.android.chrome:id/url_bar')
$ruiObj.inputtext('www.att.com')
waitsecond(1)
end
tcase << TestAction.new(:pressEnter_5_1) do
pressEnter
waitsecond(4)
end
tcase << TestAction.new(:wait2second_2) do
waitsecond(2)
end
tcase << TestAction.new(:scriptAction_LogStopTest) do
$reload = RUIObject.new.with('objectid', -1485276626).with('selfid', 131798869).with('textdescid', -1148751605).with('uniqueparentid', -932380963)
.with('uitreeindex', 1)
.with('classname', 'Button')
.with('content-desc', 'RELOAD').exists?
$progressBar = RUIObject.new.with('objectid', 460148827).with('selfid', -703099949).with('textdescid', 1379711781).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('pretext', 'Block')
.with('classname', 'ProgressBar')
.with('resource-id', 'com.android.chrome:id/progress').exists?
if ($progressBar or $reload) == true
$myTestResult = false
else
$myTestResult = true
end
if $myTestResult == false
$myFailReason = "Browser is not starting"
end
logStopTest("05_01_08_04_MultiTasking")
end
tcase << TestAction.new(:pressHome_1) do
pressHome
end
tcase.run(loopTime)
end
def self.MultiTasking_05_01_08_05(loopTime)
tcase = TestCase.new("MultiTasking_05_01_08_05")
tcase << TestAction.new(:scriptAction_StartTestLog) do
logStartTest("05_01_08_05_MultiTasking")
end
tcase << TestAction.new(:gotoApp_1_1) do
gotoApp('Contacts')
waitsecond(2)
end
tcase << TestAction.new(:gotoApp_1_2) do
gotoApp('Messenger')
waitsecond(2)
end
tcase << TestAction.new(:gotoApp_1_3) do
gotoApp('Phone')
waitsecond(2)
end
tcase << TestAction.new(:gotoApp_1_4) do
gotoApp('Play Store')
waitsecond(2)
end
tcase << TestAction.new(:gotoApp_2) do
gotoApp('Camera')
waitsecond(2)
end
tcase << TestAction.new(:gotoApp_1_5) do
gotoApp('Chrome')
waitsecond(2)
end
tcase << TestAction.new(:ImageButton_DocumentMenuButton_2) do
$ruiObj = RUIObject.new.with('objectid', -1808270022).with('selfid', -336731118).with('textdescid', -1833889831).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'ImageButton')
.with('resource-id', 'com.android.chrome:id/document_menu_button')
.with('content-desc', 'More options')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_LogStopTest) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "End button not found"
end
logStopTest("05_01_08_05_MultiTasking")
end
tcase << TestAction.new(:pressBack_3) do
pressBack
end
tcase << TestAction.new(:pressBack_4) do
pressBack
end
tcase.run(loopTime)
end
def self.MultiTasking_05_01_08_06(loopTime)
tcase = TestCase.new("MultiTasking_05_01_08_06")
tcase << TestAction.new(:scriptAction_StartTestLog) do
logStartTest("05_01_08_06_MultiTasking")
end
tcase << TestAction.new(:gotoApp_1_1) do
gotoApp('Chrome')
waitsecond(2)
end
tcase << TestAction.new(:ImageButton_DocumentMenuButton_2) do
$ruiObj = RUIObject.new.with('objectid', -1808270022).with('selfid', -336731118).with('textdescid', -1833889831).with('uniqueparentid', 0)
.with('uitreeindex', 439)
.with('classname', 'ImageButton')
.with('resource-id', 'com.android.chrome:id/document_menu_button')
.with('content-desc', 'More options')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_LogStopTest) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "End button not found"
end
logStopTest("05_01_08_06_MultiTasking")
end
tcase << TestAction.new(:pressHome_1) do
pressHome
end
tcase.run(loopTime)
end
def self.NFC_05_01_11_01(loopTime)
tcase = TestCase.new("NFC_05_01_11_01")
tcase << TestAction.new(:scriptAction_28_1) do
UiDevice.getInstance.openNotification()
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_StartTestLog) do
logStartTest("05_01_11_01_NFC")
end
tcase << TestAction.new(:FrameLayout_SettingsButtonContainer_3) do
$ruiObj = RUIObject.new.with('objectid', -994030416).with('selfid', 1322766864).with('textdescid', 417942116).with('uniqueparentid', 0)
.with('classname', 'FrameLayout')
.with('resource-id', 'com.android.systemui:id/settings_button_container')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_2) do
$ruiObj = RUIObject.new.with('objectid', 674368800).with('selfid', -2078686330).with('textdescid', -957350501).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'Networks')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_4) do
$ruiObj = RUIObject.new.with('objectid', -487328458).with('selfid', 347833004).with('textdescid', -1018549621).with('uniqueparentid', 0).with('classresourceid', 490183159)
.with('uitreeindex', 28)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'Share connect')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Switch_Switchwidget_4) do
$ruiObj = RUIObject.new.with('objectid', 1615815228).with('selfid', 2013927764).with('textdescid', 153854525).with('uniqueparentid', 0).with('classresourceid', -1664951417)
.with('uitreeindex', 7)
.with('classname', 'Switch')
.with('resource-id', 'com.android.settings:id/switchWidget')
.with('text', 'ON')
$ruiObj.isExist
ifFailJumpTo(:Turn_on_1)
waitsecond(2)
end
tcase << TestAction.new(:Turn_on) do
click(1232,684)
waitsecond(2)
end
tcase << TestAction.new(:Turn_on_1) do
click(1232,684)
waitsecond(2)
end
tcase << TestAction.new(:Turn_on_2) do
click(1232,684)
waitsecond(2)
end
tcase << TestAction.new(:Switch_Switchwidget_2) do
$ruiObj = RUIObject.new.with('objectid', 1615815228).with('selfid', -1992748934).with('textdescid', 474516501).with('uniqueparentid', 0).with('classresourceid', -1664951417)
.with('uitreeindex', 7)
.with('classname', 'Switch')
.with('resource-id', 'com.android.settings:id/switchWidget')
.with('text', 'OFF')
$ruiObj.isExist
waitsecond(2)
end
tcase << TestAction.new(:pressBack_7) do
pressBack
end
tcase << TestAction.new(:pressBack_8) do
pressBack
end
tcase << TestAction.new(:scriptAction_LogStopTest) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "End button not found"
end
logStopTest("05_01_11_01_NFC")
end
tcase << TestAction.new(:pressBack_10) do
pressBack
end
tcase.run(loopTime)
end
def self.PIM_05_01_06_01(loopTime)
tcase = TestCase.new("PIM_05_01_06_01")
tcase << TestAction.new(:scriptAction_StartTestLog) do
logStartTest("05_01_06_01_PIM")
end
tcase << TestAction.new(:gotoApp_4) do
gotoApp('Calendar')
end
tcase << TestAction.new(:ImageView_RightArrow_2) do
$ruiObj = RUIObject.new.with('objectid', 120576481).with('selfid', -773553589).with('textdescid', -1353191203).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'ImageView')
.with('resource-id', 'com.google.android.calendar:id/right_arrow')
.with('content-desc', 'next page')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageView_RightArrow_4) do
$ruiObj = RUIObject.new.with('objectid', 120576481).with('selfid', -773553589).with('textdescid', -1353191203).with('uniqueparentid', 0)
.with('uitreeindex', 5)
.with('classname', 'ImageView')
.with('resource-id', 'com.google.android.calendar:id/right_arrow')
.with('content-desc', 'next page')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageView_RightArrow_6) do
$ruiObj = RUIObject.new.with('objectid', 120576481).with('selfid', -773553589).with('textdescid', -1353191203).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'ImageView')
.with('resource-id', 'com.google.android.calendar:id/right_arrow')
.with('content-desc', 'next page')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_DoneButton_8) do
$ruiObj = RUIObject.new.with('objectid', -530367081).with('selfid', -1828804226).with('textdescid', -1264958839).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'Button')
.with('resource-id', 'com.google.android.calendar:id/done_button')
.with('content-desc', 'Got it')
.with('text', 'GOT IT')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_Show_12) do
$ruiObj = RUIObject.new.with('objectid', -138219108).with('selfid', -2132232079).with('textdescid', 1916500102).with('uniqueparentid', 0)
.with('uitreeindex', 0)
.with('classname', 'ImageButton')
.with('content-desc', 'Show Calendar List and Settings drawer')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Label_14) do
$ruiObj = RUIObject.new.with('objectid', 1940182694).with('selfid', -693771).with('textdescid', 2098771294).with('uniqueparentid', 0).with('classresourceid', -498129859)
.with('uitreeindex', 16)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.calendar:id/label')
.with('text', 'Day')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_FloatingActionButton_33_1) do
$ruiObj = RUIObject.new.with('objectid', 1953345966).with('selfid', 220763148).with('textdescid', 1476526422).with('uniqueparentid', 0)
.with('uitreeindex', 6)
.with('classname', 'ImageButton')
.with('resource-id', 'com.google.android.calendar:id/floating_action_button')
.with('content-desc', 'Create new event and more')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_SpeedDialTitle_36_1) do
$ruiObj = RUIObject.new.with('objectid', 1229235289).with('selfid', 1868068256).with('textdescid', 265786407).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.calendar:id/speed_dial_title')
.with('content-desc', 'Event button')
.with('text', 'Event')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:EditText_Input_22) do
$ruiObj = RUIObject.new.with('objectid', -1826635904).with('selfid', 33055906).with('textdescid', -791138144).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'EditText')
.with('resource-id', 'com.google.android.calendar:id/input')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_PermissionAllowButton_24) do
$ruiObj = RUIObject.new.with('objectid', -886457929).with('selfid', 1443382411).with('textdescid', 270556320).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'Button')
.with('resource-id', 'com.android.packageinstaller:id/permission_allow_button')
.with('text', 'ALLOW')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:EditText_Input_22_1) do
$ruiObj = RUIObject.new.with('objectid', -1826635904).with('selfid', 33055906).with('textdescid', -791138144).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'EditText')
.with('resource-id', 'com.google.android.calendar:id/input')
$ruiObj.inputtext('Event')
waitsecond(2)
end
tcase << TestAction.new(:Button_Save_27) do
$ruiObj = RUIObject.new.with('objectid', 1614119710).with('selfid', 870102252).with('textdescid', -499081892).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'Button')
.with('resource-id', 'com.google.android.calendar:id/save')
.with('text', 'DONE')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_Save_29) do
$ruiObj = RUIObject.new.with('objectid', 1614119710).with('selfid', 870535911).with('textdescid', -485638463).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'Button')
.with('resource-id', 'com.google.android.calendar:id/save')
.with('text', 'SAVE')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_ActionToday_31) do
$ruiObj = RUIObject.new.with('objectid', 546077736).with('selfid', 751135543).with('textdescid', 1853532502).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.calendar:id/action_today')
.with('content-desc', 'Jump to Today')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_FloatingActionButton_33) do
$ruiObj = RUIObject.new.with('objectid', 1953345966).with('selfid', 220763148).with('textdescid', 1476526422).with('uniqueparentid', 0)
.with('uitreeindex', 6)
.with('classname', 'ImageButton')
.with('resource-id', 'com.google.android.calendar:id/floating_action_button')
.with('content-desc', 'Create new event and more')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_SpeedDialTitle_36) do
$ruiObj = RUIObject.new.with('objectid', 1229235289).with('selfid', 1868068256).with('textdescid', 265786407).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'TextView')
.with('resource-id', 'com.google.android.calendar:id/speed_dial_title')
.with('content-desc', 'Event button')
.with('text', 'Event')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:pressBack_30) do
pressBack
end
tcase << TestAction.new(:scriptAction_LogStopTest) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "End button not found"
end
logStopTest("05_01_06_01_PIM")
end
tcase << TestAction.new(:pressBack_10) do
pressBack
end
tcase << TestAction.new(:pressBack_2) do
pressBack
end
tcase.run(loopTime)
end
def self.PIM_05_01_06_02(loopTime)
tcase = TestCase.new("PIM_05_01_06_02")
tcase << TestAction.new(:gotoApp_2) do
gotoApp('Tools')
end
tcase << TestAction.new(:TextView_Clock_2) do
$ruiObj = RUIObject.new.with('objectid', -665293804).with('selfid', 1065244522).with('textdescid', 336857840).with('uniqueparentid', 0)
.with('uitreeindex', 5)
.with('classname', 'TextView')
.with('content-desc', 'Clock')
.with('text', 'Clock')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_StartTestLog) do
logStartTest("05_01_06_02_PIM")
end
tcase << TestAction.new(:Button_Button1_42) do
$ruiObj = RUIObject.new.with('objectid', -1592541968).with('selfid', -1318451484).with('textdescid', 1176208020).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'OK')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_22) do
$ruiObj = RUIObject.new.with('objectid', -322510520).with('selfid', -1121994128).with('textdescid', 2047918567).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'Alarm')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_DeleteAlarmMenu_2) do
$ruiObj = RUIObject.new.with('objectid', -627640121).with('selfid', 2100473433).with('textdescid', 1981482564).with('uniqueparentid', 0)
.with('uitreeindex', 1)
.with('classname', 'TextView')
.with('resource-id', 'com.lge.clock:id/delete_alarm_menu')
.with('content-desc', 'Delete')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:CheckBox_Checkall_6) do
$ruiObj = RUIObject.new.with('objectid', -1315363028).with('selfid', 359201994).with('textdescid', 1804684335).with('uniqueparentid', 0)
.with('uitreeindex', 0)
.with('classname', 'CheckBox')
.with('resource-id', 'com.lge.clock:id/checkall')
.with('text', 'Select all')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_Deletebutton_8) do
$ruiObj = RUIObject.new.with('objectid', -823128703).with('selfid', -664347347).with('textdescid', -891854826).with('uniqueparentid', 0)
.with('uitreeindex', 11)
.with('classname', 'Button')
.with('resource-id', 'com.lge.clock:id/deleteButton')
.with('text', 'Delete')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_Button1_4) do
$ruiObj = RUIObject.new.with('objectid', -405151478).with('selfid', 2077687487).with('textdescid', 489169807).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'Yes')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageView_Fab_10) do
$ruiObj = RUIObject.new.with('objectid', -476403250).with('selfid', -466463568).with('textdescid', -1883598830).with('uniqueparentid', 0)
.with('uitreeindex', 13)
.with('classname', 'ImageView')
.with('resource-id', 'com.lge.clock:id/fab')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_Savebutton_6) do
$ruiObj = RUIObject.new.with('objectid', -902674558).with('selfid', -575419535).with('textdescid', -816404443).with('uniqueparentid', 0)
.with('uitreeindex', 35)
.with('classname', 'Button')
.with('resource-id', 'com.lge.clock:id/saveButton')
.with('text', 'SAVE')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:Button_Savebutton_8) do
$ruiObj = RUIObject.new.with('objectid', -902674558).with('selfid', -575419535).with('textdescid', -816404443).with('uniqueparentid', 0)
.with('uitreeindex', 35)
.with('classname', 'Button')
.with('resource-id', 'com.lge.clock:id/saveButton')
.with('text', 'SAVE')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:pressBack_5) do
pressBack
end
tcase << TestAction.new(:scriptAction_LogStopTest) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "End button not found"
end
logStopTest("05_01_06_02_PIM")
end
tcase << TestAction.new(:pressBack_7) do
pressBack
end
tcase.run(loopTime)
end
def self.PIM_05_01_06_03(loopTime)
tcase = TestCase.new("PIM_05_01_06_03")
tcase << TestAction.new(:scriptAction_StartTestLog) do
logStartTest("05_01_06_03_PIM")
waitsecond(1)
end
tcase << TestAction.new(:gotoApp_2) do
gotoApp('Calendar')
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_Open_4) do
$ruiObj = RUIObject.new.with('objectid', 1598382174).with('selfid', 1589392844).with('textdescid', -1452260343).with('uniqueparentid', 0)
.with('uitreeindex', 0)
.with('classname', 'ImageButton')
.with('content-desc', 'Open navigation drawer')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_ButtonView_11) do
$ruiObj = RUIObject.new.with('objectid', 603982191).with('selfid', -1602079928).with('textdescid', -172768317).with('uniqueparentid', 0).with('classresourceid', 1399022470)
.with('uitreeindex', 58)
.with('classname', 'TextView')
.with('resource-id', 'com.android.calendar:id/button_view')
.with('text', 'Agenda')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_ActionToday_2) do
$ruiObj = RUIObject.new.with('objectid', -2135668340).with('selfid', 1131565901).with('textdescid', 1083312205).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'TextView')
.with('resource-id', 'com.android.calendar:id/action_today')
.with('content-desc', 'Today')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_4) do
$ruiObj = RUIObject.new.with('objectid', -1850572144).with('selfid', 548004568).with('textdescid', 1656008822).with('uniqueparentid', 0).with('classresourceid', -1613819572)
.with('uitreeindex', 8)
.with('classname', 'TextView')
.with('resource-id', 'com.android.calendar:id/title')
.with('text', 'Event')
$ruiObj.select('ItemFirst').click
waitsecond(1)
end
tcase << TestAction.new(:TextView_InfoActionDelete_12) do
$ruiObj = RUIObject.new.with('objectid', 1081504919).with('selfid', 1545757212).with('textdescid', 2217076).with('uniqueparentid', -2003986771)
.with('uitreeindex', 3)
.with('classname', 'TextView')
.with('resource-id', 'com.android.calendar:id/info_action_delete')
.with('content-desc', 'Delete')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_Button1_21) do
$ruiObj = RUIObject.new.with('objectid', -122532739).with('selfid', 982364851).with('textdescid', 1617680178).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'DELETE')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:Button_Button1_14) do
$ruiObj = RUIObject.new.with('objectid', -122532739).with('selfid', 2077687487).with('textdescid', 773318652).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'Yes')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:pressBack_7) do
pressBack
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_LogStopTest) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "End button not found"
end
logStopTest("05_01_06_03_PIM")
end
tcase << TestAction.new(:pressBack_9) do
pressBack
waitsecond(1)
end
tcase.run(loopTime)
end
def self.PIM_05_01_06_04(loopTime)
tcase = TestCase.new("PIM_05_01_06_04")
tcase << TestAction.new(:gotoApp_2) do
gotoApp('Tools')
end
tcase << TestAction.new(:TextView_Clock_2) do
$ruiObj = RUIObject.new.with('objectid', -665293804).with('selfid', 1065244522).with('textdescid', 336857840).with('uniqueparentid', 0)
.with('uitreeindex', 5)
.with('classname', 'TextView')
.with('content-desc', 'Clock')
.with('text', 'Clock')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_StartTestLog) do
logStartTest("05_01_06_04_PIM")
end
tcase << TestAction.new(:TextView_Title_21) do
$ruiObj = RUIObject.new.with('objectid', -322510520).with('selfid', -1121994128).with('textdescid', 2047918567).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'Alarm')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_DeleteAlarmMenu_5) do
$ruiObj = RUIObject.new.with('objectid', -627640121).with('selfid', 2100473433).with('textdescid', 1981482564).with('uniqueparentid', 0)
.with('uitreeindex', 1)
.with('classname', 'TextView')
.with('resource-id', 'com.lge.clock:id/delete_alarm_menu')
.with('content-desc', 'Delete')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:CheckBox_Checkall_7) do
$ruiObj = RUIObject.new.with('objectid', -1315363028).with('selfid', 359201994).with('textdescid', 1804684335).with('uniqueparentid', 0)
.with('uitreeindex', 0)
.with('classname', 'CheckBox')
.with('resource-id', 'com.lge.clock:id/checkall')
.with('text', 'Select all')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_Deletebutton_9) do
$ruiObj = RUIObject.new.with('objectid', -823128703).with('selfid', -664347347).with('textdescid', -891854826).with('uniqueparentid', 0)
.with('uitreeindex', 11)
.with('classname', 'Button')
.with('resource-id', 'com.lge.clock:id/deleteButton')
.with('text', 'Delete')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_Button1_11) do
$ruiObj = RUIObject.new.with('objectid', -405151478).with('selfid', 2077687487).with('textdescid', 489169807).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'Yes')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_NoContentsText_5) do
$ruiObj = RUIObject.new.with('objectid', -906561874).with('selfid', 2062356648).with('textdescid', -1982958191).with('uniqueparentid', 0)
.with('uitreeindex', 6)
.with('classname', 'TextView')
.with('resource-id', 'com.lge.clock:id/no_contents_text')
.with('text', 'No alarms')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:pressBack_15) do
pressBack
end
tcase << TestAction.new(:pressBack_16) do
pressBack
end
tcase << TestAction.new(:scriptAction_LogStopTest) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "End button not found"
end
logStopTest("05_01_06_04_PIM")
end
tcase.run(loopTime)
end
def self.StoreFrontDownload_05_01_05_01(loopTime)
tcase = TestCase.new("StoreFrontDownload_05_01_05_01")
tcase << TestAction.new(:scriptAction_1) do
logStartTest("05_01_05_01_StoreFrontDownload")
end
tcase << TestAction.new(:gotoApp_2) do
gotoApp('Play Store')
waitsecond(8)
end
tcase << TestAction.new(:ImageView_SearchBoxIdleText_4_1) do
$ruiObj = RUIObject.new.with('objectid', 1987043402).with('selfid', 88317888).with('textdescid', -133777698).with('uniqueparentid', 0)
.with('uitreeindex', 32)
.with('classname', 'ImageView')
.with('resource-id', 'com.android.vending:id/search_box_idle_text')
.with('content-desc', 'Search')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_True_False) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason == "Store Front is not loaded"
end
logStopTest("05_01_05_01_StoreFrontDownload")
end
tcase << TestAction.new(:pressBack_7) do
pressBack
end
tcase << TestAction.new(:pressHome_2) do
pressHome
end
tcase.run(loopTime)
end
def self.StoreFrontDownload_05_01_05_02(loopTime)
tcase = TestCase.new("StoreFrontDownload_05_01_05_02")
tcase << TestAction.new(:scriptAction_1) do
logStartTest("05_01_05_02_StoreFrontDownload")
end
tcase << TestAction.new(:gotoApp_2) do
gotoApp('Play Store')
waitsecond(8)
end
tcase << TestAction.new(:ImageView_SearchBoxIdleText_5) do
$ruiObj = RUIObject.new.with('objectid', 1987043402).with('selfid', 88317888).with('textdescid', -133777698).with('uniqueparentid', 0)
.with('uitreeindex', 32)
.with('classname', 'ImageView')
.with('resource-id', 'com.android.vending:id/search_box_idle_text')
.with('content-desc', 'Search')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:EditText_SearchBoxTextInput_6) do
$ruiObj = RUIObject.new.with('objectid', 1660565057).with('selfid', 209465679).with('textdescid', -62090753).with('uniqueparentid', 0)
.with('uitreeindex', 32)
.with('classname', 'EditText')
.with('resource-id', 'com.android.vending:id/search_box_text_input')
$ruiObj.inputtext('ColorNote')
waitsecond(1)
end
tcase << TestAction.new(:pressEnter_2) do
pressEnter
waitsecond(4)
end
tcase << TestAction.new(:TextView_LiTitle_4) do
$ruiObj = RUIObject.new.with('objectid', 1456557201).with('selfid', -1969590474).with('textdescid', 83190698).with('uniqueparentid', 0)
.with('uitreeindex', 5)
.with('classname', 'TextView')
.with('resource-id', 'com.android.vending:id/li_title')
.with('content-desc', 'App: ColorNote Notepad Notes')
.with('text', 'ColorNote Notepad Notes')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:Button_UninstallButton_UnInstall_exist) do
$ruiObj = RUIObject.new.with('objectid', -1388871150).with('selfid', -895718918).with('textdescid', -1334831508).with('uniqueparentid', 0)
.with('uitreeindex', 7)
.with('classname', 'Button')
.with('resource-id', 'com.android.vending:id/uninstall_button')
.with('text', 'UNINSTALL')
$ruiObj.isExist
ifFailJumpTo(:Button_BuyButton_1)
waitsecond(1)
end
tcase << TestAction.new(:Button_UninstallButton_UninstallCK_1) do
$ruiObj = RUIObject.new.with('objectid', -1388871150).with('selfid', -895718918).with('textdescid', -1334831508).with('uniqueparentid', 0)
.with('uitreeindex', 7)
.with('classname', 'Button')
.with('resource-id', 'com.android.vending:id/uninstall_button')
.with('text', 'UNINSTALL')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_Button1_Clk_OK) do
$ruiObj = RUIObject.new.with('objectid', 1379336962).with('selfid', -1318451484).with('textdescid', -1993773146).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'OK')
$ruiObj.click
waitsecond(8)
end
tcase << TestAction.new(:Button_BuyButton_1) do
$ruiObj = RUIObject.new.with('objectid', 1237348910).with('selfid', -652886121).with('textdescid', 538738615).with('uniqueparentid', 0)
.with('uitreeindex', 7)
.with('classname', 'Button')
.with('resource-id', 'com.android.vending:id/buy_button')
.with('text', 'INSTALL')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:Button_ContinueButton_2) do
$ruiObj = RUIObject.new.with('objectid', -1553570735).with('selfid', 1461394585).with('textdescid', 1663670089).with('uniqueparentid', 0)
.with('uitreeindex', 7)
.with('classname', 'Button')
.with('resource-id', 'com.android.vending:id/continue_button')
.with('text', 'ACCEPT')
$ruiObj.click
waitsecond(8)
end
tcase << TestAction.new(:Button_Button1_2) do
$ruiObj = RUIObject.new.with('objectid', 1379336962).with('selfid', 1349887951).with('textdescid', -101886821).with('uniqueparentid', 0)
.with('uitreeindex', 1)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'Continue')
$ruiObj.click
waitsecond(8)
end
tcase << TestAction.new(:Button_UninstallButton_4) do
$ruiObj = RUIObject.new.with('objectid', -1388871150).with('selfid', -895718918).with('textdescid', -1334831508).with('uniqueparentid', 0)
.with('uitreeindex', 7)
.with('classname', 'Button')
.with('resource-id', 'com.android.vending:id/uninstall_button')
.with('text', 'UNINSTALL')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_CheckPass) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason == "Install Failed"
end
logStopTest("05_01_05_02_StoreFrontDownload")
end
tcase << TestAction.new(:pressBack_16) do
pressBack
end
tcase << TestAction.new(:pressBack_17) do
pressBack
end
tcase << TestAction.new(:pressHome_19) do
pressHome
end
tcase.run(loopTime)
end
def self.StoreFrontDownload_05_01_05_04(loopTime)
tcase = TestCase.new("StoreFrontDownload_05_01_05_04")
tcase << TestAction.new(:scriptAction_1) do
logStartTest("05_01_05_04_StoreFrontDownload")
end
tcase << TestAction.new(:gotoApp_2) do
gotoApp('Play Store')
end
tcase << TestAction.new(:ImageView_ActionButton_2) do
$ruiObj = RUIObject.new.with('objectid', -369045791).with('selfid', 1033206202).with('textdescid', -584859083).with('uniqueparentid', 0)
.with('uitreeindex', 36)
.with('classname', 'ImageView')
.with('resource-id', 'com.android.vending:id/action_button')
.with('content-desc', 'Voice Search')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:pressBack_3) do
pressBack
end
tcase << TestAction.new(:scriptAction_True_False) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason == "Store Front cannot open and close"
end
logStopTest("05_01_05_04_StoreFrontDownload")
end
tcase << TestAction.new(:pressBack_2) do
pressBack
end
tcase << TestAction.new(:pressHome_3) do
pressHome
end
tcase.run(loopTime)
end
def self.StoreFrontDownload_05_01_05_05(loopTime)
tcase = TestCase.new("StoreFrontDownload_05_01_05_05")
tcase << TestAction.new(:scriptAction_1) do
logStartTest("05_01_05_05_StoreFrontDownload")
end
tcase << TestAction.new(:gotoApp_2) do
gotoApp('ColorNote')
end
tcase << TestAction.new(:TextView_EmptyText_AddNoteCK) do
$ruiObj = RUIObject.new.with('objectid', -1225710509).with('selfid', -126164144).with('textdescid', -1803056542).with('uniqueparentid', 0)
.with('uitreeindex', 6)
.with('classname', 'TextView')
.with('resource-id', 'com.socialnmobile.dictapps.notepad.color.note:id/empty_text')
.with('text', 'Add Note')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:pressBack_4) do
pressBack
end
tcase << TestAction.new(:scriptAction_True_False) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason == "Store Front is not loaded"
end
logStopTest("05_01_05_05_StoreFrontDownload")
end
tcase << TestAction.new(:pressHome_1) do
pressHome
end
tcase.run(loopTime)
end
def self.StoreFrontDownload_05_01_05_06(loopTime)
tcase = TestCase.new("StoreFrontDownload_05_01_05_06")
tcase << TestAction.new(:scriptAction_1) do
logStartTest("05_01_05_06_StoreFrontDownload")
end
tcase << TestAction.new(:gotoApp_2) do
gotoApp('Play Store')
waitsecond(1)
end
tcase << TestAction.new(:ImageView_SearchBoxIdleText_12) do
$ruiObj = RUIObject.new.with('objectid', 1987043402).with('selfid', 88317888).with('textdescid', -133777698).with('uniqueparentid', 0)
.with('uitreeindex', 28)
.with('classname', 'ImageView')
.with('resource-id', 'com.android.vending:id/search_box_idle_text')
.with('content-desc', 'Search')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:EditText_SearchBoxTextInput_13) do
$ruiObj = RUIObject.new.with('objectid', 1660565057).with('selfid', 209465679).with('textdescid', -62090753).with('uniqueparentid', 0)
.with('uitreeindex', 28)
.with('classname', 'EditText')
.with('resource-id', 'com.android.vending:id/search_box_text_input')
$ruiObj.inputtext('ColorNote')
waitsecond(1)
end
tcase << TestAction.new(:TextView_SuggestText_16) do
$ruiObj = RUIObject.new.with('objectid', 193809363).with('selfid', 208620854).with('textdescid', 1052874934).with('uniqueparentid', 0)
.with('uitreeindex', 32)
.with('classname', 'TextView')
.with('resource-id', 'com.android.vending:id/suggest_text')
.with('text', 'ColorNote Notepad Notes')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_LiTitle_2) do
$ruiObj = RUIObject.new.with('objectid', 1456557201).with('selfid', -1969590474).with('textdescid', 83190698).with('uniqueparentid', 0)
.with('uitreeindex', 5)
.with('classname', 'TextView')
.with('resource-id', 'com.android.vending:id/li_title')
.with('content-desc', 'App: ColorNote Notepad Notes')
.with('text', 'ColorNote Notepad Notes')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_LaunchButton_18) do
$ruiObj = RUIObject.new.with('objectid', 515078971).with('selfid', 328139855).with('textdescid', 387228145).with('uniqueparentid', 0)
.with('uitreeindex', 8)
.with('classname', 'Button')
.with('resource-id', 'com.android.vending:id/launch_button')
.with('text', 'OPEN')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_EmptyText_AddNoteCK) do
$ruiObj = RUIObject.new.with('objectid', -1225710509).with('selfid', -126164144).with('textdescid', -1803056542).with('uniqueparentid', 0)
.with('uitreeindex', 6)
.with('classname', 'TextView')
.with('resource-id', 'com.socialnmobile.dictapps.notepad.color.note:id/empty_text')
.with('text', 'Add Note')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:pressBack_20) do
pressBack
end
tcase << TestAction.new(:scriptAction_22) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason == "Open DL app from Store Front Fail"
end
logStopTest("05_01_05_06_StoreFrontDownload")
end
tcase << TestAction.new(:pressBack_23) do
pressBack
end
tcase << TestAction.new(:pressBack_2) do
pressBack
end
tcase << TestAction.new(:pressHome_24) do
pressHome
end
tcase.run(loopTime)
end
def self.StoreFrontDownload_05_01_05_07(loopTime)
tcase = TestCase.new("StoreFrontDownload_05_01_05_07")
tcase << TestAction.new(:scriptAction_1) do
logStartTest("05_01_05_07_StoreFrontDownload")
end
tcase << TestAction.new(:gotoApp_2) do
gotoApp('Play Store')
waitsecond(1)
end
tcase << TestAction.new(:ImageView_SearchBoxIdleText_5) do
$ruiObj = RUIObject.new.with('objectid', 1987043402).with('selfid', 88317888).with('textdescid', -133777698).with('uniqueparentid', 0)
.with('uitreeindex', 32)
.with('classname', 'ImageView')
.with('resource-id', 'com.android.vending:id/search_box_idle_text')
.with('content-desc', 'Search')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:EditText_SearchBoxTextInput_6) do
$ruiObj = RUIObject.new.with('objectid', 1660565057).with('selfid', 209465679).with('textdescid', -62090753).with('uniqueparentid', 0)
.with('uitreeindex', 32)
.with('classname', 'EditText')
.with('resource-id', 'com.android.vending:id/search_box_text_input')
$ruiObj.inputtext('ColorNote')
waitsecond(1)
end
tcase << TestAction.new(:TextView_SuggestText_7_Click_ColorNote) do
$ruiObj = RUIObject.new.with('objectid', 193809363).with('selfid', 208620854).with('textdescid', 1052874934).with('uniqueparentid', 0)
.with('uitreeindex', 36)
.with('classname', 'TextView')
.with('resource-id', 'com.android.vending:id/suggest_text')
.with('text', 'ColorNote Notepad Notes')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_LiTitle_2) do
$ruiObj = RUIObject.new.with('objectid', 1456557201).with('selfid', -1969590474).with('textdescid', 83190698).with('uniqueparentid', 0)
.with('uitreeindex', 5)
.with('classname', 'TextView')
.with('resource-id', 'com.android.vending:id/li_title')
.with('content-desc', 'App: ColorNote Notepad Notes')
.with('text', 'ColorNote Notepad Notes')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_UninstallButton_15_pressed) do
$ruiObj = RUIObject.new.with('objectid', -1388871150).with('selfid', -895718918).with('textdescid', -1334831508).with('uniqueparentid', 0)
.with('uitreeindex', 7)
.with('classname', 'Button')
.with('resource-id', 'com.android.vending:id/uninstall_button')
.with('text', 'UNINSTALL')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_Button1_16_pressed_OK) do
$ruiObj = RUIObject.new.with('objectid', 1379336962).with('selfid', -1318451484).with('textdescid', -1993773146).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'OK')
$ruiObj.click
waitsecond(8)
end
tcase << TestAction.new(:Button_BuyButton_18_Install) do
$ruiObj = RUIObject.new.with('objectid', 1237348910).with('selfid', -652886121).with('textdescid', 538738615).with('uniqueparentid', 0)
.with('uitreeindex', 7)
.with('classname', 'Button')
.with('resource-id', 'com.android.vending:id/buy_button')
.with('text', 'INSTALL')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_CheckPass) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason == "Install Failed"
end
logStopTest("05_01_05_07_StoreFrontDownload")
end
tcase << TestAction.new(:pressBack_16) do
pressBack
end
tcase << TestAction.new(:pressBack_17) do
pressBack
end
tcase << TestAction.new(:pressHome_19) do
pressHome
end
tcase.run(loopTime)
end
def self.Telephony_05_01_01_03(loopTime)
tcase = TestCase.new("Telephony_05_01_01_03")
tcase << TestAction.new(:scriptAction_StartTest_1) do
logStartTest("05_01_01_03_Telephony")
end
tcase << TestAction.new(:gotoApp_1_1) do
gotoApp('Phone')
end
tcase << TestAction.new(:TextView_Tabtext_2) do
$ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 715664122).with('textdescid', 24268628).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'TextView')
.with('resource-id', 'com.android.contacts:id/tabText')
.with('text', 'Call logs')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageView_SecondaryActionIcon_2) do
$ruiObj = RUIObject.new.with('objectid', 1053896352).with('selfid', -1241359936).with('textdescid', 579079266).with('uniqueparentid', 0).with('classresourceid', -550590844)
.with('uitreeindex', 9)
.with('pretext', 'Groups?0')
.with('classname', 'ImageView')
.with('resource-id', 'com.android.contacts:id/secondary_action_icon')
.with('content-desc', 'Call A01 a01')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:wait8second_31) do
waitsecond(12)
end
tcase << TestAction.new(:scriptAction_10_1) do
sendBTCmd('answerCall')
waitsecond(8)
end
tcase << TestAction.new(:scriptAction_10_1_1) do
sendBTCmd('endCall')
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_LogStopTest) do
$myTestResult = checkLastBTCmdResult
if $myTestResult == false
$myFailReason = "Call not come to other dev"
end
logStopTest("05_01_01_03_Telephony")
end
tcase << TestAction.new(:Button_Endbutton_6) do
$ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
.with('uitreeindex', 8)
.with('classname', 'Button')
.with('resource-id', 'com.android.incallui:id/endButton')
.with('text', 'End')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:pressBack_1) do
pressBack
end
tcase << TestAction.new(:pressBack_2) do
pressBack
end
tcase.run(loopTime)
end
def self.Telephony_05_01_01_05(loopTime)
tcase = TestCase.new("Telephony_05_01_01_05")
tcase << TestAction.new(:pressHome_2) do
pressHome
end
tcase << TestAction.new(:scriptAction_StartTestLog_1) do
logStartTest("05_01_01_05_Telephony")
end
tcase << TestAction.new(:scriptAction_BTMakeCall) do
sendBTCmd("makeCall('#{db('CallNumber')[0]}')")
waitsecond(8)
end
tcase << TestAction.new(:wait8second_12) do
waitsecond(8)
end
tcase << TestAction.new(:wait8second_14) do
waitsecond(8)
end
tcase << TestAction.new(:answerSwipe) do
$UIDev.swipe(288,1860,288,1400,10)
waitsecond(8)
end
tcase << TestAction.new(:Button_Endbutton_2) do
$ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
.with('uitreeindex', 10)
.with('classname', 'Button')
.with('resource-id', 'com.android.incallui:id/endButton')
.with('text', 'End')
$ruiObj.isNotExist
ifFailJumpTo(:Button_Endbutton_2_1)
waitsecond(1)
end
tcase << TestAction.new(:answerSwipe_1) do
$UIDev.swipe(288,1860,288,1400,10)
waitsecond(2)
end
tcase << TestAction.new(:Button_Endbutton_2_1) do
$ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
.with('uitreeindex', 10)
.with('classname', 'Button')
.with('resource-id', 'com.android.incallui:id/endButton')
.with('text', 'End')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_LogStopTest_1) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "End button not found"
end
logStopTest("05_01_01_05_Telephony")
end
tcase << TestAction.new(:scriptAction_BTEndCall) do
sendBTCmd('endCall')
end
tcase << TestAction.new(:Button_Endbutton_2_1_1) do
$ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
.with('uitreeindex', 10)
.with('classname', 'Button')
.with('resource-id', 'com.android.incallui:id/endButton')
.with('text', 'End')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:pressBack_1) do
pressBack
end
tcase << TestAction.new(:pressBack_2) do
pressBack
end
tcase.run(loopTime)
end
def self.Telephony_05_01_01_06(loopTime)
tcase = TestCase.new("Telephony_05_01_01_06")
tcase << TestAction.new(:scriptAction_StartTestLog) do
logStartTest("05_01_01_06_Telephony")
end
tcase << TestAction.new(:gotoApp_3) do
gotoApp('Phone')
end
tcase << TestAction.new(:TextView_Tabtext_2) do
$ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 1015283306).with('textdescid', -1384079800).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'TextView')
.with('resource-id', 'com.android.contacts:id/tabText')
.with('text', 'Contacts')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:EditText_SearchSrcText_2) do
$ruiObj = RUIObject.new.with('objectid', 588070375).with('selfid', -959326622).with('textdescid', -497243406).with('uniqueparentid', 0)
.with('uitreeindex', 6)
.with('classname', 'EditText')
.with('resource-id', 'android:id/search_src_text')
.with('content-desc', 'Search contacts')
$ruiObj.inputtext('tn tn')
waitsecond(1)
end
tcase << TestAction.new(:TextView_tn_6) do
$ruiObj = RUIObject.new.with('objectid', 1836583107).with('selfid', -71120562).with('textdescid', 984860861).with('uniqueparentid', 0).with('classresourceid', -938935918)
.with('uitreeindex', 13)
.with('classname', 'TextView')
.with('content-desc', 'tn tn')
.with('text', 'tn tn')
$ruiObj.select('ItemFirst').click
waitsecond(1)
end
tcase << TestAction.new(:TextView_MenuDelete_2) do
$ruiObj = RUIObject.new.with('objectid', -1318735913).with('selfid', 1219450656).with('textdescid', 2068859689).with('uniqueparentid', 0)
.with('uitreeindex', 23)
.with('pretext', 'NOTIFICATION SOUND')
.with('classname', 'TextView')
.with('resource-id', 'com.android.contacts:id/menu_delete')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_Button1_43) do
$ruiObj = RUIObject.new.with('objectid', -195446968).with('selfid', 982364851).with('textdescid', -1387444483).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'DELETE')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:Button_Button1_22_1) do
$ruiObj = RUIObject.new.with('objectid', -195446968).with('selfid', -1318451484).with('textdescid', 917278956).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'OK')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_LogStopTest) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "End button not found"
end
logStopTest("05_01_01_06_Telephony")
end
tcase << TestAction.new(:pressBack_2) do
pressBack
end
tcase << TestAction.new(:pressBack_3) do
pressBack
end
tcase.run(loopTime)
end
def self.Telephony_05_01_01_07(loopTime)
tcase = TestCase.new("Telephony_05_01_01_07")
tcase << TestAction.new(:scriptAction_StartTestLog) do
logStartTest("05_01_01_07_Telephony")
end
tcase << TestAction.new(:gotoApp_3) do
gotoApp('Phone')
waitsecond(1)
end
tcase << TestAction.new(:TextView_Tabtext_2) do
$ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 1015283306).with('textdescid', -1384079800).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'TextView')
.with('resource-id', 'com.android.contacts:id/tabText')
.with('text', 'Contacts')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageButton_AddContactButton_2) do
$ruiObj = RUIObject.new.with('objectid', 168201771).with('selfid', 2046190261).with('textdescid', 1812475979).with('uniqueparentid', 0)
.with('uitreeindex', 7)
.with('classname', 'ImageButton')
.with('resource-id', 'com.android.contacts:id/add_contact_button')
.with('content-desc', 'New contact')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:EditText_14) do
$ruiObj = RUIObject.new.with('objectid', -2023645967).with('selfid', 1666676343).with('textdescid', 1691484495).with('uniqueparentid', 0).with('classresourceid', 1666676343)
.with('uitreeindex', 6)
.with('pretext', 'Phone?0')
.with('classname', 'EditText')
$ruiObj.inputtext('tn tn')
waitsecond(1)
end
tcase << TestAction.new(:EditText_16) do
$ruiObj = RUIObject.new.with('objectid', 1622197326).with('selfid', 1666676343).with('textdescid', -1251490414).with('uniqueparentid', 0).with('classresourceid', 1666676343)
.with('uitreeindex', 9)
.with('pretext', 'Phone?1')
.with('classname', 'EditText')
$ruiObj.inputtext('00000000')
waitsecond(1)
end
tcase << TestAction.new(:Button_BtnSave_4) do
$ruiObj = RUIObject.new.with('objectid', 344009592).with('selfid', -1684371128).with('textdescid', -1561576549).with('uniqueparentid', 0)
.with('uitreeindex', 19)
.with('classname', 'Button')
.with('resource-id', 'com.android.contacts:id/btn_save')
.with('text', 'SAVE')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:Button_BtnSave_20) do
$ruiObj = RUIObject.new.with('objectid', 344009592).with('selfid', -1684339352).with('textdescid', -1560591493).with('uniqueparentid', 0)
.with('uitreeindex', 16)
.with('classname', 'Button')
.with('resource-id', 'com.android.contacts:id/btn_save')
.with('text', 'Save')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_Button1_2) do
$ruiObj = RUIObject.new.with('objectid', -195446968).with('selfid', 2077686463).with('textdescid', -1628829679).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'YES')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_LogStopTest) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "Contact is not saved"
end
logStopTest("05_01_01_07_Telephony")
end
tcase << TestAction.new(:pressBack_5) do
pressBack
end
tcase << TestAction.new(:pressBack_6) do
pressBack
end
tcase.run(loopTime)
end
def self.VideoCall_01(loopTime)
tcase = TestCase.new("VideoCall_01")
tcase << TestAction.new(:scriptAction_StartTest_1) do
logStartTest("VideoCall_01")
end
tcase << TestAction.new(:pressHome_4) do
pressHome
end
tcase << TestAction.new(:TextView_Phone_2) do
$ruiObj = RUIObject.new.with('objectid', -479243074).with('selfid', 1134672426).with('textdescid', 1322329030).with('uniqueparentid', 0)
.with('uitreeindex', 9)
.with('classname', 'TextView')
.with('content-desc', 'Phone')
.with('text', 'Phone')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Tabtext_2) do
$ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 1015283306).with('textdescid', -1384079800).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'TextView')
.with('resource-id', 'com.android.contacts:id/tabText')
.with('text', 'Contacts')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:EditText_SearchSrcText_2) do
$ruiObj = RUIObject.new.with('objectid', 588070375).with('selfid', -959326622).with('textdescid', -497243406).with('uniqueparentid', 0)
.with('uitreeindex', 6)
.with('classname', 'EditText')
.with('resource-id', 'android:id/search_src_text')
.with('content-desc', 'Search contacts')
$ruiObj.inputtext('A01 a01')
waitsecond(1)
end
tcase << TestAction.new(:TextView_A01_4) do
$ruiObj = RUIObject.new.with('objectid', -728261803).with('selfid', -2094016618).with('textdescid', -1517178717).with('uniqueparentid', 0).with('classresourceid', -938935918)
.with('uitreeindex', 12)
.with('classname', 'TextView')
.with('content-desc', 'A01 a01')
.with('text', 'A01 a01')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageView_EabActionButton_2) do
$ruiObj = RUIObject.new.with('objectid', -209436562).with('selfid', 14418249).with('textdescid', 2097401202).with('uniqueparentid', 0).with('classresourceid', -1382351217)
.with('uitreeindex', 9)
.with('classname', 'ImageView')
.with('resource-id', 'com.android.contacts:id/eab_action_button')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:wait8second_31) do
waitsecond(8)
end
tcase << TestAction.new(:scriptAction_18_1) do
sendBTCmd('answerCall')
waitsecond(8)
end
tcase << TestAction.new(:scriptAction_18_1_1) do
sendBTCmd('endCall')
waitsecond(2)
end
tcase << TestAction.new(:scriptAction_LogStopTest_1_1) do
$myTestResult = checkLastBTCmdResult
if $myTestResult == false
$myFailReason = "Call not come to other dev"
end
logStopTest("VideoCall_01")
end
tcase << TestAction.new(:Button_ButtonEndCall_4) do
$ruiObj = RUIObject.new.with('objectid', 449066258).with('selfid', 2024460923).with('textdescid', -1859117805).with('uniqueparentid', 0)
.with('uitreeindex', 8)
.with('classname', 'Button')
.with('resource-id', 'com.android.incallui:id/button_end_call')
.with('text', 'End')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:pressBack_3) do
pressBack
end
tcase << TestAction.new(:pressBack_4) do
pressBack
end
tcase.run(loopTime)
end
def self.WiFi_05_01_10_01(loopTime)
tcase = TestCase.new("WiFi_05_01_10_01")
tcase << TestAction.new(:scriptAction_2) do
logStartTest("05_01_10_01_WiFi")
end
tcase << TestAction.new(:gotoApp_5) do
gotoApp('Settings')
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_2) do
$ruiObj = RUIObject.new.with('objectid', 674368800).with('selfid', -2078686330).with('textdescid', -957350501).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'Networks')
$ruiObj.click
end
tcase << TestAction.new(:TextView_Title_4) do
$ruiObj = RUIObject.new.with('objectid', 2008023572).with('selfid', -589731018).with('textdescid', 498664031).with('uniqueparentid', 0).with('classresourceid', 490183159)
.with('uitreeindex', 8)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'Wi-Fi')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_27) do
$ruiObj = RUIObject.new.with('objectid', 67205646).with('selfid', -589731018).with('textdescid', 397088473).with('uniqueparentid', 1090881942).with('classresourceid', 490183159)
.with('uitreeindex', 23)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'WiFi')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:Button_Button2_2) do
$ruiObj = RUIObject.new.with('objectid', -360890209).with('selfid', -1317527958).with('textdescid', -223504546).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'Button')
.with('resource-id', 'android:id/button2')
.with('text', 'No')
$ruiObj.click
end
tcase << TestAction.new(:ImageView_Icon_2) do
$ruiObj = RUIObject.new.with('objectid', -1337042610).with('selfid', -1580627678).with('textdescid', 1501352082).with('uniqueparentid', 0).with('classresourceid', -858811928)
.with('uitreeindex', 8)
.with('pretext', 'WiFi networks')
.with('classname', 'ImageView')
.with('resource-id', 'android:id/icon')
$ruiObj.isExist
ifFailJumpTo(:Switch_OFF_10)
waitsecond(1)
end
tcase << TestAction.new(:Switch_ON_8) do
$ruiObj = RUIObject.new.with('objectid', 1178284996).with('selfid', 1645353587).with('textdescid', -1975291963).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'Switch')
.with('text', 'ON')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:Switch_OFF_10) do
$ruiObj = RUIObject.new.with('objectid', 1178284996).with('selfid', -533646533).with('textdescid', -1104515187).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'Switch')
.with('text', 'OFF')
$ruiObj.click
waitsecond(4)
end
tcase << TestAction.new(:TextView_Title_245) do
$ruiObj = RUIObject.new.with('objectid', 1391628862).with('selfid', 1193786863).with('textdescid', 936938386).with('uniqueparentid', 0).with('classresourceid', 490183159)
.with('uitreeindex', 7)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'WIFI NETWORKS')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:Switch_ON_14) do
$ruiObj = RUIObject.new.with('objectid', 1178284996).with('selfid', 1645353587).with('textdescid', -1975291963).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'Switch')
.with('text', 'ON')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_10_TrueFalse) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason = "WiFi cannot turn ON"
end
logStopTest("05_01_10_01_WiFi")
waitsecond(1)
end
tcase << TestAction.new(:pressBack_20) do
pressBack
end
tcase << TestAction.new(:pressBack_21) do
pressBack
end
tcase << TestAction.new(:pressHome_22) do
pressHome
end
tcase.run(loopTime)
end
def self.WiFi_05_01_10_02(loopTime)
tcase = TestCase.new("WiFi_05_01_10_02")
tcase << TestAction.new(:scriptAction_2) do
logStartTest("05_01_10_02_WiFi")
end
tcase << TestAction.new(:gotoApp_2) do
gotoApp('Settings')
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_2) do
$ruiObj = RUIObject.new.with('objectid', 674368800).with('selfid', -2078686330).with('textdescid', -957350501).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'Networks')
$ruiObj.click
end
tcase << TestAction.new(:TextView_Title_21) do
$ruiObj = RUIObject.new.with('objectid', 67205646).with('selfid', -589731018).with('textdescid', 397088473).with('uniqueparentid', 0).with('classresourceid', 490183159)
.with('uitreeindex', 23)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'WiFi')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Empty_25) do
$ruiObj = RUIObject.new.with('objectid', 1333259948).with('selfid', -886975434).with('textdescid', 1201392520).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'TextView')
.with('resource-id', 'android:id/empty')
.with('text', 'Turn WiFi on in the upper right corner to see available networks')
$ruiObj.isExist
ifFailJumpTo(:wait1second_21)
end
tcase << TestAction.new(:Switch_ON_2_1_1) do
$ruiObj = RUIObject.new.with('objectid', 1178284996).with('selfid', 1645353587).with('textdescid', -1975291963).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'Switch')
.with('text', 'ON')
$ruiObj.click
end
tcase << TestAction.new(:wait1second_21) do
waitsecond(1)
end
tcase << TestAction.new(:check_if_wifi_is_added) do
$ruiObj = RUIObject.new.with('objectid', -1789239232).with('selfid', -789618896).with('textdescid', 272817007).with('uniqueparentid', 0).with('classresourceid', 490183159)
.with('uitreeindex', 11)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'qctcomp')
$ruiObj.isNotExist
ifFailJumpTo(:check_connection)
waitsecond(1)
end
tcase << TestAction.new(:Add_wifi) do
$ruiObj = RUIObject.new.with('objectid', 1634319278).with('selfid', 1290820192).with('textdescid', 371464933).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'ImageButton')
.with('content-desc', 'More options')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_6) do
$ruiObj = RUIObject.new.with('objectid', -1984796814).with('selfid', -392058123).with('textdescid', -1929502754).with('uniqueparentid', 0).with('classresourceid', 490183159)
.with('uitreeindex', 0)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'Add WiFi')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:EditText_Ssid_8) do
$ruiObj = RUIObject.new.with('objectid', 1745689399).with('selfid', 1359933717).with('textdescid', -1718203447).with('uniqueparentid', 0).with('classresourceid', -1413606463)
.with('uitreeindex', 2)
.with('classname', 'EditText')
.with('resource-id', 'com.lge.wifisettings:id/ssid')
$ruiObj.inputtext('qctcomp')
waitsecond(1)
end
tcase << TestAction.new(:Button_Button1_10) do
$ruiObj = RUIObject.new.with('objectid', -360890210).with('selfid', -210572094).with('textdescid', 1221395928).with('uniqueparentid', 0)
.with('uitreeindex', 7)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'CONNECT')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:check_connection) do
$ruiObj = RUIObject.new.with('objectid', 1399891586).with('selfid', -404041766).with('textdescid', 623785653).with('uniqueparentid', 0).with('classresourceid', -1930775675)
.with('uitreeindex', 10)
.with('classname', 'TextView')
.with('resource-id', 'android:id/summary')
.with('text', 'Connected')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_Button3_15) do
$ruiObj = RUIObject.new.with('objectid', -360890208).with('selfid', 1759634711).with('textdescid', 452800563).with('uniqueparentid', 0)
.with('uitreeindex', 12)
.with('classname', 'Button')
.with('resource-id', 'android:id/button3')
.with('text', 'Forget')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_14) do
$ruiObj = RUIObject.new.with('objectid', -1789239232).with('selfid', -789618896).with('textdescid', 272817007).with('uniqueparentid', 0).with('classresourceid', 490183159)
.with('uitreeindex', 15)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'qctcomp')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:EditText_Password_17) do
$ruiObj = RUIObject.new.with('objectid', -976316462).with('selfid', -2120332491).with('textdescid', -201039218).with('uniqueparentid', 0).with('classresourceid', -714852383)
.with('uitreeindex', 2)
.with('classname', 'EditText')
.with('resource-id', 'com.lge.wifisettings:id/password')
$ruiObj.inputtext('12abcdef34')
waitsecond(1)
end
tcase << TestAction.new(:Button_Button1_18) do
$ruiObj = RUIObject.new.with('objectid', -360890210).with('selfid', -210572094).with('textdescid', 1221395928).with('uniqueparentid', 0)
.with('uitreeindex', 6)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'CONNECT')
$ruiObj.click
waitsecond(4)
end
tcase << TestAction.new(:TextView_Summary_2) do
$ruiObj = RUIObject.new.with('objectid', 1704199271).with('selfid', -404041766).with('textdescid', -634935376).with('uniqueparentid', 0).with('classresourceid', -1930775675)
.with('uitreeindex', 7)
.with('classname', 'TextView')
.with('resource-id', 'android:id/summary')
.with('text', 'Connected')
$ruiObj.isExist
waitsecond(1)
end
tcase << TestAction.new(:scriptAction_23_TrueFalse) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason == "WiFi cannot connected"
end
logStopTest("05_01_10_02_WiFi")
end
tcase << TestAction.new(:Switch_OFF_19_1) do
$ruiObj = RUIObject.new.with('objectid', 1178284996).with('selfid', -533646533).with('textdescid', -1104515187).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'Switch')
.with('text', 'OFF')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:pressBack_15) do
pressBack
end
tcase << TestAction.new(:pressBack_16) do
pressBack
end
tcase << TestAction.new(:pressHome_17) do
pressHome
end
tcase.run(loopTime)
end
def self.android_ExpHandler(loopTime)
tcase = TestCase.new("android_ExpHandler")
tcase << TestAction.new(:scriptAction_check) do
$err = "system popup detected::#{takeScreenShot}::screenshot saved"
$myTestResult = false
puts $err
logcat($err)
writelog($err)
uiObj("Button").click if uiObj("Button").exists
waitsecond(2)
end
tcase.run(loopTime)
end
def self.change_3G(loopTime)
tcase = TestCase.new("change_3G")
tcase << TestAction.new(:gotoApp_16) do
gotoApp('HiddenMenuCall')
end
tcase << TestAction.new(:TextView_Title_2) do
$ruiObj = RUIObject.new.with('objectid', 1100751325).with('selfid', -167282287).with('textdescid', -350417171).with('uniqueparentid', 0).with('classresourceid', 490183159)
.with('uitreeindex', 1)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'LG Hidden Menu')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_87) do
$ruiObj = RUIObject.new.with('objectid', 684902757).with('selfid', 538152793).with('textdescid', -1915478867).with('uniqueparentid', 0).with('classresourceid', 490183159)
.with('uitreeindex', 4)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'Field Test')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Text1_10) do
$ruiObj = RUIObject.new.with('objectid', -483333610).with('selfid', -141259386).with('textdescid', -734720867).with('uniqueparentid', 0).with('classresourceid', 490068035)
.with('uitreeindex', 1)
.with('classname', 'TextView')
.with('resource-id', 'android:id/text1')
.with('text', 'Modem Settings')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:swipeDown_12) do
swipe_vertical 500
waitsecond(1)
end
tcase << TestAction.new(:TextView_Text1_14) do
$ruiObj = RUIObject.new.with('objectid', -483333610).with('selfid', 12767364).with('textdescid', 1760273017).with('uniqueparentid', 0).with('classresourceid', 490068035)
.with('uitreeindex', 6)
.with('classname', 'TextView')
.with('resource-id', 'android:id/text1')
.with('text', 'RAT Selection')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Text1_2) do
$ruiObj = RUIObject.new.with('objectid', -483333610).with('selfid', -244179464).with('textdescid', 496935915).with('uniqueparentid', 0).with('classresourceid', 490068035)
.with('uitreeindex', 5)
.with('classname', 'TextView')
.with('resource-id', 'android:id/text1')
.with('text', 'GSM WCDMA')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_Button1_18) do
$ruiObj = RUIObject.new.with('objectid', 2089308220).with('selfid', -1318451484).with('textdescid', 1664978912).with('uniqueparentid', 0)
.with('uitreeindex', 1)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'OK')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:pressBack_7) do
pressBack
end
tcase << TestAction.new(:pressBack_8) do
pressBack
end
tcase << TestAction.new(:pressBack_20) do
pressBack
end
tcase << TestAction.new(:pressBack_20_1) do
pressBack
end
tcase << TestAction.new(:pressHome_9) do
pressHome
end
tcase.run(loopTime)
end
def self.change_LTE(loopTime)
tcase = TestCase.new("change_LTE")
tcase << TestAction.new(:gotoApp_16_1) do
gotoApp('HiddenMenuCall')
end
tcase << TestAction.new(:TextView_Title_3) do
$ruiObj = RUIObject.new.with('objectid', 1100751325).with('selfid', -167282287).with('textdescid', -350417171).with('uniqueparentid', 0).with('classresourceid', 490183159)
.with('uitreeindex', 1)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'LG Hidden Menu')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_87) do
$ruiObj = RUIObject.new.with('objectid', 684902757).with('selfid', 538152793).with('textdescid', -1915478867).with('uniqueparentid', 0).with('classresourceid', 490183159)
.with('uitreeindex', 4)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'Field Test')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Text1_10) do
$ruiObj = RUIObject.new.with('objectid', -483333610).with('selfid', -141259386).with('textdescid', -734720867).with('uniqueparentid', 0).with('classresourceid', 490068035)
.with('uitreeindex', 1)
.with('classname', 'TextView')
.with('resource-id', 'android:id/text1')
.with('text', 'Modem Settings')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:swipeDown_12) do
swipe_vertical 500
waitsecond(1)
end
tcase << TestAction.new(:TextView_Text1_14) do
$ruiObj = RUIObject.new.with('objectid', -483333610).with('selfid', 12767364).with('textdescid', 1760273017).with('uniqueparentid', 0).with('classresourceid', 490068035)
.with('uitreeindex', 6)
.with('classname', 'TextView')
.with('resource-id', 'android:id/text1')
.with('text', 'RAT Selection')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Text1_2) do
$ruiObj = RUIObject.new.with('objectid', -483333610).with('selfid', 747569194).with('textdescid', -1653100487).with('uniqueparentid', 0).with('classresourceid', 490068035)
.with('uitreeindex', 1)
.with('classname', 'TextView')
.with('resource-id', 'android:id/text1')
.with('text', 'GSM WCDMA LTE auto')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:Button_Button1_18) do
$ruiObj = RUIObject.new.with('objectid', 2089308220).with('selfid', -1318451484).with('textdescid', 1664978912).with('uniqueparentid', 0)
.with('uitreeindex', 1)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'OK')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:pressBack_7) do
pressBack
end
tcase << TestAction.new(:pressBack_8) do
pressBack
end
tcase << TestAction.new(:pressBack_20) do
pressBack
end
tcase << TestAction.new(:pressBack_20_1) do
pressBack
end
tcase << TestAction.new(:pressHome_9) do
pressHome
end
tcase.run(loopTime)
end
def self.connectWifi(loopTime)
tcase = TestCase.new("connectWifi")
tcase << TestAction.new(:scriptAction_2) do
logStartTest("Connect_to_wifi")
end
tcase << TestAction.new(:gotoApp_4) do
gotoApp('Settings')
end
tcase << TestAction.new(:TextView_Title_27) do
$ruiObj = RUIObject.new.with('objectid', 674368800).with('selfid', -2078686330).with('textdescid', -957350501).with('uniqueparentid', 0)
.with('uitreeindex', 3)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'Networks')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:swipeUp_8) do
swipe_vertical_back 500
end
tcase << TestAction.new(:TextView_Title_4) do
$ruiObj = RUIObject.new.with('objectid', 2008023572).with('selfid', -589731018).with('textdescid', 498664031).with('uniqueparentid', 0).with('classresourceid', 490183159)
.with('uitreeindex', 9)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'WiFi')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:ImageView_Icon_6) do
$ruiObj = RUIObject.new.with('objectid', -1337042610).with('selfid', -1580627678).with('textdescid', 1501352082).with('uniqueparentid', 0).with('classresourceid', -858811928)
.with('uitreeindex', 10)
.with('pretext', 'Searching')
.with('classname', 'ImageView')
.with('resource-id', 'android:id/icon')
$ruiObj.isNotExist
ifFailJumpTo(:TextView_Title_10)
waitsecond(1)
end
tcase << TestAction.new(:Switch_ON_8) do
$ruiObj = RUIObject.new.with('objectid', 1178284996).with('selfid', 1645353587).with('textdescid', -1975291963).with('uniqueparentid', 0)
.with('uitreeindex', 2)
.with('classname', 'Switch')
.with('text', 'ON')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_10) do
$ruiObj = RUIObject.new.with('objectid', 1034430516).with('selfid', -71636208).with('textdescid', -1976912357).with('uniqueparentid', 0).with('classresourceid', 490183159)
.with('uitreeindex', 9)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'QCTCOMP')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:EditText_Password_12) do
$ruiObj = RUIObject.new.with('objectid', -976316462).with('selfid', -2120332491).with('textdescid', -201039218).with('uniqueparentid', 0).with('classresourceid', -714852383)
.with('uitreeindex', 2)
.with('classname', 'EditText')
.with('resource-id', 'com.lge.wifisettings:id/password')
$ruiObj.inputtext('12abcdef34')
waitsecond(1)
end
tcase << TestAction.new(:Button_Button1_14) do
$ruiObj = RUIObject.new.with('objectid', -360890210).with('selfid', 736098498).with('textdescid', 503413208).with('uniqueparentid', 0)
.with('uitreeindex', 6)
.with('classname', 'Button')
.with('resource-id', 'android:id/button1')
.with('text', 'Connect')
$ruiObj.click
waitsecond(4)
end
tcase << TestAction.new(:TextView_Summary_16) do
$ruiObj = RUIObject.new.with('objectid', 1399891586).with('selfid', -404041766).with('textdescid', 623785653).with('uniqueparentid', 0).with('classresourceid', -1930775675)
.with('uitreeindex', 10)
.with('classname', 'TextView')
.with('resource-id', 'android:id/summary')
.with('text', 'Connected')
$ruiObj.isExist
end
tcase << TestAction.new(:scriptAction_23_TrueFalse) do
$myTestResult = checkLastExistResult
if $myTestResult == false
$myFailReason == "WiFi cannot connected"
end
logStopTest("Connect_to_wifi")
end
tcase << TestAction.new(:pressBack_15) do
pressBack
end
tcase << TestAction.new(:pressBack_16) do
pressBack
end
tcase << TestAction.new(:pressHome_17) do
pressHome
end
tcase.run(loopTime)
end
def self.enhanced_LTE_service(loopTime)
tcase = TestCase.new("enhanced_LTE_service")
tcase << TestAction.new(:pressHome_1) do
pressHome
waitsecond(2)
end
tcase << TestAction.new(:gotoApp_5_1) do
gotoApp('Settings')
waitsecond(1)
end
tcase << TestAction.new(:TextView_Title_2) do
$ruiObj = RUIObject.new.with('objectid', 10212784).with('selfid', -2078686330).with('textdescid', 1550078507).with('uniqueparentid', 0)
.with('uitreeindex', 5)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'Networks')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:swipeDown_3) do
swipe_vertical 500
waitsecond(2)
end
tcase << TestAction.new(:TextView_Title_5) do
$ruiObj = RUIObject.new.with('objectid', -2099539841).with('selfid', -590021802).with('textdescid', -1389148054).with('uniqueparentid', 0).with('classresourceid', 490183159)
.with('uitreeindex', 34)
.with('classname', 'TextView')
.with('resource-id', 'android:id/title')
.with('text', 'More')
$ruiObj.click
waitsecond(2)
end
tcase << TestAction.new(:Switch_SwitchWidget_7) do
$ruiObj = RUIObject.new.with('objectid', -1128160036).with('selfid', -1798770950).with('textdescid', -613222716).with('uniqueparentid', 0).with('classresourceid', -205276468)
.with('uitreeindex', 4)
.with('classname', 'Switch')
.with('resource-id', 'android:id/switch_widget')
$ruiObj.click
waitsecond(2)
end
tcase.run(loopTime)
end
def self.Telephony_05_01_01_01(loopTime)
tcase = TestCase.new("Telephony_05_01_01_01")
tcase << TestAction.new(:scriptAction_StartTest_1) do
logStartTest("05_01_01_01_Telephony")
end
tcase << TestAction.new(:pressHome_4) do
pressHome
end
tcase << TestAction.new(:TextView_Phone_2) do
$ruiObj = RUIObject.new.with('objectid', -479243074).with('selfid', 1134672426).with('textdescid', 1322329030).with('uniqueparentid', 0)
.with('uitreeindex', 9)
.with('classname', 'TextView')
.with('content-desc', 'Phone')
.with('text', 'Phone')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:TextView_Tabtext_2) do
$ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 1015283306).with('textdescid', -1384079800).with('uniqueparentid', 0)
.with('uitreeindex', 4)
.with('classname', 'TextView')
.with('resource-id', 'com.android.contacts:id/tabText')
.with('text', 'Contacts')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:EditText_SearchSrcText_4) do
$ruiObj = RUIObject.new.with('objectid', 588070375).with('selfid', -959326622).with('textdescid', -497243406).with('uniqueparentid', 0)
.with('uitreeindex', 6)
.with('classname', 'EditText')
.with('resource-id', 'android:id/search_src_text')
.with('content-desc', 'Search contacts')
$ruiObj.inputtext('A01')
waitsecond(1)
end
tcase << TestAction.new(:ImageView_Button1_8) do
$ruiObj = RUIObject.new.with('objectid', -1827607533).with('selfid', 643737864).with('textdescid', -306619761).with('uniqueparentid', 0).with('classresourceid', -1143292048)
.with('uitreeindex', 13)
.with('classname', 'ImageView')
.with('resource-id', 'android:id/button1')
.with('content-desc', 'Call A01 a01')
$ruiObj.click
waitsecond(4)
end
tcase << TestAction.new(:wait8second_31) do
waitsecond(12)
end
tcase << TestAction.new(:scriptAction_10) do
sendBTCmd('answerCall')
waitsecond(8)
end
tcase << TestAction.new(:scriptAction_10_1) do
if rand(100) < 0
sendBTCmd('endCall')
waitsecond(1)
end
end
tcase << TestAction.new(:scriptAction_LogStopTest_1_1) do
$myTestResult = checkLastBTCmdResult
if $myTestResult == false
$myFailReason = "Call not come to other dev"
end
logStopTest("05_01_01_01_Telephony")
end
tcase << TestAction.new(:Button_Endbutton_2) do
$ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
.with('uitreeindex', 8)
.with('classname', 'Button')
.with('resource-id', 'com.android.incallui:id/endButton')
.with('text', 'End')
$ruiObj.click
waitsecond(1)
end
tcase << TestAction.new(:pressBack_3) do
pressBack
end
tcase << TestAction.new(:pressBack_4) do
pressBack
end
tcase.run(loopTime)
end
def self.startTest(loopTime)
tcase = TestCase.new("startTest")
tcase << TestAction.new(:pressBack_1) do
pressBack
end
tcase << TestAction.new(:pressBack_2) do
pressBack
end
tcase << TestAction.new(:pressHome_3) do
pressHome
end
tcase << TestAction.new(:pressRecentApps_2) do
pressRecentApps
waitsecond(2)
end
tcase << TestAction.new(:pressHome_4) do
pressHome
waitsecond(2)
end
tcase.run(loopTime)
end
def self.exception_handler
puts "Module Exception Hanlder..."
if ($lastPackageName == "android")
android_ExpHandler(1)
end
end
def self.run(loop)
mainLoop loop
end
end
$exceptionPackageNameList = []
$exceptionPackageNameList_exclude = []
$exceptionPackageNameList << "android"
def exception_handler
DIVA_MTBF_SPR.exception_handler
end
$curProjectLogFile = $useLastLogFile
$curProjectLogFile = "DIVA_MTBF_SPR_#{getTimeStamp}.log" if $useLastLogFile.nil?
$useLastLogFile = nil
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment