Advertisement
Guest User

Untitled

a guest
Sep 7th, 2017
551
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 227.71 KB | None | 0 0
  1. loadTestDB
  2.  
  3. module JOAN_MTBF
  4.  
  5. def self.Browser_05_01_04_01(loopTime)
  6.  
  7. tcase = TestCase.new("Browser_05_01_04_01")
  8.  
  9. tcase << TestAction.new(:scriptAction_2) do
  10. logStartTest("Browser_05_01_04_01")
  11. end
  12.  
  13. tcase << TestAction.new(:gotoApp_2) do
  14. gotoApp('Chrome')
  15. end
  16.  
  17. tcase << TestAction.new(:Button_TermsAccept_6) do
  18. $ruiObj = RUIObject.new.with('objectid', 1131623741).with('selfid', 2073999009).with('textdescid', -212510162).with('uniqueparentid', 0)
  19. .with('uitreeindex', 4)
  20. .with('classname', 'Button')
  21. .with('resource-id', 'com.android.chrome:id/terms_accept')
  22. .with('text', 'ACCEPT CONTINUE')
  23.  
  24. $ruiObj.click
  25.  
  26. waitsecond(1)
  27. end
  28.  
  29. tcase << TestAction.new(:Button_PositiveButton_8_1) do
  30. $ruiObj = RUIObject.new.with('objectid', -1302979962).with('selfid', -1854494819).with('textdescid', 1350385207).with('uniqueparentid', 0)
  31. .with('uitreeindex', 10)
  32. .with('classname', 'Button')
  33. .with('resource-id', 'com.android.chrome:id/positive_button')
  34. .with('text', 'OK GOT IT')
  35.  
  36. $ruiObj.isExist
  37. ifFailJumpTo(:EditText_UrlBar_24)
  38.  
  39. waitsecond(1)
  40. end
  41.  
  42. tcase << TestAction.new(:swipeDown_2) do
  43. swipe_vertical 500
  44.  
  45. waitsecond(2)
  46. end
  47.  
  48. tcase << TestAction.new(:Button_PositiveButton_8) do
  49. $ruiObj = RUIObject.new.with('objectid', -1302979962).with('selfid', -1854494819).with('textdescid', 1350385207).with('uniqueparentid', 0)
  50. .with('uitreeindex', 10)
  51. .with('classname', 'Button')
  52. .with('resource-id', 'com.android.chrome:id/positive_button')
  53. .with('text', 'OK GOT IT')
  54.  
  55. $ruiObj.click
  56.  
  57. waitsecond(1)
  58. end
  59.  
  60. tcase << TestAction.new(:EditText_UrlBar_24) do
  61. $ruiObj = RUIObject.new.with('objectid', 882195433).with('selfid', 613381324).with('textdescid', 1578254679).with('uniqueparentid', 0)
  62. .with('uitreeindex', 138)
  63. .with('classname', 'EditText')
  64. .with('resource-id', 'com.android.chrome:id/url_bar')
  65.  
  66. $ruiObj.click
  67.  
  68. waitsecond(1)
  69. end
  70.  
  71. tcase << TestAction.new(:EditText_UrlBar_2) do
  72. $ruiObj = RUIObject.new.with('objectid', 882195433).with('selfid', 613381324).with('textdescid', 1578254679).with('uniqueparentid', 0)
  73. .with('uitreeindex', 21)
  74. .with('classname', 'EditText')
  75. .with('resource-id', 'com.android.chrome:id/url_bar')
  76.  
  77. $ruiObj.inputtext('m.att.com')
  78.  
  79. waitsecond(1)
  80. end
  81.  
  82. tcase << TestAction.new(:pressEnter_5) do
  83. pressEnter
  84.  
  85. waitsecond(2)
  86. end
  87.  
  88. tcase << TestAction.new(:wait4second_2) do
  89. waitsecond(4)
  90. end
  91.  
  92. tcase << TestAction.new(:scriptAction_1_1) do
  93. $reload = RUIObject.new.with('objectid', -1298956826).with('selfid', 1403544531).with('textdescid', 1877548115).with('uniqueparentid', 0)
  94. .with('uitreeindex', 4)
  95. .with('classname', 'Button')
  96. .with('resource-id', 'reload-button')
  97. .with('content-desc', 'RELOAD').exists?
  98.  
  99. $progressBar = RUIObject.new.with('objectid', 1158061653).with('selfid', 1366906829).with('textdescid', 1540172907).with('uniqueparentid', 0)
  100. .with('uitreeindex', 18)
  101. .with('classname', 'ImageView')
  102. .with('resource-id', 'com.android.chrome:id/progress').exists?
  103.  
  104. if ($progressBar || $reload) == true
  105. $myTestResult = false
  106. else
  107. $myTestResult = true
  108. end
  109. if $myTestResult == false
  110. $myFailReason = "Page not loaded."
  111. end
  112. logStopTest("Browser_05_01_04_01")
  113. end
  114.  
  115. tcase << TestAction.new(:pressBack_1) do
  116. pressBack
  117. end
  118.  
  119. tcase << TestAction.new(:pressHome_1) do
  120. pressHome
  121. end
  122.  
  123. tcase.run(loopTime)
  124.  
  125. end
  126.  
  127. def self.Browser_05_01_04_02(loopTime)
  128.  
  129. tcase = TestCase.new("Browser_05_01_04_02")
  130.  
  131. tcase << TestAction.new(:scriptAction_2_1) do
  132. logStartTest("Browser_05_01_04_02")
  133. end
  134.  
  135. tcase << TestAction.new(:gotoApp_21) do
  136. gotoApp('Chrome')
  137. end
  138.  
  139. tcase << TestAction.new(:EditText_UrlBar_2) do
  140. $ruiObj = RUIObject.new.with('objectid', 882195433).with('selfid', 613381324).with('textdescid', 1578254679).with('uniqueparentid', 0)
  141. .with('uitreeindex', 40)
  142. .with('classname', 'EditText')
  143. .with('resource-id', 'com.android.chrome:id/url_bar')
  144.  
  145. $ruiObj.click
  146.  
  147. waitsecond(1)
  148. end
  149.  
  150. tcase << TestAction.new(:EditText_UrlBar_2_1) do
  151. $ruiObj = RUIObject.new.with('objectid', 882195433).with('selfid', 613381324).with('textdescid', 1578254679).with('uniqueparentid', 0)
  152. .with('uitreeindex', 40)
  153. .with('classname', 'EditText')
  154. .with('resource-id', 'com.android.chrome:id/url_bar')
  155.  
  156. $ruiObj.inputtext('www.naver.com')
  157.  
  158. waitsecond(1)
  159. end
  160.  
  161. tcase << TestAction.new(:pressEnter_6) do
  162. pressEnter
  163.  
  164. waitsecond(4)
  165. end
  166.  
  167. tcase << TestAction.new(:clickXY_154_500_3) do
  168. click(154,500)
  169.  
  170. waitsecond(4)
  171. end
  172.  
  173. tcase << TestAction.new(:swipeDown_9) do
  174. swipe_vertical 500
  175. end
  176.  
  177. tcase << TestAction.new(:scriptAction_1_1_1) do
  178. $reload = RUIObject.new.with('objectid', -1298956826).with('selfid', 1403544531).with('textdescid', 1877548115).with('uniqueparentid', 0)
  179. .with('uitreeindex', 4)
  180. .with('classname', 'Button')
  181. .with('resource-id', 'reload-button')
  182. .with('content-desc', 'RELOAD').exists?
  183.  
  184. $progressBar = RUIObject.new.with('objectid', 1158061653).with('selfid', 1366906829).with('textdescid', 1540172907).with('uniqueparentid', 0)
  185. .with('uitreeindex', 18)
  186. .with('classname', 'ImageView')
  187. .with('resource-id', 'com.android.chrome:id/progress').exists?
  188.  
  189. if ($progressBar || $reload) == true
  190. $myTestResult = false
  191. else
  192. $myTestResult = true
  193. end
  194. if $myTestResult == false
  195. $myFailReason = "Page not loaded."
  196. end
  197. logStopTest("Browser_05_01_04_01")
  198. end
  199.  
  200. tcase << TestAction.new(:pressBack_10) do
  201. pressBack
  202. end
  203.  
  204. tcase << TestAction.new(:pressBack_1) do
  205. pressBack
  206. end
  207.  
  208. tcase << TestAction.new(:pressHome_4) do
  209. pressHome
  210. end
  211.  
  212. tcase.run(loopTime)
  213.  
  214. end
  215.  
  216. def self.Browser_05_01_04_03(loopTime)
  217.  
  218. tcase = TestCase.new("Browser_05_01_04_03")
  219.  
  220. tcase << TestAction.new(:scriptAction_2_1_1_1) do
  221. logStartTest("Browser_05_01_04_03")
  222. end
  223.  
  224. tcase << TestAction.new(:gotoApp_2) do
  225. gotoApp('Chrome')
  226. end
  227.  
  228. tcase << TestAction.new(:EditText_UrlBar_27) do
  229. $ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
  230. .with('uitreeindex', 2)
  231. .with('classname', 'EditText')
  232. .with('resource-id', 'com.android.chrome:id/url_bar')
  233.  
  234. $ruiObj.click
  235. noFailCheck
  236.  
  237. waitsecond(1)
  238. end
  239.  
  240. tcase << TestAction.new(:EditText_UrlBar_27_1) do
  241. $ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
  242. .with('uitreeindex', 2)
  243. .with('classname', 'EditText')
  244. .with('resource-id', 'com.android.chrome:id/url_bar')
  245.  
  246. $ruiObj.inputtext('www.ebay.com')
  247. noFailCheck
  248.  
  249. waitsecond(1)
  250. end
  251.  
  252. tcase << TestAction.new(:pressEnter_10) do
  253. pressEnter
  254.  
  255. waitsecond(4)
  256. end
  257.  
  258. tcase << TestAction.new(:EditText_UrlBar_27_1) do
  259. $ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
  260. .with('uitreeindex', 2)
  261. .with('classname', 'EditText')
  262. .with('resource-id', 'com.android.chrome:id/url_bar')
  263.  
  264. $ruiObj.click
  265. noFailCheck
  266.  
  267. waitsecond(1)
  268. end
  269.  
  270. tcase << TestAction.new(:EditText_UrlBar_4) do
  271. $ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
  272. .with('uitreeindex', 2)
  273. .with('classname', 'EditText')
  274. .with('resource-id', 'com.android.chrome:id/url_bar')
  275.  
  276. $ruiObj.inputtext('www.yahoo.com')
  277. noFailCheck
  278.  
  279. waitsecond(1)
  280. end
  281.  
  282. tcase << TestAction.new(:pressEnter_12) do
  283. pressEnter
  284.  
  285. waitsecond(4)
  286. end
  287.  
  288. tcase << TestAction.new(:EditText_UrlBar_27_1_1) do
  289. $ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
  290. .with('uitreeindex', 2)
  291. .with('classname', 'EditText')
  292. .with('resource-id', 'com.android.chrome:id/url_bar')
  293.  
  294. $ruiObj.click
  295. noFailCheck
  296.  
  297. waitsecond(1)
  298. end
  299.  
  300. tcase << TestAction.new(:EditText_UrlBar_5) do
  301. $ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
  302. .with('uitreeindex', 2)
  303. .with('classname', 'EditText')
  304. .with('resource-id', 'com.android.chrome:id/url_bar')
  305.  
  306. $ruiObj.inputtext('www.amazon.com')
  307. noFailCheck
  308.  
  309. waitsecond(1)
  310. end
  311.  
  312. tcase << TestAction.new(:pressEnter_14) do
  313. pressEnter
  314.  
  315. waitsecond(4)
  316. end
  317.  
  318. tcase << TestAction.new(:EditText_UrlBar_27_1_1_1) do
  319. $ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
  320. .with('uitreeindex', 2)
  321. .with('classname', 'EditText')
  322. .with('resource-id', 'com.android.chrome:id/url_bar')
  323.  
  324. $ruiObj.click
  325. noFailCheck
  326.  
  327. waitsecond(1)
  328. end
  329.  
  330. tcase << TestAction.new(:EditText_UrlBar_3) do
  331. $ruiObj = RUIObject.new.with('objectid', 882195433).with('selfid', 613381324).with('textdescid', 1578254679).with('uniqueparentid', 0)
  332. .with('uitreeindex', 177)
  333. .with('classname', 'EditText')
  334. .with('resource-id', 'com.android.chrome:id/url_bar')
  335.  
  336. $ruiObj.inputtext('www.youtube.com')
  337.  
  338. waitsecond(1)
  339. end
  340.  
  341. tcase << TestAction.new(:pressEnter_16) do
  342. pressEnter
  343.  
  344. waitsecond(4)
  345. end
  346.  
  347. tcase << TestAction.new(:EditText_UrlBar_27_1_1_1_1) do
  348. $ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
  349. .with('uitreeindex', 2)
  350. .with('classname', 'EditText')
  351. .with('resource-id', 'com.android.chrome:id/url_bar')
  352.  
  353. $ruiObj.click
  354. noFailCheck
  355.  
  356. waitsecond(1)
  357. end
  358.  
  359. tcase << TestAction.new(:EditText_UrlBar_7) do
  360. $ruiObj = RUIObject.new.with('objectid', 1651866124).with('selfid', 613381324).with('textdescid', -331757676).with('uniqueparentid', 0)
  361. .with('uitreeindex', 2)
  362. .with('classname', 'EditText')
  363. .with('resource-id', 'com.android.chrome:id/url_bar')
  364.  
  365. $ruiObj.inputtext('www.nytimes.com')
  366. noFailCheck
  367.  
  368. waitsecond(1)
  369. end
  370.  
  371. tcase << TestAction.new(:pressEnter_18) do
  372. pressEnter
  373.  
  374. waitsecond(4)
  375. end
  376.  
  377. tcase << TestAction.new(:wait2second_2) do
  378. waitsecond(2)
  379. end
  380.  
  381. tcase << TestAction.new(:scriptAction_1_1_1_1) do
  382. $reload = RUIObject.new.with('objectid', -1298956826).with('selfid', 1403544531).with('textdescid', 1877548115).with('uniqueparentid', 0)
  383. .with('uitreeindex', 4)
  384. .with('classname', 'Button')
  385. .with('resource-id', 'reload-button')
  386. .with('content-desc', 'RELOAD').exists?
  387.  
  388. $progressBar = RUIObject.new.with('objectid', 1158061653).with('selfid', 1366906829).with('textdescid', 1540172907).with('uniqueparentid', 0)
  389. .with('uitreeindex', 18)
  390. .with('classname', 'ImageView')
  391. .with('resource-id', 'com.android.chrome:id/progress').exists?
  392.  
  393. if ($progressBar || $reload) == true
  394. $myTestResult = false
  395. else
  396. $myTestResult = true
  397. end
  398. if $myTestResult == false
  399. $myFailReason = "Page not loaded."
  400. end
  401. logStopTest("Browser_05_01_04_01")
  402. end
  403.  
  404. tcase << TestAction.new(:pressHome_8) do
  405. pressHome
  406. end
  407.  
  408. tcase.run(loopTime)
  409.  
  410. end
  411.  
  412. def self.Email_05_01_03_01(loopTime)
  413.  
  414. tcase = TestCase.new("Email_05_01_03_01")
  415.  
  416. tcase << TestAction.new(:pressHome_2) do
  417. pressHome
  418. end
  419.  
  420. tcase << TestAction.new(:scriptAction_12_1) do
  421. logStartTest("Email_05_01_03_01")
  422. end
  423.  
  424. tcase << TestAction.new(:gotoApp_3) do
  425. gotoApp('Email')
  426. end
  427.  
  428. tcase << TestAction.new(:ImageView_Img1_2) do
  429. $ruiObj = RUIObject.new.with('objectid', 577677288).with('selfid', 1832242753).with('textdescid', 1040024250).with('uniqueparentid', 0)
  430. .with('uitreeindex', 13)
  431. .with('classname', 'ImageView')
  432. .with('resource-id', 'com.lge.email:id/img1')
  433. .with('content-desc', 'Compose')
  434.  
  435. $ruiObj.click
  436.  
  437. waitsecond(1)
  438. end
  439.  
  440. tcase << TestAction.new(:clickXY_284_388_4) do
  441. click(284,388)
  442.  
  443. waitsecond(1)
  444. end
  445.  
  446. tcase << TestAction.new(:EditText_To_7) do
  447. $ruiObj = RUIObject.new.with('objectid', 949433449).with('selfid', -182898776).with('textdescid', -900253096).with('uniqueparentid', 0).with('classresourceid', 1666676343)
  448. .with('uitreeindex', 5)
  449. .with('pretext', 'To')
  450. .with('classname', 'EditText')
  451. .with('content-desc', 'To: ')
  452.  
  453. $ruiObj.inputtext('dvgats1@gmail.com')
  454. end
  455.  
  456. tcase << TestAction.new(:pressEnter_3) do
  457. pressEnter
  458. end
  459.  
  460. tcase << TestAction.new(:EditText_Txtemailsubject_6) do
  461. $ruiObj = RUIObject.new.with('objectid', 1286174050).with('selfid', -1018848110).with('textdescid', 1216689918).with('uniqueparentid', 1959895911).with('classresourceid', 386631998)
  462. .with('uitreeindex', 11)
  463. .with('classname', 'EditText')
  464. .with('resource-id', 'com.lge.email:id/txtEmailSubject')
  465.  
  466. $ruiObj.inputtext('Email Test')
  467.  
  468. waitsecond(1)
  469. end
  470.  
  471. tcase << TestAction.new(:clickXY_116_908_2) do
  472. click(116,908)
  473. end
  474.  
  475. tcase << TestAction.new(:View_EditBox_13_1) do
  476. $ruiObj = RUIObject.new.with('objectid', 134611444).with('selfid', 1661648749).with('textdescid', 1161931405).with('uniqueparentid', -2001114113).with('classresourceid', -760537482)
  477. .with('uitreeindex', 12)
  478. .with('pretext', 'CcBcc')
  479. .with('classname', 'android.view.View')
  480. .with('resource-id', 'EditBox')
  481. .with('content-desc', '
  482.  
  483. Sent from my LG Mobile')
  484.  
  485. $ruiObj.click
  486. end
  487.  
  488. tcase << TestAction.new(:scriptAction_14) do
  489. $ruiObj.inputtext('Testing UiEngine Email Test!!!')
  490. end
  491.  
  492. tcase << TestAction.new(:Button_BtnsendAtnt_2) do
  493. $ruiObj = RUIObject.new.with('objectid', 1747678584).with('selfid', 1651854553).with('textdescid', 36858568).with('uniqueparentid', 0)
  494. .with('uitreeindex', 16)
  495. .with('classname', 'Button')
  496. .with('resource-id', 'com.lge.email:id/btnSend_atnt')
  497. .with('content-desc', 'Send')
  498. .with('text', 'SEND')
  499.  
  500. $ruiObj.click
  501.  
  502. waitsecond(2)
  503. end
  504.  
  505. tcase << TestAction.new(:ImageView_Img1_18) do
  506. $ruiObj = RUIObject.new.with('objectid', 577677288).with('selfid', 1832242753).with('textdescid', 1040024250).with('uniqueparentid', 0)
  507. .with('uitreeindex', 13)
  508. .with('classname', 'ImageView')
  509. .with('resource-id', 'com.lge.email:id/img1')
  510. .with('content-desc', 'Compose')
  511.  
  512. $ruiObj.isExist
  513.  
  514. waitsecond(2)
  515. end
  516.  
  517. tcase << TestAction.new(:ImageView_Slidedrawerimg_20) do
  518. $ruiObj = RUIObject.new.with('objectid', -431894634).with('selfid', -1542033050).with('textdescid', -503831734).with('uniqueparentid', 0)
  519. .with('uitreeindex', 0)
  520. .with('classname', 'ImageView')
  521. .with('resource-id', 'com.lge.email:id/slidedrawerimg')
  522.  
  523. $ruiObj.click
  524. end
  525.  
  526. tcase << TestAction.new(:TextView_DrawerChildName_22) do
  527. $ruiObj = RUIObject.new.with('objectid', 2119189077).with('selfid', 232899905).with('textdescid', -1453017635).with('uniqueparentid', 0)
  528. .with('uitreeindex', 19)
  529. .with('classname', 'TextView')
  530. .with('resource-id', 'com.lge.email:id/drawer_child_name')
  531. .with('text', 'Sent')
  532.  
  533. $ruiObj.click
  534.  
  535. waitsecond(1)
  536. end
  537.  
  538. tcase << TestAction.new(:clickXY_516_516_24) do
  539. click(516,516)
  540.  
  541. waitsecond(1)
  542. end
  543.  
  544. tcase << TestAction.new(:Button_Btnatntbottomdelete_4) do
  545. $ruiObj = RUIObject.new.with('objectid', -2098725759).with('selfid', 480632483).with('textdescid', 1124287286).with('uniqueparentid', 0)
  546. .with('uitreeindex', 18)
  547. .with('classname', 'Button')
  548. .with('resource-id', 'com.lge.email:id/btnAtntBottomDelete')
  549. .with('text', 'DELETE')
  550.  
  551. $ruiObj.click
  552.  
  553. waitsecond(2)
  554. end
  555.  
  556. tcase << TestAction.new(:Delete_Confirm_Button1_6) do
  557. $ruiObj = RUIObject.new.with('objectid', 892548796).with('selfid', 982364851).with('textdescid', 658117233).with('uniqueparentid', 0)
  558. .with('uitreeindex', 3)
  559. .with('classname', 'Button')
  560. .with('resource-id', 'android:id/button1')
  561. .with('text', 'DELETE')
  562.  
  563. $ruiObj.click
  564.  
  565. waitsecond(2)
  566. end
  567.  
  568. tcase << TestAction.new(:scriptAction_8) do
  569. $myTestResult = checkLastExistResult
  570.  
  571. if $myTestResult == false
  572. $myFailReason = "Email not sent"
  573. end
  574. logStopTest("Email_05_01_03_01")
  575. end
  576.  
  577. tcase << TestAction.new(:pressBack_3) do
  578. pressBack
  579. end
  580.  
  581. tcase << TestAction.new(:pressBack_4) do
  582. pressBack
  583. end
  584.  
  585. tcase.run(loopTime)
  586.  
  587. end
  588.  
  589. def self.Email_05_01_03_02(loopTime)
  590.  
  591. tcase = TestCase.new("Email_05_01_03_02")
  592.  
  593. tcase << TestAction.new(:scriptAction_12) do
  594. logStartTest("Email_05_01_03_02")
  595. end
  596.  
  597. tcase << TestAction.new(:gotoApp_3) do
  598. gotoApp('Email')
  599. end
  600.  
  601. tcase << TestAction.new(:ImageView_Img1_2) do
  602. $ruiObj = RUIObject.new.with('objectid', 577677288).with('selfid', 1832242753).with('textdescid', 1040024250).with('uniqueparentid', 0)
  603. .with('uitreeindex', 13)
  604. .with('classname', 'ImageView')
  605. .with('resource-id', 'com.lge.email:id/img1')
  606. .with('content-desc', 'Compose')
  607.  
  608. $ruiObj.click
  609.  
  610. waitsecond(1)
  611. end
  612.  
  613. tcase << TestAction.new(:EditText_To_2) do
  614. $ruiObj = RUIObject.new.with('objectid', 949433449).with('selfid', -182898776).with('textdescid', -900253096).with('uniqueparentid', 0).with('classresourceid', 1666676343)
  615. .with('uitreeindex', 6)
  616. .with('pretext', 'To')
  617. .with('classname', 'EditText')
  618. .with('content-desc', 'To: ')
  619.  
  620. $ruiObj.inputtext('dvgats1@gmail.com')
  621. end
  622.  
  623. tcase << TestAction.new(:pressEnter_3) do
  624. pressEnter
  625. end
  626.  
  627. tcase << TestAction.new(:EditText_Txtemailsubject_6) do
  628. $ruiObj = RUIObject.new.with('objectid', 1286174050).with('selfid', -1018848110).with('textdescid', 1216689918).with('uniqueparentid', 1959895911).with('classresourceid', 386631998)
  629. .with('uitreeindex', 11)
  630. .with('classname', 'EditText')
  631. .with('resource-id', 'com.lge.email:id/txtEmailSubject')
  632.  
  633. $ruiObj.inputtext('Email Test')
  634.  
  635. waitsecond(1)
  636. end
  637.  
  638. tcase << TestAction.new(:clickXY_96_920_2) do
  639. click(96,920)
  640.  
  641. waitsecond(1)
  642. end
  643.  
  644. tcase << TestAction.new(:View_EditBox_4) do
  645. $ruiObj = RUIObject.new.with('objectid', 134611444).with('selfid', 1661648749).with('textdescid', 1161931405).with('uniqueparentid', -2001114113).with('classresourceid', -760537482)
  646. .with('uitreeindex', 12)
  647. .with('pretext', 'CcBcc')
  648. .with('classname', 'android.view.View')
  649. .with('resource-id', 'EditBox')
  650. .with('content-desc', '
  651.  
  652. Sent from my LG Mobile')
  653.  
  654. $ruiObj.click
  655. end
  656.  
  657. tcase << TestAction.new(:scriptAction_14) do
  658. $ruiObj.inputtext('Testing UiEngine Email Test!!!')
  659. end
  660.  
  661. tcase << TestAction.new(:Button_BtnattachAtnt_2) do
  662. $ruiObj = RUIObject.new.with('objectid', 61942491).with('selfid', 1685585846).with('textdescid', 746935205).with('uniqueparentid', 0)
  663. .with('uitreeindex', 15)
  664. .with('classname', 'Button')
  665. .with('resource-id', 'com.lge.email:id/btnAttach_atnt')
  666. .with('content-desc', 'Attach')
  667. .with('text', 'ATTACH')
  668.  
  669. $ruiObj.click
  670.  
  671. waitsecond(2)
  672. end
  673.  
  674. tcase << TestAction.new(:ImageView_Iv_15) do
  675. $ruiObj = RUIObject.new.with('objectid', 973762667).with('selfid', -408094862).with('textdescid', 121871637).with('uniqueparentid', 0)
  676. .with('uitreeindex', 1)
  677. .with('pretext', 'Attach 0 B215 MB')
  678. .with('classname', 'ImageView')
  679. .with('resource-id', 'com.lge.email:id/iv')
  680.  
  681. $ruiObj.click
  682.  
  683. waitsecond(4)
  684. end
  685.  
  686. tcase << TestAction.new(:ImageButton_Show_6) do
  687. $ruiObj = RUIObject.new.with('objectid', -1807230859).with('selfid', -929198491).with('textdescid', 629574489).with('uniqueparentid', 0)
  688. .with('uitreeindex', 0)
  689. .with('classname', 'ImageButton')
  690. .with('content-desc', 'Show roots')
  691.  
  692. $ruiObj.click
  693. end
  694.  
  695. tcase << TestAction.new(:TextView_Title_6) do
  696. $ruiObj = RUIObject.new.with('objectid', 942770025).with('selfid', 525544369).with('textdescid', 2103473669).with('uniqueparentid', 0).with('classresourceid', 490183159)
  697. .with('uitreeindex', 15)
  698. .with('classname', 'TextView')
  699. .with('resource-id', 'android:id/title')
  700. .with('text', 'Gallery')
  701.  
  702. $ruiObj.click
  703.  
  704. waitsecond(2)
  705. end
  706.  
  707. tcase << TestAction.new(:clickXY_228_560_6) do
  708. click(228,560)
  709.  
  710. waitsecond(1)
  711. end
  712.  
  713. tcase << TestAction.new(:clickXY_204_544_8) do
  714. click(204,544)
  715.  
  716. waitsecond(1)
  717. end
  718.  
  719. tcase << TestAction.new(:Button_SelectionOk_10) do
  720. $ruiObj = RUIObject.new.with('objectid', 1615080131).with('selfid', 1112270122).with('textdescid', -118829337).with('uniqueparentid', 0)
  721. .with('uitreeindex', 3)
  722. .with('classname', 'Button')
  723. .with('resource-id', 'com.android.gallery3d:id/selection_ok')
  724. .with('text', 'OK')
  725.  
  726. $ruiObj.click
  727.  
  728. waitsecond(1)
  729. end
  730.  
  731. tcase << TestAction.new(:Click_Original) do
  732. $ruiObj = RUIObject.new.with('objectid', -784272264).with('selfid', -1179635554).with('textdescid', -74272089).with('uniqueparentid', 0).with('classresourceid', 490068035)
  733. .with('uitreeindex', 1)
  734. .with('classname', 'TextView')
  735. .with('resource-id', 'android:id/text1')
  736. .with('text', 'Original')
  737.  
  738. $ruiObj.click
  739.  
  740. waitsecond(1)
  741. end
  742.  
  743. tcase << TestAction.new(:Button_BtnsendAtnt_4) do
  744. $ruiObj = RUIObject.new.with('objectid', 1747678584).with('selfid', 1651854553).with('textdescid', 36858568).with('uniqueparentid', 0)
  745. .with('uitreeindex', 21)
  746. .with('classname', 'Button')
  747. .with('resource-id', 'com.lge.email:id/btnSend_atnt')
  748. .with('content-desc', 'Send')
  749. .with('text', 'SEND')
  750.  
  751. $ruiObj.click
  752.  
  753. waitsecond(2)
  754. end
  755.  
  756. tcase << TestAction.new(:ImageView_Img1_23) do
  757. $ruiObj = RUIObject.new.with('objectid', 577677288).with('selfid', 1832242753).with('textdescid', 1040024250).with('uniqueparentid', 0)
  758. .with('uitreeindex', 18)
  759. .with('classname', 'ImageView')
  760. .with('resource-id', 'com.lge.email:id/img1')
  761. .with('content-desc', 'Compose')
  762.  
  763. $ruiObj.isExist
  764.  
  765. waitsecond(2)
  766. end
  767.  
  768. tcase << TestAction.new(:ImageView_Slidedrawerimg_20) do
  769. $ruiObj = RUIObject.new.with('objectid', -431894634).with('selfid', -1542033050).with('textdescid', -503831734).with('uniqueparentid', 0)
  770. .with('uitreeindex', 0)
  771. .with('classname', 'ImageView')
  772. .with('resource-id', 'com.lge.email:id/slidedrawerimg')
  773.  
  774. $ruiObj.click
  775. end
  776.  
  777. tcase << TestAction.new(:TextView_DrawerChildName_22) do
  778. $ruiObj = RUIObject.new.with('objectid', 2119189077).with('selfid', 232899905).with('textdescid', -1453017635).with('uniqueparentid', 0)
  779. .with('uitreeindex', 19)
  780. .with('classname', 'TextView')
  781. .with('resource-id', 'com.lge.email:id/drawer_child_name')
  782. .with('text', 'Sent')
  783.  
  784. $ruiObj.click
  785.  
  786. waitsecond(2)
  787. end
  788.  
  789. tcase << TestAction.new(:clickXY_560_492_12) do
  790. click(560,492)
  791.  
  792. waitsecond(1)
  793. end
  794.  
  795. tcase << TestAction.new(:Button_Btnatntbottomdelete_6) do
  796. $ruiObj = RUIObject.new.with('objectid', -2098725759).with('selfid', 480632483).with('textdescid', 1124287286).with('uniqueparentid', 0)
  797. .with('uitreeindex', 25)
  798. .with('classname', 'Button')
  799. .with('resource-id', 'com.lge.email:id/btnAtntBottomDelete')
  800. .with('text', 'DELETE')
  801.  
  802. $ruiObj.click
  803.  
  804. waitsecond(2)
  805. end
  806.  
  807. tcase << TestAction.new(:Button_Button1_29) do
  808. $ruiObj = RUIObject.new.with('objectid', 892548796).with('selfid', 1012902611).with('textdescid', 1604787793).with('uniqueparentid', 0)
  809. .with('uitreeindex', 3)
  810. .with('classname', 'Button')
  811. .with('resource-id', 'android:id/button1')
  812. .with('text', 'Delete')
  813.  
  814. $ruiObj.click
  815.  
  816. waitsecond(1)
  817. end
  818.  
  819. tcase << TestAction.new(:scriptAction_8) do
  820. $myTestResult = checkLastExistResult
  821.  
  822. if $myTestResult == false
  823. $myFailReason = "Email not sent"
  824. end
  825. logStopTest("Email_05_01_03_02")
  826. end
  827.  
  828. tcase << TestAction.new(:pressBack_3) do
  829. pressBack
  830. end
  831.  
  832. tcase << TestAction.new(:pressBack_4) do
  833. pressBack
  834. end
  835.  
  836. tcase.run(loopTime)
  837.  
  838. end
  839.  
  840. def self.Email_05_01_03_03(loopTime)
  841.  
  842. tcase = TestCase.new("Email_05_01_03_03")
  843.  
  844. tcase << TestAction.new(:scriptAction_3) do
  845. logStartTest("Email_05_01_03_03")
  846. end
  847.  
  848. tcase << TestAction.new(:gotoApp_3) do
  849. gotoApp('Email')
  850. end
  851.  
  852. tcase << TestAction.new(:ImageView_Slidedrawerimg_2) do
  853. $ruiObj = RUIObject.new.with('objectid', -431894634).with('selfid', -1542033050).with('textdescid', -503831734).with('uniqueparentid', 0)
  854. .with('uitreeindex', 0)
  855. .with('classname', 'ImageView')
  856. .with('resource-id', 'com.lge.email:id/slidedrawerimg')
  857.  
  858. $ruiObj.click
  859. end
  860.  
  861. tcase << TestAction.new(:TextView_DrawerChildName_11) do
  862. $ruiObj = RUIObject.new.with('objectid', 2119189077).with('selfid', -1379016195).with('textdescid', 1922754213).with('uniqueparentid', 0)
  863. .with('uitreeindex', 12)
  864. .with('classname', 'TextView')
  865. .with('resource-id', 'com.lge.email:id/drawer_child_name')
  866. .with('text', 'Inbox')
  867.  
  868. $ruiObj.click
  869.  
  870. waitsecond(2)
  871. end
  872.  
  873. tcase << TestAction.new(:clickXY_444_404_8) do
  874. click(444,404)
  875.  
  876. waitsecond(1)
  877. end
  878.  
  879. tcase << TestAction.new(:Button_Btnatntbottomdelete_2) do
  880. $ruiObj = RUIObject.new.with('objectid', -2098725759).with('selfid', 480632483).with('textdescid', 1124287286).with('uniqueparentid', 0)
  881. .with('uitreeindex', 19)
  882. .with('classname', 'Button')
  883. .with('resource-id', 'com.lge.email:id/btnAtntBottomDelete')
  884. .with('text', 'DELETE')
  885.  
  886. $ruiObj.click
  887.  
  888. waitsecond(2)
  889. end
  890.  
  891. tcase << TestAction.new(:Button_Button1_4) do
  892. $ruiObj = RUIObject.new.with('objectid', 892548796).with('selfid', 982364851).with('textdescid', 658117233).with('uniqueparentid', 0)
  893. .with('uitreeindex', 3)
  894. .with('classname', 'Button')
  895. .with('resource-id', 'android:id/button1')
  896. .with('text', 'DELETE')
  897.  
  898. $ruiObj.click
  899.  
  900. waitsecond(2)
  901. end
  902.  
  903. tcase << TestAction.new(:scriptAction_8_1_1) do
  904. $myTestResult = checkLastExistResult
  905.  
  906. if $myTestResult == false
  907. $myFailReason = "Email not opened"
  908. end
  909. logStopTest("Email_05_01_03_03")
  910. end
  911.  
  912. tcase << TestAction.new(:pressBack_1) do
  913. pressBack
  914. end
  915.  
  916. tcase << TestAction.new(:pressBack_2) do
  917. pressBack
  918. end
  919.  
  920. tcase.run(loopTime)
  921.  
  922. end
  923.  
  924. def self.GPU_WebCrawler(loopTime)
  925.  
  926. tcase = TestCase.new("GPU_WebCrawler")
  927.  
  928. tcase << TestAction.new(:gotoApp_2) do
  929. gotoApp('WebCrawler')
  930.  
  931. waitsecond(2)
  932. end
  933.  
  934. tcase << TestAction.new(:Button_Start_6) do
  935. $ruiObj = RUIObject.new.with('objectid', 759506754).with('selfid', 1749104131).with('textdescid', 384870857).with('uniqueparentid', 0).with('classresourceid', -53051820)
  936. .with('uitreeindex', 3)
  937. .with('classname', 'Button')
  938. .with('resource-id', 'com.android.webcrawler:id/start')
  939. .with('text', 'Start Crawling')
  940.  
  941. $ruiObj.click
  942.  
  943. waitsecond(2)
  944. end
  945.  
  946. tcase << TestAction.new(:wait32second_9) do
  947. waitsecond(100)
  948. end
  949.  
  950. tcase << TestAction.new(:pressBack_11) do
  951. pressBack
  952.  
  953. waitsecond(2)
  954. end
  955.  
  956. tcase << TestAction.new(:pressBack_2) do
  957. pressBack
  958.  
  959. waitsecond(2)
  960. end
  961.  
  962. tcase.run(loopTime)
  963.  
  964. end
  965.  
  966. def self.Gmail_05_01_03_01(loopTime)
  967.  
  968. tcase = TestCase.new("Gmail_05_01_03_01")
  969.  
  970. tcase << TestAction.new(:pressHome_2) do
  971. pressHome
  972. end
  973.  
  974. tcase << TestAction.new(:scriptAction_12_1) do
  975. logStartTest("Gmail_05_01_03_01")
  976. end
  977.  
  978. tcase << TestAction.new(:gotoApp_3) do
  979. gotoApp('Gmail')
  980.  
  981. waitsecond(2)
  982. end
  983.  
  984. tcase << TestAction.new(:ImageButton_ComposeButton_2) do
  985. $ruiObj = RUIObject.new.with('objectid', 2010391035).with('selfid', 1808564263).with('textdescid', -481574643).with('uniqueparentid', 0)
  986. .with('uitreeindex', 26)
  987. .with('classname', 'ImageButton')
  988. .with('resource-id', 'com.google.android.gm:id/compose_button')
  989. .with('content-desc', 'Compose')
  990.  
  991. $ruiObj.click
  992.  
  993. waitsecond(1)
  994. end
  995.  
  996. tcase << TestAction.new(:MultiAutoCompleteTextView_To_5) do
  997. $ruiObj = RUIObject.new.with('objectid', 1308296701).with('selfid', 678761455).with('textdescid', 1902492099).with('uniqueparentid', 0).with('classresourceid', 1488875515)
  998. .with('uitreeindex', 9)
  999. .with('classname', 'MultiAutoCompleteTextView')
  1000. .with('resource-id', 'com.google.android.gm:id/to')
  1001.  
  1002. $ruiObj.inputtext('dvgats1@gmail.com')
  1003.  
  1004. waitsecond(2)
  1005. end
  1006.  
  1007. tcase << TestAction.new(:pressEnter_3) do
  1008. pressEnter
  1009. end
  1010.  
  1011. tcase << TestAction.new(:EditText_Subject_6) do
  1012. $ruiObj = RUIObject.new.with('objectid', 1144045145).with('selfid', -477614756).with('textdescid', 1105661159).with('uniqueparentid', 0).with('classresourceid', 927865352)
  1013. .with('uitreeindex', 12)
  1014. .with('classname', 'EditText')
  1015. .with('resource-id', 'com.google.android.gm:id/subject')
  1016.  
  1017. $ruiObj.inputtext('Email Test')
  1018.  
  1019. waitsecond(1)
  1020. end
  1021.  
  1022. tcase << TestAction.new(:View_Compose_2) do
  1023. $ruiObj = RUIObject.new.with('objectid', -2101420856).with('selfid', -497970335).with('textdescid', 1027339414).with('uniqueparentid', 1227675605).with('classresourceid', 1815484335)
  1024. .with('uitreeindex', 14)
  1025. .with('classname', 'android.view.View')
  1026. .with('content-desc', 'Compose email')
  1027.  
  1028. $ruiObj.click
  1029.  
  1030. waitsecond(2)
  1031. end
  1032.  
  1033. tcase << TestAction.new(:scriptAction_14) do
  1034. $ruiObj.inputtext('Testing UiEngine Email Test!!!')
  1035. end
  1036.  
  1037. tcase << TestAction.new(:TextView_Send_10) do
  1038. $ruiObj = RUIObject.new.with('objectid', 1131985907).with('selfid', 2103341243).with('textdescid', -1405558155).with('uniqueparentid', 0)
  1039. .with('uitreeindex', 3)
  1040. .with('classname', 'TextView')
  1041. .with('resource-id', 'com.google.android.gm:id/send')
  1042. .with('content-desc', 'Send')
  1043.  
  1044. $ruiObj.click
  1045.  
  1046. waitsecond(1)
  1047. end
  1048.  
  1049. tcase << TestAction.new(:ImageButton_ComposeButton_12) do
  1050. $ruiObj = RUIObject.new.with('objectid', 2010391035).with('selfid', 1808564263).with('textdescid', -481574643).with('uniqueparentid', 0)
  1051. .with('uitreeindex', 26)
  1052. .with('classname', 'ImageButton')
  1053. .with('resource-id', 'com.google.android.gm:id/compose_button')
  1054. .with('content-desc', 'Compose')
  1055.  
  1056. $ruiObj.isExist
  1057.  
  1058. waitsecond(1)
  1059. end
  1060.  
  1061. tcase << TestAction.new(:ImageButton_Open_2) do
  1062. $ruiObj = RUIObject.new.with('objectid', -387960062).with('selfid', 1589392844).with('textdescid', -1233194523).with('uniqueparentid', 0)
  1063. .with('uitreeindex', 0)
  1064. .with('classname', 'ImageButton')
  1065. .with('content-desc', 'Open navigation drawer')
  1066.  
  1067. $ruiObj.click
  1068.  
  1069. waitsecond(2)
  1070. end
  1071.  
  1072. tcase << TestAction.new(:TextView_Name_4) do
  1073. $ruiObj = RUIObject.new.with('objectid', -630461263).with('selfid', -610816808).with('textdescid', 727067449).with('uniqueparentid', 0).with('classresourceid', 790406410)
  1074. .with('uitreeindex', 23)
  1075. .with('classname', 'TextView')
  1076. .with('resource-id', 'com.google.android.gm:id/name')
  1077. .with('text', 'Sent')
  1078.  
  1079. $ruiObj.click
  1080.  
  1081. waitsecond(2)
  1082. end
  1083.  
  1084. tcase << TestAction.new(:clickXY_428_768_19) do
  1085. click(428,768)
  1086.  
  1087. waitsecond(1)
  1088. end
  1089.  
  1090. tcase << TestAction.new(:TextView_Delete_4) do
  1091. $ruiObj = RUIObject.new.with('objectid', 1211721173).with('selfid', -390800203).with('textdescid', -538482442).with('uniqueparentid', 0)
  1092. .with('uitreeindex', 1)
  1093. .with('classname', 'TextView')
  1094. .with('resource-id', 'com.google.android.gm:id/delete')
  1095. .with('content-desc', 'Delete')
  1096.  
  1097. $ruiObj.click
  1098.  
  1099. waitsecond(2)
  1100. end
  1101.  
  1102. tcase << TestAction.new(:scriptAction_8) do
  1103. $myTestResult = checkLastExistResult
  1104.  
  1105. if $myTestResult == false
  1106. $myFailReason = "Email not sent"
  1107. end
  1108. logStopTest("Gmail_05_01_03_01")
  1109. end
  1110.  
  1111. tcase << TestAction.new(:pressBack_3) do
  1112. pressBack
  1113. end
  1114.  
  1115. tcase << TestAction.new(:pressBack_4) do
  1116. pressBack
  1117. end
  1118.  
  1119. tcase << TestAction.new(:pressHome_21) do
  1120. pressHome
  1121.  
  1122. waitsecond(2)
  1123. end
  1124.  
  1125. tcase.run(loopTime)
  1126.  
  1127. end
  1128.  
  1129. def self.Gmail_05_01_03_02(loopTime)
  1130.  
  1131. tcase = TestCase.new("Gmail_05_01_03_02")
  1132.  
  1133. tcase << TestAction.new(:scriptAction_12) do
  1134. logStartTest("Gmail_05_01_03_02")
  1135. end
  1136.  
  1137. tcase << TestAction.new(:gotoApp_3) do
  1138. gotoApp('Gmail')
  1139.  
  1140. waitsecond(2)
  1141. end
  1142.  
  1143. tcase << TestAction.new(:ImageButton_ComposeButton_2) do
  1144. $ruiObj = RUIObject.new.with('objectid', 2010391035).with('selfid', 1808564263).with('textdescid', -481574643).with('uniqueparentid', 0)
  1145. .with('uitreeindex', 24)
  1146. .with('classname', 'ImageButton')
  1147. .with('resource-id', 'com.google.android.gm:id/compose_button')
  1148. .with('content-desc', 'Compose')
  1149.  
  1150. $ruiObj.click
  1151.  
  1152. waitsecond(2)
  1153. end
  1154.  
  1155. tcase << TestAction.new(:MultiAutoCompleteTextView_To_49) do
  1156. $ruiObj = RUIObject.new.with('objectid', 1308296701).with('selfid', 678761455).with('textdescid', 1902492099).with('uniqueparentid', 0).with('classresourceid', 1488875515)
  1157. .with('uitreeindex', 9)
  1158. .with('classname', 'MultiAutoCompleteTextView')
  1159. .with('resource-id', 'com.google.android.gm:id/to')
  1160.  
  1161. $ruiObj.inputtext('dvgats1@gmail.com')
  1162.  
  1163. waitsecond(2)
  1164. end
  1165.  
  1166. tcase << TestAction.new(:pressEnter_7) do
  1167. pressEnter
  1168.  
  1169. waitsecond(1)
  1170. end
  1171.  
  1172. tcase << TestAction.new(:EditText_Subject_9) do
  1173. $ruiObj = RUIObject.new.with('objectid', 1144045145).with('selfid', -477614756).with('textdescid', 1105661159).with('uniqueparentid', 0).with('classresourceid', 927865352)
  1174. .with('uitreeindex', 12)
  1175. .with('classname', 'EditText')
  1176. .with('resource-id', 'com.google.android.gm:id/subject')
  1177.  
  1178. $ruiObj.inputtext('Email Test')
  1179.  
  1180. waitsecond(1)
  1181. end
  1182.  
  1183. tcase << TestAction.new(:View_Compose_2) do
  1184. $ruiObj = RUIObject.new.with('objectid', -2101420856).with('selfid', -497970335).with('textdescid', 1027339414).with('uniqueparentid', 1227675605).with('classresourceid', 1815484335)
  1185. .with('uitreeindex', 14)
  1186. .with('classname', 'android.view.View')
  1187. .with('content-desc', 'Compose email')
  1188.  
  1189. $ruiObj.click
  1190.  
  1191. waitsecond(2)
  1192. end
  1193.  
  1194. tcase << TestAction.new(:scriptAction_14) do
  1195. $ruiObj.inputtext('Testing UiEngine Email Test!!!')
  1196. end
  1197.  
  1198. tcase << TestAction.new(:TextView_AddAttachment_13) do
  1199. $ruiObj = RUIObject.new.with('objectid', 915724844).with('selfid', 1566257663).with('textdescid', -1753719389).with('uniqueparentid', 0)
  1200. .with('uitreeindex', 2)
  1201. .with('classname', 'TextView')
  1202. .with('resource-id', 'com.google.android.gm:id/add_attachment')
  1203. .with('content-desc', 'Attach file')
  1204.  
  1205. $ruiObj.click
  1206.  
  1207. waitsecond(1)
  1208. end
  1209.  
  1210. tcase << TestAction.new(:TextView_Title_4) do
  1211. $ruiObj = RUIObject.new.with('objectid', 665784376).with('selfid', -1478650284).with('textdescid', 1395090321).with('uniqueparentid', 0).with('classresourceid', -1261418567)
  1212. .with('uitreeindex', 0)
  1213. .with('classname', 'TextView')
  1214. .with('resource-id', 'com.google.android.gm:id/title')
  1215. .with('text', 'Attach file')
  1216.  
  1217. $ruiObj.click
  1218.  
  1219. waitsecond(2)
  1220. end
  1221.  
  1222. tcase << TestAction.new(:ImageButton_Show_2) do
  1223. $ruiObj = RUIObject.new.with('objectid', -1807230859).with('selfid', -929198491).with('textdescid', 629574489).with('uniqueparentid', 0)
  1224. .with('uitreeindex', 0)
  1225. .with('classname', 'ImageButton')
  1226. .with('content-desc', 'Show roots')
  1227.  
  1228. $ruiObj.click
  1229.  
  1230. waitsecond(1)
  1231. end
  1232.  
  1233. tcase << TestAction.new(:TextView_Title_14) do
  1234. $ruiObj = RUIObject.new.with('objectid', -1941383373).with('selfid', 4082754).with('textdescid', 50769842).with('uniqueparentid', 0).with('classresourceid', 490183159)
  1235. .with('uitreeindex', 30)
  1236. .with('classname', 'TextView')
  1237. .with('resource-id', 'android:id/title')
  1238. .with('text', 'Photos')
  1239.  
  1240. $ruiObj.click
  1241.  
  1242. waitsecond(2)
  1243. end
  1244.  
  1245. tcase << TestAction.new(:Button_PermissionAllowButton_12) do
  1246. $ruiObj = RUIObject.new.with('objectid', -886457929).with('selfid', 1443382411).with('textdescid', 270556320).with('uniqueparentid', 0)
  1247. .with('uitreeindex', 3)
  1248. .with('classname', 'Button')
  1249. .with('resource-id', 'com.android.packageinstaller:id/permission_allow_button')
  1250. .with('text', 'ALLOW')
  1251.  
  1252. $ruiObj.click
  1253.  
  1254. waitsecond(2)
  1255. end
  1256.  
  1257. tcase << TestAction.new(:TextView_Title_16) do
  1258. $ruiObj = RUIObject.new.with('objectid', -2074516409).with('selfid', -1484513934).with('textdescid', 889140747).with('uniqueparentid', 0)
  1259. .with('uitreeindex', 19)
  1260. .with('classname', 'TextView')
  1261. .with('resource-id', 'com.google.android.apps.photos:id/title')
  1262. .with('text', '1M')
  1263.  
  1264. $ruiObj.click
  1265.  
  1266. waitsecond(2)
  1267. end
  1268.  
  1269. tcase << TestAction.new(:View_Photo_18) do
  1270. $ruiObj = RUIObject.new.with('objectid', 2023669211).with('selfid', -986702481).with('textdescid', -1518879013).with('uniqueparentid', 0)
  1271. .with('uitreeindex', 2)
  1272. .with('classname', 'android.view.ViewGroup')
  1273.  
  1274. $ruiObj.select('Similiar').click
  1275.  
  1276. waitsecond(2)
  1277. end
  1278.  
  1279. tcase << TestAction.new(:TextView_DoneButton_20) do
  1280. $ruiObj = RUIObject.new.with('objectid', -984795698).with('selfid', -885365197).with('textdescid', 1453085810).with('uniqueparentid', 0)
  1281. .with('uitreeindex', 11)
  1282. .with('classname', 'TextView')
  1283. .with('resource-id', 'com.google.android.apps.photos:id/done_button')
  1284. .with('content-desc', 'Done')
  1285. .with('text', 'DONE')
  1286.  
  1287. $ruiObj.click
  1288.  
  1289. waitsecond(2)
  1290. end
  1291.  
  1292. tcase << TestAction.new(:TextView_Send_23) do
  1293. $ruiObj = RUIObject.new.with('objectid', 1131985907).with('selfid', 2103341243).with('textdescid', -1405558155).with('uniqueparentid', 0)
  1294. .with('uitreeindex', 3)
  1295. .with('classname', 'TextView')
  1296. .with('resource-id', 'com.google.android.gm:id/send')
  1297. .with('content-desc', 'Send')
  1298.  
  1299. $ruiObj.click
  1300.  
  1301. waitsecond(2)
  1302. end
  1303.  
  1304. tcase << TestAction.new(:ImageButton_ComposeButton_6) do
  1305. $ruiObj = RUIObject.new.with('objectid', 1598291378).with('selfid', 1808564263).with('textdescid', -1604213756).with('uniqueparentid', 0)
  1306. .with('uitreeindex', 16)
  1307. .with('classname', 'ImageButton')
  1308. .with('resource-id', 'com.google.android.gm:id/compose_button')
  1309. .with('content-desc', 'Compose')
  1310.  
  1311. $ruiObj.isExist
  1312. end
  1313.  
  1314. tcase << TestAction.new(:ImageButton_Open_2) do
  1315. $ruiObj = RUIObject.new.with('objectid', -1013150848).with('selfid', 1589392844).with('textdescid', -993230041).with('uniqueparentid', 0)
  1316. .with('uitreeindex', 0)
  1317. .with('classname', 'ImageButton')
  1318. .with('content-desc', 'Open navigation drawer')
  1319.  
  1320. $ruiObj.click
  1321.  
  1322. waitsecond(2)
  1323. end
  1324.  
  1325. tcase << TestAction.new(:clickXY_3195_1800_4) do
  1326. click(319.5,1800)
  1327.  
  1328. waitsecond(2)
  1329. end
  1330.  
  1331. tcase << TestAction.new(:clickXY_7065_8865_6) do
  1332. click(706.5,886.5)
  1333.  
  1334. waitsecond(2)
  1335. end
  1336.  
  1337. tcase << TestAction.new(:TextView_Delete_36) do
  1338. $ruiObj = RUIObject.new.with('objectid', -15615667).with('selfid', -390800203).with('textdescid', -1373012866).with('uniqueparentid', 0)
  1339. .with('uitreeindex', 1)
  1340. .with('classname', 'TextView')
  1341. .with('resource-id', 'com.google.android.gm:id/delete')
  1342. .with('content-desc', 'Delete')
  1343.  
  1344. $ruiObj.click
  1345.  
  1346. waitsecond(1)
  1347. end
  1348.  
  1349. tcase << TestAction.new(:scriptAction_8) do
  1350. $myTestResult = checkLastExistResult
  1351.  
  1352. if $myTestResult == false
  1353. $myFailReason = "Email not sent"
  1354. end
  1355. logStopTest("Gmail_05_01_03_02")
  1356. end
  1357.  
  1358. tcase << TestAction.new(:pressBack_3) do
  1359. pressBack
  1360. end
  1361.  
  1362. tcase << TestAction.new(:pressBack_4) do
  1363. pressBack
  1364. end
  1365.  
  1366. tcase << TestAction.new(:pressHome_2) do
  1367. pressHome
  1368.  
  1369. waitsecond(0)
  1370. end
  1371.  
  1372. tcase.run(loopTime)
  1373.  
  1374. end
  1375.  
  1376. def self.Gmail_05_01_03_03(loopTime)
  1377.  
  1378. tcase = TestCase.new("Gmail_05_01_03_03")
  1379.  
  1380. tcase << TestAction.new(:scriptAction_3) do
  1381. logStartTest("Gmail_05_01_03_03")
  1382. end
  1383.  
  1384. tcase << TestAction.new(:gotoApp_3) do
  1385. gotoApp('Gmail')
  1386. end
  1387.  
  1388. tcase << TestAction.new(:ImageButton_Navigate_4) do
  1389. $ruiObj = RUIObject.new.with('objectid', -387960062).with('selfid', -123872605).with('textdescid', -1698616212).with('uniqueparentid', 0)
  1390. .with('uitreeindex', 0)
  1391. .with('classname', 'ImageButton')
  1392. .with('content-desc', 'Navigate up')
  1393.  
  1394. $ruiObj.click
  1395.  
  1396. waitsecond(1)
  1397. end
  1398.  
  1399. tcase << TestAction.new(:TextView_Name_2) do
  1400. $ruiObj = RUIObject.new.with('objectid', -630461263).with('selfid', -610816808).with('textdescid', 727067449).with('uniqueparentid', 0).with('classresourceid', 790406410)
  1401. .with('uitreeindex', 26)
  1402. .with('classname', 'TextView')
  1403. .with('resource-id', 'com.google.android.gm:id/name')
  1404. .with('text', 'Sent')
  1405.  
  1406. $ruiObj.click
  1407.  
  1408. waitsecond(1)
  1409. end
  1410.  
  1411. tcase << TestAction.new(:clickXY_672_824_5) do
  1412. click(672,824)
  1413.  
  1414. waitsecond(1)
  1415. end
  1416.  
  1417. tcase << TestAction.new(:TextView_Delete_10) do
  1418. $ruiObj = RUIObject.new.with('objectid', -15615667).with('selfid', -390800203).with('textdescid', -1373012866).with('uniqueparentid', 0)
  1419. .with('uitreeindex', 2)
  1420. .with('classname', 'TextView')
  1421. .with('resource-id', 'com.google.android.gm:id/delete')
  1422. .with('content-desc', 'Delete')
  1423.  
  1424. $ruiObj.isExist
  1425. end
  1426.  
  1427. tcase << TestAction.new(:scriptAction_8_1_1) do
  1428. $myTestResult = checkLastExistResult
  1429.  
  1430. if $myTestResult == false
  1431. $myFailReason = "Email not opened"
  1432. end
  1433. logStopTest("Gmail_05_01_03_03")
  1434. end
  1435.  
  1436. tcase << TestAction.new(:pressBack_1) do
  1437. pressBack
  1438. end
  1439.  
  1440. tcase << TestAction.new(:pressBack_2) do
  1441. pressBack
  1442. end
  1443.  
  1444. tcase << TestAction.new(:pressHome_4) do
  1445. pressHome
  1446.  
  1447. waitsecond(2)
  1448. end
  1449.  
  1450. tcase.run(loopTime)
  1451.  
  1452. end
  1453.  
  1454. def self.MenuNavigation_05_01_09_01(loopTime)
  1455.  
  1456. tcase = TestCase.new("MenuNavigation_05_01_09_01")
  1457.  
  1458. tcase << TestAction.new(:pressHome_1) do
  1459. pressHome
  1460. end
  1461.  
  1462. tcase << TestAction.new(:scriptAction_off) do
  1463. $ignoreDefaultExpHandler = true
  1464.  
  1465. waitsecond(2)
  1466. end
  1467.  
  1468. tcase << TestAction.new(:scriptAction_StartTestLog) do
  1469. logStartTest("05_01_09_01_Menu_Navigation")
  1470.  
  1471.  
  1472. waitsecond(2)
  1473. end
  1474.  
  1475. tcase << TestAction.new(:scriptAction_resetCounter) do
  1476. $appCounter = 0
  1477.  
  1478. waitsecond(2)
  1479. end
  1480.  
  1481. tcase << TestAction.new(:scriptAction_loop) do
  1482.  
  1483. until $appCounter > 31
  1484. $appCounter += 1
  1485. gotoApp(db('NavApp')[$appCounter-1])
  1486. waitsecond(2)
  1487. allow_popup
  1488. waitsecond(2)
  1489. pressHome
  1490. $ruiObj = RUIObject.new.with('objectid', -1351376744).with('selfid', -1318451484).with('textdescid', -1794026948).with('uniqueparentid', 0)
  1491. .with('uitreeindex', 1)
  1492. .with('classname', 'Button')
  1493. .with('resource-id', 'android:id/button1')
  1494. .with('text', 'OK')
  1495.  
  1496. $ruiObj.click
  1497. end
  1498.  
  1499. waitsecond(2)
  1500. end
  1501.  
  1502. tcase << TestAction.new(:scriptAction_StopLogTest) do
  1503. if $appCounter == 26
  1504. $myTestResult = true
  1505. else
  1506. $myTestRsult = false
  1507. $myFailReason = "Failed"
  1508. end
  1509. logStopTest("05_01_09_01_Menu_Navigation")
  1510.  
  1511. waitsecond(2)
  1512. end
  1513.  
  1514. tcase.run(loopTime)
  1515.  
  1516. end
  1517.  
  1518. def self.Messaging_05_01_02_03(loopTime)
  1519.  
  1520. tcase = TestCase.new("Messaging_05_01_02_03")
  1521.  
  1522. tcase << TestAction.new(:scriptAction_28) do
  1523. logStartTest("Messaging_05_01_02_03")
  1524. end
  1525.  
  1526. tcase << TestAction.new(:gotoApp_2) do
  1527. gotoApp('Messaging')
  1528.  
  1529. waitsecond(1)
  1530. end
  1531.  
  1532. tcase << TestAction.new(:Button_Button1_2) do
  1533. $ruiObj = RUIObject.new.with('objectid', -1004548822).with('selfid', 2077686463).with('textdescid', 307253103).with('uniqueparentid', 0).with('classresourceid', 1834539358)
  1534. .with('uitreeindex', 4)
  1535. .with('classname', 'Button')
  1536. .with('resource-id', 'android:id/button1')
  1537. .with('text', 'YES')
  1538.  
  1539. $ruiObj.click
  1540.  
  1541. waitsecond(2)
  1542. end
  1543.  
  1544. tcase << TestAction.new(:ComposeNewMessage) do
  1545. $tmusComposeButton = RUIObject.new.with('objectid', -547009504).with('selfid', 1638137891).with('textdescid', 1140939687).with('uniqueparentid', 0)
  1546. .with('uitreeindex', 5)
  1547. .with('classname', 'ImageView')
  1548. .with('resource-id', 'com.android.mms:id/fab_img')
  1549. .with('content-desc', 'New message')
  1550.  
  1551. $vzwComposeButton = RUIObject.new.with('objectid', 2129085589).with('selfid', 468961841).with('textdescid', -293661237).with('uniqueparentid', 0)
  1552. .with('uitreeindex', 5)
  1553. .with('classname', 'ImageView')
  1554. .with('resource-id', 'com.android.mms:id/img1')
  1555. .with('content-desc', 'Compose button')
  1556.  
  1557. if $tmusComposeButton.isExist
  1558. $tmusComposeButton.click
  1559. elsif $vzwComposeButton.isExist
  1560. $vzwComposeButton.click
  1561. end
  1562.  
  1563. waitsecond(2)
  1564. end
  1565.  
  1566. tcase << TestAction.new(:MultiAutoCompleteTextView_2) do
  1567. $ruiObj = RUIObject.new.with('objectid', -2030797265).with('selfid', -1346021293).with('textdescid', 1469794257).with('uniqueparentid', 0).with('classresourceid', -1346021293)
  1568. .with('uitreeindex', 0)
  1569. .with('classname', 'MultiAutoCompleteTextView')
  1570.  
  1571. $ruiObj.inputtext('A01 a01')
  1572.  
  1573. waitsecond(1)
  1574. end
  1575.  
  1576. tcase << TestAction.new(:clickXY_110_182_6) do
  1577. click(110,182)
  1578.  
  1579. waitsecond(1)
  1580. end
  1581.  
  1582. tcase << TestAction.new(:EditText_Enter_8) do
  1583. $ruiObj = RUIObject.new.with('objectid', -1637280020).with('selfid', -454502120).with('textdescid', -1217933909).with('uniqueparentid', 0).with('classresourceid', 1666676343)
  1584. .with('uitreeindex', 5)
  1585. .with('classname', 'EditText')
  1586. .with('content-desc', 'Enter message')
  1587.  
  1588. $ruiObj.click
  1589.  
  1590. waitsecond(1)
  1591. end
  1592.  
  1593. tcase << TestAction.new(:scriptAction_141_1) do
  1594. $ruiObj.inputtext('Abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzaaaaaaaaaabbbbbbbbbbcccccccccc')
  1595.  
  1596. waitsecond(4)
  1597. end
  1598.  
  1599. tcase << TestAction.new(:SendButton) do
  1600. $tmusSendButton = RUIObject.new.with('objectid', 353843972).with('selfid', 742186862).with('textdescid', -1914765924).with('uniqueparentid', 0)
  1601. .with('uitreeindex', 8)
  1602. .with('classname', 'Button')
  1603. .with('resource-id', 'com.android.mms:id/send_button_text')
  1604. .with('content-desc', 'Send')
  1605. .with('text', 'Send')
  1606.  
  1607. $vzwSendButton = RUIObject.new.with('objectid', 1247717607).with('selfid', -817858366).with('textdescid', -1713609473).with('uniqueparentid', 0)
  1608. .with('uitreeindex', 8)
  1609. .with('classname', 'Button')
  1610. .with('resource-id', 'com.android.mms:id/send_button')
  1611. .with('text', 'Send')
  1612.  
  1613. if $tmusSendButton.isExist
  1614. $tmusSendButton.click
  1615. elsif $vzwSendButton.isExist
  1616. $vzwSendButton.click
  1617. end
  1618.  
  1619. waitsecond(2)
  1620. end
  1621.  
  1622. tcase << TestAction.new(:pressBack_5) do
  1623. pressBack
  1624. end
  1625.  
  1626. tcase << TestAction.new(:pressBack_6) do
  1627. pressBack
  1628. end
  1629.  
  1630. tcase << TestAction.new(:clickXY_164_208_12) do
  1631. click(164,208)
  1632.  
  1633. waitsecond(1)
  1634. end
  1635.  
  1636. tcase << TestAction.new(:TextView_TimestampView_2) do
  1637. $ruiObj = RUIObject.new.with('objectid', 780859453).with('selfid', -108293667).with('textdescid', -1097305943).with('uniqueparentid', 0).with('classresourceid', 1659956455)
  1638. .with('uitreeindex', 8)
  1639. .with('classname', 'TextView')
  1640. .with('resource-id', 'com.android.mms:id/timestamp_view')
  1641. .with('text', 'Sending')
  1642.  
  1643. $ruiObj.isNotExist
  1644. end
  1645.  
  1646. tcase << TestAction.new(:TextView_Delete_6) do
  1647. $ruiObj = RUIObject.new.with('objectid', -1337172653).with('selfid', 1644806947).with('textdescid', -2074083528).with('uniqueparentid', 0)
  1648. .with('uitreeindex', 4)
  1649. .with('classname', 'TextView')
  1650. .with('content-desc', 'Delete')
  1651.  
  1652. $ruiObj.click
  1653.  
  1654. waitsecond(1)
  1655. end
  1656.  
  1657. tcase << TestAction.new(:TextView_Title_2) do
  1658. $ruiObj = RUIObject.new.with('objectid', 930093027).with('selfid', -1054998202).with('textdescid', 908714598).with('uniqueparentid', 0)
  1659. .with('uitreeindex', 1)
  1660. .with('classname', 'TextView')
  1661. .with('resource-id', 'com.android.mms:id/title')
  1662. .with('text', 'Select all')
  1663.  
  1664. $ruiObj.click
  1665. end
  1666.  
  1667. tcase << TestAction.new(:Button_Button1_7) do
  1668. $ruiObj = RUIObject.new.with('objectid', -1505530336).with('selfid', 982364851).with('textdescid', 652125653).with('uniqueparentid', 0)
  1669. .with('uitreeindex', 2)
  1670. .with('classname', 'Button')
  1671. .with('resource-id', 'android:id/button1')
  1672. .with('text', 'DELETE')
  1673.  
  1674. $ruiObj.click
  1675.  
  1676. waitsecond(2)
  1677. end
  1678.  
  1679. tcase << TestAction.new(:Button_Button1_18) do
  1680. $ruiObj = RUIObject.new.with('objectid', -1505530336).with('selfid', 2077687487).with('textdescid', -1187425223).with('uniqueparentid', 0)
  1681. .with('uitreeindex', 3)
  1682. .with('classname', 'Button')
  1683. .with('resource-id', 'android:id/button1')
  1684. .with('text', 'Yes')
  1685.  
  1686. $ruiObj.click
  1687.  
  1688. waitsecond(1)
  1689. end
  1690.  
  1691. tcase << TestAction.new(:scriptAction_30) do
  1692. $myTestResult = checkLastExistResult
  1693.  
  1694. if $myTestResult == false
  1695. $myFailReason = "Message not sent"
  1696. end
  1697. logStopTest("Messaging_05_01_02_03")
  1698. end
  1699.  
  1700. tcase << TestAction.new(:pressBack_53) do
  1701. pressBack
  1702.  
  1703. waitsecond(1)
  1704. end
  1705.  
  1706. tcase << TestAction.new(:pressBack_26) do
  1707. pressBack
  1708.  
  1709. waitsecond(1)
  1710. end
  1711.  
  1712. tcase.run(loopTime)
  1713.  
  1714. end
  1715.  
  1716. def self.Messaging_05_01_02_05(loopTime)
  1717.  
  1718. tcase = TestCase.new("Messaging_05_01_02_05")
  1719.  
  1720. tcase << TestAction.new(:scriptAction_28) do
  1721. logStartTest("Messaging_05_01_02_05")
  1722. end
  1723.  
  1724. tcase << TestAction.new(:gotoApp_2) do
  1725. gotoApp('Messaging')
  1726.  
  1727. waitsecond(1)
  1728. end
  1729.  
  1730. tcase << TestAction.new(:ComposeNewMessage_1) do
  1731. $tmusComposeButton = RUIObject.new.with('objectid', -547009504).with('selfid', 1638137891).with('textdescid', 1140939687).with('uniqueparentid', 0)
  1732. .with('uitreeindex', 5)
  1733. .with('classname', 'ImageView')
  1734. .with('resource-id', 'com.android.mms:id/fab_img')
  1735. .with('content-desc', 'New message')
  1736.  
  1737. $vzwComposeButton = RUIObject.new.with('objectid', 2129085589).with('selfid', 468961841).with('textdescid', -293661237).with('uniqueparentid', 0)
  1738. .with('uitreeindex', 5)
  1739. .with('classname', 'ImageView')
  1740. .with('resource-id', 'com.android.mms:id/img1')
  1741. .with('content-desc', 'Compose button')
  1742.  
  1743. if $tmusComposeButton.isExist
  1744. $tmusComposeButton.click
  1745. elsif $vzwComposeButton.isExist
  1746. $vzwComposeButton.click
  1747. end
  1748.  
  1749. waitsecond(2)
  1750. end
  1751.  
  1752. tcase << TestAction.new(:MultiAutoCompleteTextView_2) do
  1753. $ruiObj = RUIObject.new.with('objectid', -2030797265).with('selfid', -1346021293).with('textdescid', 1469794257).with('uniqueparentid', 0).with('classresourceid', -1346021293)
  1754. .with('uitreeindex', 0)
  1755. .with('classname', 'MultiAutoCompleteTextView')
  1756.  
  1757. $ruiObj.inputtext('A01 a01')
  1758.  
  1759. waitsecond(1)
  1760. end
  1761.  
  1762. tcase << TestAction.new(:clickXY_88_174_6) do
  1763. click(88,174)
  1764.  
  1765. waitsecond(1)
  1766. end
  1767.  
  1768. tcase << TestAction.new(:EditText_Enter_2) do
  1769. $ruiObj = RUIObject.new.with('objectid', -1677830865).with('selfid', -454502120).with('textdescid', 724968942).with('uniqueparentid', 0).with('classresourceid', 1666676343)
  1770. .with('uitreeindex', 9)
  1771. .with('classname', 'EditText')
  1772. .with('content-desc', 'Enter message')
  1773.  
  1774. $ruiObj.click
  1775.  
  1776. waitsecond(1)
  1777. end
  1778.  
  1779. tcase << TestAction.new(:scriptAction_141_1) do
  1780. $ruiObj.inputtext('Abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzaaaaaaaaaabbbbbbbbbbcccccccccc')
  1781.  
  1782. waitsecond(4)
  1783. end
  1784.  
  1785. tcase << TestAction.new(:AttachButton) do
  1786. $tmusAttachButton = RUIObject.new.with('objectid', 874172794).with('selfid', -1211001229).with('textdescid', -704319221).with('uniqueparentid', 0)
  1787. .with('uitreeindex', 6)
  1788. .with('classname', 'ImageButton')
  1789. .with('resource-id', 'com.android.mms:id/attachButton_right')
  1790. .with('content-desc', 'Attach')
  1791.  
  1792. $vzwAttachButton = RUIObject.new.with('objectid', 1000615746).with('selfid', -876235136).with('textdescid', -1072393149).with('uniqueparentid', 0)
  1793. .with('uitreeindex', 5)
  1794. .with('classname', 'ImageButton')
  1795. .with('resource-id', 'com.android.mms:id/attachButton_left')
  1796. .with('content-desc', 'Attach')
  1797.  
  1798. if $tmusAttachButton.isExist
  1799. $tmusAttachButton.click
  1800. elsif $vzwAttachButton.isExist
  1801. $vzwAttachButton.click
  1802. end
  1803.  
  1804. waitsecond(2)
  1805. end
  1806.  
  1807. tcase << TestAction.new(:Video) do
  1808. $ruiObj = RUIObject.new.with('objectid', -1141961992).with('selfid', -465694566).with('textdescid', -1041083352).with('uniqueparentid', 0)
  1809. .with('uitreeindex', 5)
  1810. .with('pretext', 'Take photo')
  1811. .with('classname', 'ImageView')
  1812. .with('resource-id', 'com.android.mms:id/icon')
  1813.  
  1814. $ruiObj.click
  1815.  
  1816. waitsecond(8)
  1817. end
  1818.  
  1819. tcase << TestAction.new(:Button_PermissionAllowButton_6) do
  1820. $ruiObj = RUIObject.new.with('objectid', -886457929).with('selfid', 1443382411).with('textdescid', 270556320).with('uniqueparentid', 0)
  1821. .with('uitreeindex', 3)
  1822. .with('classname', 'Button')
  1823. .with('resource-id', 'com.android.packageinstaller:id/permission_allow_button')
  1824. .with('text', 'ALLOW')
  1825.  
  1826. $ruiObj.click
  1827.  
  1828. waitsecond(1)
  1829. end
  1830.  
  1831. tcase << TestAction.new(:ImageButton_Show_6) do
  1832. $ruiObj = RUIObject.new.with('objectid', 1571666208).with('selfid', -929198491).with('textdescid', 2010273934).with('uniqueparentid', 0)
  1833. .with('uitreeindex', 0)
  1834. .with('classname', 'ImageButton')
  1835. .with('content-desc', 'Show roots')
  1836.  
  1837. $ruiObj.click
  1838.  
  1839. waitsecond(2)
  1840. end
  1841.  
  1842. tcase << TestAction.new(:TextView_Title_8) do
  1843. $ruiObj = RUIObject.new.with('objectid', -1941383373).with('selfid', 4082754).with('textdescid', 50769842).with('uniqueparentid', 0).with('classresourceid', 490183159)
  1844. .with('uitreeindex', 30)
  1845. .with('classname', 'TextView')
  1846. .with('resource-id', 'android:id/title')
  1847. .with('text', 'Photos')
  1848.  
  1849. $ruiObj.click
  1850.  
  1851. waitsecond(2)
  1852. end
  1853.  
  1854. tcase << TestAction.new(:Button_PermissionAllowButton_10) do
  1855. $ruiObj = RUIObject.new.with('objectid', -886457929).with('selfid', 1443382411).with('textdescid', 270556320).with('uniqueparentid', 0)
  1856. .with('uitreeindex', 3)
  1857. .with('classname', 'Button')
  1858. .with('resource-id', 'com.android.packageinstaller:id/permission_allow_button')
  1859. .with('text', 'ALLOW')
  1860.  
  1861. $ruiObj.click
  1862.  
  1863. waitsecond(2)
  1864. end
  1865.  
  1866. tcase << TestAction.new(:TextView_Title_24) do
  1867. $ruiObj = RUIObject.new.with('objectid', -2074516409).with('selfid', 1224707480).with('textdescid', 1793532939).with('uniqueparentid', 0)
  1868. .with('uitreeindex', 4)
  1869. .with('classname', 'TextView')
  1870. .with('resource-id', 'com.google.android.apps.photos:id/title')
  1871. .with('text', '10M')
  1872.  
  1873. $ruiObj.click
  1874.  
  1875. waitsecond(2)
  1876. end
  1877.  
  1878. tcase << TestAction.new(:clickXY_232_736_16) do
  1879. click(232,736)
  1880.  
  1881. waitsecond(2)
  1882. end
  1883.  
  1884. tcase << TestAction.new(:TrimAndSave) do
  1885. $reduceButton = RUIObject.new.with('objectid', -1505530336).with('selfid', 1382949486).with('textdescid', 185347450).with('uniqueparentid', 0)
  1886. .with('uitreeindex', 3)
  1887. .with('classname', 'Button')
  1888. .with('resource-id', 'android:id/button1')
  1889. .with('text', 'REDUCE')
  1890.  
  1891. if $reduceButton.isExist
  1892. $reduceButton.click
  1893.  
  1894. waitsecond(1)
  1895.  
  1896. RUIObject.new.with('objectid', -886457929).with('selfid', 1443382411).with('textdescid', 270556320).with('uniqueparentid', 0)
  1897. .with('uitreeindex', 3)
  1898. .with('classname', 'Button')
  1899. .with('resource-id', 'com.android.packageinstaller:id/permission_allow_button')
  1900. .with('text', 'ALLOW').click
  1901.  
  1902. waitsecond(1)
  1903.  
  1904. RUIObject.new.with('objectid', -2139312908).with('selfid', 893316343).with('textdescid', -1979207657).with('uniqueparentid', 0)
  1905. .with('uitreeindex', 28)
  1906. .with('classname', 'Button')
  1907. .with('resource-id', 'com.lge.videostudio:id/trim_area_save')
  1908. .with('text', 'SAVE').click
  1909.  
  1910. end
  1911.  
  1912. waitsecond(2)
  1913. end
  1914.  
  1915. tcase << TestAction.new(:Button_TrimAreaSave_4) do
  1916. $ruiObj = RUIObject.new.with('objectid', -1223836307).with('selfid', 892882684).with('textdescid', 865181803).with('uniqueparentid', 0)
  1917. .with('uitreeindex', 31)
  1918. .with('classname', 'Button')
  1919. .with('resource-id', 'com.lge.videostudio:id/trim_area_save')
  1920. .with('text', 'DONE')
  1921.  
  1922. $ruiObj.click
  1923.  
  1924. waitsecond(2)
  1925. end
  1926.  
  1927. tcase << TestAction.new(:Button_SendButtonText_6) do
  1928. $ruiObj = RUIObject.new.with('objectid', -1452330871).with('selfid', 742186862).with('textdescid', -1346972937).with('uniqueparentid', 0)
  1929. .with('uitreeindex', 11)
  1930. .with('classname', 'Button')
  1931. .with('resource-id', 'com.android.mms:id/send_button_text')
  1932. .with('content-desc', 'Send')
  1933. .with('text', 'Send')
  1934.  
  1935. $ruiObj.click
  1936.  
  1937. waitsecond(2)
  1938. end
  1939.  
  1940. tcase << TestAction.new(:pressBack_8) do
  1941. pressBack
  1942.  
  1943. waitsecond(2)
  1944. end
  1945.  
  1946. tcase << TestAction.new(:pressBack_10) do
  1947. pressBack
  1948.  
  1949. waitsecond(2)
  1950. end
  1951.  
  1952. tcase << TestAction.new(:clickXY_166_220_5) do
  1953. click(166,220)
  1954.  
  1955. waitsecond(1)
  1956. end
  1957.  
  1958. tcase << TestAction.new(:LinearLayout_StatusIcons_10) do
  1959. $ruiObj = RUIObject.new.with('objectid', 84459867).with('selfid', 906570047).with('textdescid', -1676711387).with('uniqueparentid', 0).with('classresourceid', 1331229891)
  1960. .with('classname', 'LinearLayout')
  1961. .with('resource-id', 'com.android.mms:id/status_icons')
  1962.  
  1963. $ruiObj.isNotExist
  1964.  
  1965. waitsecond(1)
  1966. end
  1967.  
  1968. tcase << TestAction.new(:TextView_Delete_12) do
  1969. $ruiObj = RUIObject.new.with('objectid', -1337172653).with('selfid', 1644806947).with('textdescid', -2074083528).with('uniqueparentid', 0)
  1970. .with('uitreeindex', 4)
  1971. .with('classname', 'TextView')
  1972. .with('content-desc', 'Delete')
  1973.  
  1974. $ruiObj.click
  1975.  
  1976. waitsecond(1)
  1977. end
  1978.  
  1979. tcase << TestAction.new(:Button_Button1_12) do
  1980. $ruiObj = RUIObject.new.with('objectid', -1505530336).with('selfid', 982364851).with('textdescid', 652125653).with('uniqueparentid', 0)
  1981. .with('uitreeindex', 2)
  1982. .with('classname', 'Button')
  1983. .with('resource-id', 'android:id/button1')
  1984. .with('text', 'DELETE')
  1985.  
  1986. $ruiObj.click
  1987.  
  1988. waitsecond(2)
  1989. end
  1990.  
  1991. tcase << TestAction.new(:scriptAction_30_1) do
  1992. $myTestResult = checkLastExistResult
  1993.  
  1994. if $myTestResult == false
  1995. $myFailReason = "Message not sent"
  1996. end
  1997. logStopTest("Messaging_05_01_02_05")
  1998. end
  1999.  
  2000. tcase << TestAction.new(:pressBack_53) do
  2001. pressBack
  2002. end
  2003.  
  2004. tcase << TestAction.new(:pressBack_26) do
  2005. pressBack
  2006. end
  2007.  
  2008. tcase << TestAction.new(:pressHome_12) do
  2009. pressHome
  2010. end
  2011.  
  2012. tcase.run(loopTime)
  2013.  
  2014. end
  2015.  
  2016. def self.Messaging_05_01_02_06(loopTime)
  2017.  
  2018. tcase = TestCase.new("Messaging_05_01_02_06")
  2019.  
  2020. tcase << TestAction.new(:scriptAction_28) do
  2021. logStartTest("Messaging_05_01_02_06")
  2022. end
  2023.  
  2024. tcase << TestAction.new(:gotoApp_2) do
  2025. gotoApp('Messaging')
  2026.  
  2027. waitsecond(1)
  2028. end
  2029.  
  2030. tcase << TestAction.new(:ComposeNewMessage_1_1) do
  2031. $tmusComposeButton = RUIObject.new.with('objectid', -547009504).with('selfid', 1638137891).with('textdescid', 1140939687).with('uniqueparentid', 0)
  2032. .with('uitreeindex', 5)
  2033. .with('classname', 'ImageView')
  2034. .with('resource-id', 'com.android.mms:id/fab_img')
  2035. .with('content-desc', 'New message')
  2036.  
  2037. $vzwComposeButton = RUIObject.new.with('objectid', 2129085589).with('selfid', 468961841).with('textdescid', -293661237).with('uniqueparentid', 0)
  2038. .with('uitreeindex', 5)
  2039. .with('classname', 'ImageView')
  2040. .with('resource-id', 'com.android.mms:id/img1')
  2041. .with('content-desc', 'Compose button')
  2042.  
  2043. if $tmusComposeButton.isExist
  2044. $tmusComposeButton.click
  2045. elsif $vzwComposeButton.isExist
  2046. $vzwComposeButton.click
  2047. end
  2048.  
  2049. waitsecond(2)
  2050. end
  2051.  
  2052. tcase << TestAction.new(:MultiAutoCompleteTextView_2) do
  2053. $ruiObj = RUIObject.new.with('objectid', -2030797265).with('selfid', -1346021293).with('textdescid', 1469794257).with('uniqueparentid', 0).with('classresourceid', -1346021293)
  2054. .with('uitreeindex', 0)
  2055. .with('classname', 'MultiAutoCompleteTextView')
  2056.  
  2057. $ruiObj.inputtext('A01 a01')
  2058.  
  2059. waitsecond(1)
  2060. end
  2061.  
  2062. tcase << TestAction.new(:clickXY_92_192_6) do
  2063. click(92,192)
  2064.  
  2065. waitsecond(1)
  2066. end
  2067.  
  2068. tcase << TestAction.new(:EditText_Enter_8) do
  2069. $ruiObj = RUIObject.new.with('objectid', -1637280020).with('selfid', -454502120).with('textdescid', -1217933909).with('uniqueparentid', 0).with('classresourceid', 1666676343)
  2070. .with('uitreeindex', 5)
  2071. .with('classname', 'EditText')
  2072. .with('content-desc', 'Enter message')
  2073.  
  2074. $ruiObj.click
  2075.  
  2076. waitsecond(1)
  2077. end
  2078.  
  2079. tcase << TestAction.new(:scriptAction_141_1) do
  2080. $ruiObj.inputtext('Abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzaaaaaaaaaabbbbbbbbbbcccccccccc')
  2081.  
  2082. waitsecond(1)
  2083. end
  2084.  
  2085. tcase << TestAction.new(:AttachButton_1) do
  2086. $tmusAttachButton = RUIObject.new.with('objectid', 874172794).with('selfid', -1211001229).with('textdescid', -704319221).with('uniqueparentid', 0)
  2087. .with('uitreeindex', 6)
  2088. .with('classname', 'ImageButton')
  2089. .with('resource-id', 'com.android.mms:id/attachButton_right')
  2090. .with('content-desc', 'Attach')
  2091.  
  2092. $vzwAttachButton = RUIObject.new.with('objectid', 1000615746).with('selfid', -876235136).with('textdescid', -1072393149).with('uniqueparentid', 0)
  2093. .with('uitreeindex', 5)
  2094. .with('classname', 'ImageButton')
  2095. .with('resource-id', 'com.android.mms:id/attachButton_left')
  2096. .with('content-desc', 'Attach')
  2097.  
  2098. if $tmusAttachButton.isExist
  2099. $tmusAttachButton.click
  2100. elsif $vzwAttachButton.isExist
  2101. $vzwAttachButton.click
  2102. end
  2103.  
  2104. waitsecond(2)
  2105. end
  2106.  
  2107. tcase << TestAction.new(:ImageView_Icon_2) do
  2108. $ruiObj = RUIObject.new.with('objectid', -1141961992).with('selfid', -465694566).with('textdescid', -1041083352).with('uniqueparentid', 0)
  2109. .with('uitreeindex', 1)
  2110. .with('pretext', 'Attach')
  2111. .with('classname', 'ImageView')
  2112. .with('resource-id', 'com.android.mms:id/icon')
  2113.  
  2114. $ruiObj.click
  2115.  
  2116. waitsecond(4)
  2117. end
  2118.  
  2119. tcase << TestAction.new(:Button_PermissionAllowButton_6) do
  2120. $ruiObj = RUIObject.new.with('objectid', 973397371).with('selfid', 1444367499).with('textdescid', -1740624804).with('uniqueparentid', 0)
  2121. .with('uitreeindex', 3)
  2122. .with('classname', 'Button')
  2123. .with('resource-id', 'com.android.packageinstaller:id/permission_allow_button')
  2124. .with('text', 'Allow')
  2125.  
  2126. $ruiObj.click
  2127. end
  2128.  
  2129. tcase << TestAction.new(:ImageButton_Show_6) do
  2130. $ruiObj = RUIObject.new.with('objectid', -1807230859).with('selfid', -929198491).with('textdescid', 629574489).with('uniqueparentid', 0)
  2131. .with('uitreeindex', 0)
  2132. .with('classname', 'ImageButton')
  2133. .with('content-desc', 'Show roots')
  2134.  
  2135. $ruiObj.click
  2136.  
  2137. waitsecond(1)
  2138. end
  2139.  
  2140. tcase << TestAction.new(:TextView_Title_3) do
  2141. $ruiObj = RUIObject.new.with('objectid', -1941383373).with('selfid', 4082754).with('textdescid', 50769842).with('uniqueparentid', 0).with('classresourceid', 490183159)
  2142. .with('uitreeindex', 44)
  2143. .with('classname', 'TextView')
  2144. .with('resource-id', 'android:id/title')
  2145. .with('text', 'Photos')
  2146.  
  2147. $ruiObj.click
  2148.  
  2149. waitsecond(2)
  2150. end
  2151.  
  2152. tcase << TestAction.new(:TextView_Title_5) do
  2153. $ruiObj = RUIObject.new.with('objectid', -2074516409).with('selfid', -1484513934).with('textdescid', 889140747).with('uniqueparentid', 0)
  2154. .with('uitreeindex', 10)
  2155. .with('classname', 'TextView')
  2156. .with('resource-id', 'com.google.android.apps.photos:id/title')
  2157. .with('text', '1M')
  2158.  
  2159. $ruiObj.click
  2160.  
  2161. waitsecond(2)
  2162. end
  2163.  
  2164. tcase << TestAction.new(:clickXY_248_752_9) do
  2165. click(248,752)
  2166.  
  2167. waitsecond(2)
  2168. end
  2169.  
  2170. tcase << TestAction.new(:TextView_DoneButton_2) do
  2171. $ruiObj = RUIObject.new.with('objectid', -958387193).with('selfid', -885365197).with('textdescid', 1900114073).with('uniqueparentid', 0)
  2172. .with('uitreeindex', 11)
  2173. .with('classname', 'TextView')
  2174. .with('resource-id', 'com.google.android.apps.photos:id/done_button')
  2175. .with('content-desc', 'Done')
  2176. .with('text', 'DONE')
  2177.  
  2178. $ruiObj.click
  2179.  
  2180. waitsecond(2)
  2181. end
  2182.  
  2183. tcase << TestAction.new(:SendButton_1_1) do
  2184. $tmusSendButton = RUIObject.new.with('objectid', 353843972).with('selfid', 742186862).with('textdescid', -1914765924).with('uniqueparentid', 0)
  2185. .with('uitreeindex', 8)
  2186. .with('classname', 'Button')
  2187. .with('resource-id', 'com.android.mms:id/send_button_text')
  2188. .with('content-desc', 'Send')
  2189. .with('text', 'Send')
  2190.  
  2191. $vzwSendButton = RUIObject.new.with('objectid', 1247717607).with('selfid', -817858366).with('textdescid', -1713609473).with('uniqueparentid', 0)
  2192. .with('uitreeindex', 8)
  2193. .with('classname', 'Button')
  2194. .with('resource-id', 'com.android.mms:id/send_button')
  2195. .with('text', 'Send')
  2196.  
  2197. if $tmusSendButton.isExist
  2198. $tmusSendButton.click
  2199. elsif $vzwSendButton.isExist
  2200. $vzwSendButton.click
  2201. end
  2202.  
  2203. waitsecond(4)
  2204. end
  2205.  
  2206. tcase << TestAction.new(:pressBack_5) do
  2207. pressBack
  2208. end
  2209.  
  2210. tcase << TestAction.new(:pressBack_6) do
  2211. pressBack
  2212. end
  2213.  
  2214. tcase << TestAction.new(:clickXY_158_230_12) do
  2215. click(158,230)
  2216.  
  2217. waitsecond(1)
  2218. end
  2219.  
  2220. tcase << TestAction.new(:ProgressBar_Progressbar_6) do
  2221. $ruiObj = RUIObject.new.with('objectid', -1692373424).with('selfid', 1538496395).with('textdescid', -923968560).with('uniqueparentid', 0).with('classresourceid', 225978681)
  2222. .with('uitreeindex', 10)
  2223. .with('classname', 'ProgressBar')
  2224. .with('resource-id', 'com.android.mms:id/progressbar')
  2225.  
  2226. $ruiObj.isNotExist
  2227. end
  2228.  
  2229. tcase << TestAction.new(:TextView_Delete_8) do
  2230. $ruiObj = RUIObject.new.with('objectid', -1337172653).with('selfid', 1644806947).with('textdescid', -2074083528).with('uniqueparentid', 0)
  2231. .with('uitreeindex', 4)
  2232. .with('classname', 'TextView')
  2233. .with('content-desc', 'Delete')
  2234.  
  2235. $ruiObj.click
  2236.  
  2237. waitsecond(1)
  2238. end
  2239.  
  2240. tcase << TestAction.new(:Button_Button1_4) do
  2241. $ruiObj = RUIObject.new.with('objectid', 72365522).with('selfid', 982364851).with('textdescid', 46766983).with('uniqueparentid', 0).with('classresourceid', 1834539358)
  2242. .with('uitreeindex', 2)
  2243. .with('classname', 'Button')
  2244. .with('resource-id', 'android:id/button1')
  2245. .with('text', 'DELETE')
  2246.  
  2247. $ruiObj.click
  2248.  
  2249. waitsecond(2)
  2250. end
  2251.  
  2252. tcase << TestAction.new(:scriptAction_30_1) do
  2253. $myTestResult = checkLastExistResult
  2254.  
  2255. if $myTestResult == false
  2256. $myFailReason = "End button not found"
  2257. end
  2258. logStopTest("Messaging_05_01_02_06")
  2259. end
  2260.  
  2261. tcase << TestAction.new(:pressBack_53) do
  2262. pressBack
  2263. end
  2264.  
  2265. tcase << TestAction.new(:pressBack_26) do
  2266. pressBack
  2267. end
  2268.  
  2269. tcase << TestAction.new(:pressHome_6) do
  2270. pressHome
  2271. end
  2272.  
  2273. tcase.run(loopTime)
  2274.  
  2275. end
  2276.  
  2277. def self.MultiMedia_05_01_07_01(loopTime)
  2278.  
  2279. tcase = TestCase.new("MultiMedia_05_01_07_01")
  2280.  
  2281. tcase << TestAction.new(:scriptAction_1) do
  2282. logStartTest("05_01_07_01_MultiMedia")
  2283. end
  2284.  
  2285. tcase << TestAction.new(:gotoApp_1) do
  2286. gotoApp('Camera')
  2287. end
  2288.  
  2289. tcase << TestAction.new(:Button_CancelButton_23) do
  2290. $ruiObj = RUIObject.new.with('objectid', 2138780457).with('selfid', 765132311).with('textdescid', -782727157).with('uniqueparentid', 0)
  2291. .with('uitreeindex', 3)
  2292. .with('classname', 'Button')
  2293. .with('resource-id', 'com.lge.camera:id/cancel_button')
  2294. .with('text', 'LATER')
  2295.  
  2296. $ruiObj.click
  2297.  
  2298. waitsecond(2)
  2299. end
  2300.  
  2301. tcase << TestAction.new(:Button_PermissionAllowButton_4) do
  2302. $ruiObj = RUIObject.new.with('objectid', 973397371).with('selfid', 1444367499).with('textdescid', -1740624804).with('uniqueparentid', 0)
  2303. .with('uitreeindex', 3)
  2304. .with('classname', 'Button')
  2305. .with('resource-id', 'com.android.packageinstaller:id/permission_allow_button')
  2306. .with('text', 'Allow')
  2307.  
  2308. $ruiObj.click
  2309.  
  2310. waitsecond(1)
  2311. end
  2312.  
  2313. tcase << TestAction.new(:Button_CancelButton_2) do
  2314. $ruiObj = RUIObject.new.with('objectid', -1613946387).with('selfid', -1673499114).with('textdescid', -814734932).with('uniqueparentid', 0)
  2315. .with('uitreeindex', 3)
  2316. .with('classname', 'Button')
  2317. .with('resource-id', 'com.lge.camera:id/cancel_button')
  2318. .with('text', 'No')
  2319.  
  2320. $ruiObj.click
  2321.  
  2322. waitsecond(1)
  2323. end
  2324.  
  2325. tcase << TestAction.new(:ImageView_Thumbnail_2) do
  2326. $ruiObj = RUIObject.new.with('objectid', -2123601541).with('selfid', -135259702).with('textdescid', 357252685).with('uniqueparentid', 0)
  2327. .with('uitreeindex', 17)
  2328. .with('classname', 'ImageView')
  2329. .with('resource-id', 'com.lge.camera:id/thumbnail')
  2330. .with('content-desc', 'Gallery')
  2331.  
  2332. $ruiObj.isNotExist
  2333. ifFailJumpTo(:shutter)
  2334.  
  2335. waitsecond(1)
  2336. end
  2337.  
  2338. tcase << TestAction.new(:ImageButton_QuickButtonCleanView_2) do
  2339. $ruiObj = RUIObject.new.with('objectid', 579583575).with('selfid', -1659256094).with('textdescid', -1654112402).with('uniqueparentid', 0)
  2340. .with('uitreeindex', 1)
  2341. .with('classname', 'ImageButton')
  2342. .with('resource-id', 'com.lge.camera:id/quick_button_clean_view')
  2343. .with('content-desc', 'View')
  2344.  
  2345. $ruiObj.click
  2346.  
  2347. waitsecond(1)
  2348. end
  2349.  
  2350. tcase << TestAction.new(:shutter) do
  2351. $ruiObj = RUIObject.new.with('objectid', -1799776401).with('selfid', -1818636331).with('textdescid', -839551902).with('uniqueparentid', 0)
  2352. .with('uitreeindex', 13)
  2353. .with('classname', 'ImageButton')
  2354. .with('resource-id', 'com.lge.camera:id/shutter_top_comp')
  2355. .with('content-desc', 'Start recording')
  2356.  
  2357. $ruiObj.click
  2358.  
  2359. waitsecond(1)
  2360. end
  2361.  
  2362. tcase << TestAction.new(:wait30second_14) do
  2363. waitsecond(30)
  2364. end
  2365.  
  2366. tcase << TestAction.new(:ImageButton_ShutterTopComp_6) do
  2367. $ruiObj = RUIObject.new.with('objectid', -1799776401).with('selfid', -1930433243).with('textdescid', 415097668).with('uniqueparentid', 0)
  2368. .with('uitreeindex', 5)
  2369. .with('pretext', '000008')
  2370. .with('classname', 'ImageButton')
  2371. .with('resource-id', 'com.lge.camera:id/shutter_top_comp')
  2372. .with('content-desc', 'Stop recording')
  2373.  
  2374. $ruiObj.isExist
  2375. end
  2376.  
  2377. tcase << TestAction.new(:ImageButton_ShutterTopCompType_6) do
  2378. $ruiObj = RUIObject.new.with('objectid', -1695967134).with('selfid', 685856113).with('textdescid', -1035373570).with('uniqueparentid', 0)
  2379. .with('uitreeindex', 10)
  2380. .with('classname', 'ImageButton')
  2381. .with('resource-id', 'com.lge.camera:id/shutter_top_comp_type')
  2382.  
  2383. $ruiObj.click
  2384.  
  2385. waitsecond(2)
  2386. end
  2387.  
  2388. tcase << TestAction.new(:scriptAction_5) do
  2389. $myTestResult = checkLastExistResult
  2390.  
  2391. if $myTestResult == false
  2392. $myFailReason == "Video does not exist"
  2393. end
  2394. logStopTest("05_01_07_01_MultiMedia")
  2395. end
  2396.  
  2397. tcase << TestAction.new(:pressBack_6) do
  2398. pressBack
  2399. end
  2400.  
  2401. tcase << TestAction.new(:pressBack_7) do
  2402. pressBack
  2403. end
  2404.  
  2405. tcase << TestAction.new(:pressHome_8) do
  2406. pressHome
  2407. end
  2408.  
  2409. tcase.run(loopTime)
  2410.  
  2411. end
  2412.  
  2413. def self.MultiMedia_05_01_07_02(loopTime)
  2414.  
  2415. tcase = TestCase.new("MultiMedia_05_01_07_02")
  2416.  
  2417. tcase << TestAction.new(:scriptAction_1) do
  2418. logStartTest("05_01_07_02_MultiMedia")
  2419. end
  2420.  
  2421. tcase << TestAction.new(:gotoApp_1) do
  2422. gotoApp('Gallery')
  2423.  
  2424. waitsecond(2)
  2425. end
  2426.  
  2427. tcase << TestAction.new(:Button_PermissionAllowButton_2) do
  2428. $ruiObj = RUIObject.new.with('objectid', 973397371).with('selfid', 1444367499).with('textdescid', -1740624804).with('uniqueparentid', 0)
  2429. .with('uitreeindex', 3)
  2430. .with('classname', 'Button')
  2431. .with('resource-id', 'com.android.packageinstaller:id/permission_allow_button')
  2432. .with('text', 'Allow')
  2433.  
  2434. $ruiObj.click
  2435. end
  2436.  
  2437. tcase << TestAction.new(:ImageButton_Open_2) do
  2438. $ruiObj = RUIObject.new.with('objectid', -1596683477).with('selfid', 1589392844).with('textdescid', 426502620).with('uniqueparentid', 0)
  2439. .with('uitreeindex', 1)
  2440. .with('classname', 'ImageButton')
  2441. .with('content-desc', 'Open navigation drawer')
  2442.  
  2443. $ruiObj.click
  2444.  
  2445. waitsecond(2)
  2446. end
  2447.  
  2448. tcase << TestAction.new(:CheckedTextView_DrawerItem_4) do
  2449. $ruiObj = RUIObject.new.with('objectid', -401550358).with('selfid', 229733217).with('textdescid', 1081503090).with('uniqueparentid', 0).with('classresourceid', 396870609)
  2450. .with('uitreeindex', 4)
  2451. .with('classname', 'CheckedTextView')
  2452. .with('resource-id', 'com.android.gallery3d:id/drawer_item')
  2453. .with('text', 'Videos')
  2454.  
  2455. $ruiObj.click
  2456.  
  2457. waitsecond(2)
  2458. end
  2459.  
  2460. tcase << TestAction.new(:clickXY_572_388_2) do
  2461. click(572,388)
  2462.  
  2463. waitsecond(2)
  2464. end
  2465.  
  2466. tcase << TestAction.new(:clickXY_640_560_2) do
  2467. click(640,560)
  2468.  
  2469. waitsecond(2)
  2470. end
  2471.  
  2472. tcase << TestAction.new(:TextView_ResolverText_6) do
  2473. $ruiObj = RUIObject.new.with('objectid', 1736845148).with('selfid', 1334281818).with('textdescid', 234547305).with('uniqueparentid', 0).with('classresourceid', -472389065)
  2474. .with('uitreeindex', 4)
  2475. .with('classname', 'TextView')
  2476. .with('resource-id', 'com.lge:id/resolver_text')
  2477. .with('text', 'Video')
  2478.  
  2479. $ruiObj.click
  2480.  
  2481. waitsecond(2)
  2482. end
  2483.  
  2484. tcase << TestAction.new(:Button_AllowButton_9) do
  2485. $ruiObj = RUIObject.new.with('objectid', -1049422851).with('selfid', -808516471).with('textdescid', -374437087).with('uniqueparentid', 0).with('classresourceid', 771022871)
  2486. .with('uitreeindex', 8)
  2487. .with('classname', 'Button')
  2488. .with('resource-id', 'com.lge:id/allow_button')
  2489. .with('text', 'OK')
  2490.  
  2491. $ruiObj.click
  2492.  
  2493. waitsecond(1)
  2494. end
  2495.  
  2496. tcase << TestAction.new(:Button_PermissionAllowButton_11) do
  2497. $ruiObj = RUIObject.new.with('objectid', -886457929).with('selfid', 1443382411).with('textdescid', 270556320).with('uniqueparentid', 0)
  2498. .with('uitreeindex', 3)
  2499. .with('classname', 'Button')
  2500. .with('resource-id', 'com.android.packageinstaller:id/permission_allow_button')
  2501. .with('text', 'ALLOW')
  2502.  
  2503. $ruiObj.click
  2504. end
  2505.  
  2506. tcase << TestAction.new(:wait10second_4) do
  2507. waitsecond(10)
  2508. end
  2509.  
  2510. tcase << TestAction.new(:clickXY_296_832_8) do
  2511. click(296,832)
  2512.  
  2513. waitsecond(1)
  2514. end
  2515.  
  2516. tcase << TestAction.new(:ImageButton_Pause_10) do
  2517. $ruiObj = RUIObject.new.with('objectid', 321323694).with('selfid', -485281624).with('textdescid', 2077043940).with('uniqueparentid', 0)
  2518. .with('uitreeindex', 3)
  2519. .with('pretext', 'Videos')
  2520. .with('classname', 'ImageButton')
  2521. .with('resource-id', 'com.lge.videoplayer:id/pause')
  2522. .with('content-desc', 'Pause')
  2523.  
  2524. $ruiObj.isExist
  2525.  
  2526. waitsecond(1)
  2527. end
  2528.  
  2529. tcase << TestAction.new(:scriptAction_7) do
  2530. $myTestResult = checkLastExistResult
  2531.  
  2532. if $myTestResult == false
  2533. $myFailReason = "Video did not play successfuly"
  2534. end
  2535. logStopTest("05_01_07_02_MultiMedia")
  2536. end
  2537.  
  2538. tcase << TestAction.new(:pressBack_8) do
  2539. pressBack
  2540. end
  2541.  
  2542. tcase << TestAction.new(:pressBack_9) do
  2543. pressBack
  2544. end
  2545.  
  2546. tcase << TestAction.new(:pressHome_10) do
  2547. pressHome
  2548. end
  2549.  
  2550. tcase.run(loopTime)
  2551.  
  2552. end
  2553.  
  2554. def self.MultiMedia_05_01_07_03(loopTime)
  2555.  
  2556. tcase = TestCase.new("MultiMedia_05_01_07_03")
  2557.  
  2558. tcase << TestAction.new(:scriptAction_1) do
  2559. logStartTest("05_01_07_03_MultiMedia")
  2560. end
  2561.  
  2562. tcase << TestAction.new(:gotoApp_1) do
  2563. gotoApp('Camera')
  2564.  
  2565. waitsecond(2)
  2566. end
  2567.  
  2568. tcase << TestAction.new(:ImageView_Thumbnail_2) do
  2569. $ruiObj = RUIObject.new.with('objectid', -2123601541).with('selfid', -135259702).with('textdescid', 357252685).with('uniqueparentid', 0)
  2570. .with('uitreeindex', 15)
  2571. .with('classname', 'ImageView')
  2572. .with('resource-id', 'com.lge.camera:id/thumbnail')
  2573. .with('content-desc', 'Gallery')
  2574.  
  2575. $ruiObj.click
  2576.  
  2577. waitsecond(2)
  2578. end
  2579.  
  2580. tcase << TestAction.new(:TextView_ResolverText_2) do
  2581. $ruiObj = RUIObject.new.with('objectid', 1736845148).with('selfid', 1695477105).with('textdescid', -880470158).with('uniqueparentid', 0).with('classresourceid', -472389065)
  2582. .with('uitreeindex', 2)
  2583. .with('classname', 'TextView')
  2584. .with('resource-id', 'com.lge:id/resolver_text')
  2585. .with('text', 'Gallery')
  2586.  
  2587. $ruiObj.click
  2588.  
  2589. waitsecond(2)
  2590. end
  2591.  
  2592. tcase << TestAction.new(:Button_AllowButton_4) do
  2593. $ruiObj = RUIObject.new.with('objectid', -1049422851).with('selfid', -808516471).with('textdescid', -374437087).with('uniqueparentid', 0).with('classresourceid', 771022871)
  2594. .with('uitreeindex', 8)
  2595. .with('classname', 'Button')
  2596. .with('resource-id', 'com.lge:id/allow_button')
  2597. .with('text', 'OK')
  2598.  
  2599. $ruiObj.click
  2600.  
  2601. waitsecond(2)
  2602. end
  2603.  
  2604. tcase << TestAction.new(:clickXY_196_782_2) do
  2605. click(196,782)
  2606.  
  2607. waitsecond(2)
  2608. end
  2609.  
  2610. tcase << TestAction.new(:Button_BottomMenuLayerItem5_2) do
  2611. $ruiObj = RUIObject.new.with('objectid', 786788493).with('selfid', -296540457).with('textdescid', -702028205).with('uniqueparentid', 0)
  2612. .with('uitreeindex', 4)
  2613. .with('classname', 'Button')
  2614. .with('resource-id', 'com.android.gallery3d:id/bottom_menu_layer_item5')
  2615. .with('content-desc', 'Delete')
  2616. .with('text', 'Delete')
  2617.  
  2618. $ruiObj.click
  2619.  
  2620. waitsecond(4)
  2621. end
  2622.  
  2623. tcase << TestAction.new(:scriptAction_4) do
  2624. $myTestResult = checkLastExistResult
  2625.  
  2626. if $myTestResult == false
  2627. $myFailReason == "Video fail to delete"
  2628. end
  2629. logStopTest("05_01_07_03_MultiMedia")
  2630. end
  2631.  
  2632. tcase << TestAction.new(:pressBack_5) do
  2633. pressBack
  2634. end
  2635.  
  2636. tcase << TestAction.new(:pressBack_6) do
  2637. pressBack
  2638. end
  2639.  
  2640. tcase << TestAction.new(:pressHome_7) do
  2641. pressHome
  2642. end
  2643.  
  2644. tcase.run(loopTime)
  2645.  
  2646. end
  2647.  
  2648. def self.MultiMedia_05_01_07_04(loopTime)
  2649.  
  2650. tcase = TestCase.new("MultiMedia_05_01_07_04")
  2651.  
  2652. tcase << TestAction.new(:scriptAction_1) do
  2653. logStartTest("05_01_07_04_MultiMedia")
  2654. end
  2655.  
  2656. tcase << TestAction.new(:gotoApp_1) do
  2657. gotoApp('Camera')
  2658. end
  2659.  
  2660. tcase << TestAction.new(:Button_OkButton_2_1) do
  2661. $ruiObj = RUIObject.new.with('objectid', -658747592).with('selfid', 659685775).with('textdescid', -384972794).with('uniqueparentid', 0)
  2662. .with('uitreeindex', 22)
  2663. .with('classname', 'Button')
  2664. .with('resource-id', 'com.lge.camera:id/ok_button')
  2665. .with('text', 'Turn on')
  2666.  
  2667. $ruiObj.click
  2668.  
  2669. waitsecond(1)
  2670. end
  2671.  
  2672. tcase << TestAction.new(:Button_PermissionAllowButton_4_1) do
  2673. $ruiObj = RUIObject.new.with('objectid', 973397371).with('selfid', 1444367499).with('textdescid', -1740624804).with('uniqueparentid', 0)
  2674. .with('uitreeindex', 3)
  2675. .with('classname', 'Button')
  2676. .with('resource-id', 'com.android.packageinstaller:id/permission_allow_button')
  2677. .with('text', 'Allow')
  2678.  
  2679. $ruiObj.click
  2680.  
  2681. waitsecond(1)
  2682. end
  2683.  
  2684. tcase << TestAction.new(:ImageButton_ShutterBottomCompType_2) do
  2685. $ruiObj = RUIObject.new.with('objectid', 215322368).with('selfid', -857985467).with('textdescid', -1914941152).with('uniqueparentid', 0)
  2686. .with('uitreeindex', 10)
  2687. .with('classname', 'ImageButton')
  2688. .with('resource-id', 'com.lge.camera:id/shutter_bottom_comp_type')
  2689.  
  2690. $ruiObj.click
  2691.  
  2692. waitsecond(2)
  2693. end
  2694.  
  2695. tcase << TestAction.new(:ImageView_Thumbnail_1_1) do
  2696. $ruiObj = RUIObject.new.with('objectid', -2123601541).with('selfid', -135259702).with('textdescid', 357252685).with('uniqueparentid', 0)
  2697. .with('uitreeindex', 15)
  2698. .with('classname', 'ImageView')
  2699. .with('resource-id', 'com.lge.camera:id/thumbnail')
  2700. .with('content-desc', 'Gallery')
  2701.  
  2702. $ruiObj.click
  2703.  
  2704. waitsecond(2)
  2705. end
  2706.  
  2707. tcase << TestAction.new(:TextView_ResolverText_2_1) do
  2708. $ruiObj = RUIObject.new.with('objectid', 1736845148).with('selfid', 1695477105).with('textdescid', -880470158).with('uniqueparentid', 0).with('classresourceid', -472389065)
  2709. .with('uitreeindex', 2)
  2710. .with('classname', 'TextView')
  2711. .with('resource-id', 'com.lge:id/resolver_text')
  2712. .with('text', 'Gallery')
  2713.  
  2714. $ruiObj.click
  2715.  
  2716. waitsecond(2)
  2717. end
  2718.  
  2719. tcase << TestAction.new(:Button_AllowButton_3_1) do
  2720. $ruiObj = RUIObject.new.with('objectid', -1049422851).with('selfid', -808516471).with('textdescid', -374437087).with('uniqueparentid', 0).with('classresourceid', 771022871)
  2721. .with('uitreeindex', 8)
  2722. .with('classname', 'Button')
  2723. .with('resource-id', 'com.lge:id/allow_button')
  2724. .with('text', 'OK')
  2725.  
  2726. $ruiObj.click
  2727.  
  2728. waitsecond(2)
  2729. end
  2730.  
  2731. tcase << TestAction.new(:scriptAction_10) do
  2732. $myTestResult = checkLastExistResult
  2733.  
  2734. if $myTestResult == false
  2735. $myFailReason == "Take picture FAILED"
  2736. end
  2737. logStopTest("05_01_07_04_MultiMedia")
  2738. end
  2739.  
  2740. tcase << TestAction.new(:pressBack_11) do
  2741. pressBack
  2742. end
  2743.  
  2744. tcase << TestAction.new(:pressBack_12) do
  2745. pressBack
  2746. end
  2747.  
  2748. tcase << TestAction.new(:pressHome_13) do
  2749. pressHome
  2750. end
  2751.  
  2752. tcase.run(loopTime)
  2753.  
  2754. end
  2755.  
  2756. def self.MultiMedia_05_01_07_05(loopTime)
  2757.  
  2758. tcase = TestCase.new("MultiMedia_05_01_07_05")
  2759.  
  2760. tcase << TestAction.new(:scriptAction_1) do
  2761. logStartTest("05_01_07_05_MultiMedia")
  2762. end
  2763.  
  2764. tcase << TestAction.new(:scriptAction_4) do
  2765. gotoApp("Gallery")
  2766.  
  2767. waitsecond(2)
  2768. end
  2769.  
  2770. tcase << TestAction.new(:Button_Button1_6) do
  2771. $ruiObj = RUIObject.new.with('objectid', 1034541174).with('selfid', -1318451484).with('textdescid', 730622746).with('uniqueparentid', 0)
  2772. .with('uitreeindex', 3)
  2773. .with('classname', 'Button')
  2774. .with('resource-id', 'android:id/button1')
  2775. .with('text', 'OK')
  2776.  
  2777. $ruiObj.click
  2778.  
  2779. waitsecond(2)
  2780. end
  2781.  
  2782. tcase << TestAction.new(:refresh) do
  2783. pressRecentApps
  2784.  
  2785. RUIObject.new.with('text', 'Gallery').click
  2786.  
  2787. waitsecond(2)
  2788. end
  2789.  
  2790. tcase << TestAction.new(:Button_AllowButton_4) do
  2791. $ruiObj = RUIObject.new.with('objectid', -1049422851).with('selfid', -808516471).with('textdescid', -374437087).with('uniqueparentid', 0).with('classresourceid', 771022871)
  2792. .with('uitreeindex', 8)
  2793. .with('classname', 'Button')
  2794. .with('resource-id', 'com.lge:id/allow_button')
  2795. .with('text', 'OK')
  2796.  
  2797. $ruiObj.click
  2798.  
  2799. waitsecond(2)
  2800. end
  2801.  
  2802. tcase << TestAction.new(:clickXY_270_678_2) do
  2803. click(270,678)
  2804.  
  2805. waitsecond(1)
  2806. end
  2807.  
  2808. tcase << TestAction.new(:TextView_ActionDelete_11) do
  2809. $ruiObj = RUIObject.new.with('objectid', -1653355804).with('selfid', -340367424).with('textdescid', 366757063).with('uniqueparentid', 0)
  2810. .with('uitreeindex', 5)
  2811. .with('classname', 'TextView')
  2812. .with('resource-id', 'com.android.gallery3d:id/action_delete')
  2813. .with('content-desc', 'Delete')
  2814.  
  2815. $ruiObj.isExist
  2816.  
  2817. waitsecond(0)
  2818. end
  2819.  
  2820. tcase << TestAction.new(:scriptAction_8) do
  2821. $myTestResult = checkLastExistResult
  2822.  
  2823. if $myTestResult == false
  2824. $myFailReason == "Picutre not open"
  2825. end
  2826. logStopTest("05_01_07_05_MultiMedia")
  2827. end
  2828.  
  2829. tcase << TestAction.new(:pressBack_9) do
  2830. pressBack
  2831. end
  2832.  
  2833. tcase << TestAction.new(:pressBack_10) do
  2834. pressBack
  2835. end
  2836.  
  2837. tcase << TestAction.new(:pressHome_11) do
  2838. pressHome
  2839. end
  2840.  
  2841. tcase << TestAction.new(:View_GlRootView_1) do
  2842. $ruiObj = RUIObject.new.with('objectid', -789837373).with('selfid', -1563922518).with('textdescid', 1284845245).with('uniqueparentid', 0)
  2843. .with('uitreeindex', 0)
  2844. .with('classname', 'android.view.View')
  2845. .with('resource-id', 'com.android.gallery3d:id/gl_root_view')
  2846.  
  2847. $ruiObj.click
  2848.  
  2849. waitsecond(2)
  2850. end
  2851.  
  2852. tcase.run(loopTime)
  2853.  
  2854. end
  2855.  
  2856. def self.MultiMedia_05_01_07_06(loopTime)
  2857.  
  2858. tcase = TestCase.new("MultiMedia_05_01_07_06")
  2859.  
  2860. tcase << TestAction.new(:scriptAction_1) do
  2861. logStartTest("05_01_07_06_MultiMedia")
  2862. end
  2863.  
  2864. tcase << TestAction.new(:gotoApp_1) do
  2865. gotoApp('Gallery')
  2866.  
  2867. waitsecond(2)
  2868. end
  2869.  
  2870. tcase << TestAction.new(:clickXY_266_620_2) do
  2871. click(266,620)
  2872.  
  2873. waitsecond(1)
  2874. end
  2875.  
  2876. tcase << TestAction.new(:TextView_ActionDelete_2) do
  2877. $ruiObj = RUIObject.new.with('objectid', -1653355804).with('selfid', -340367424).with('textdescid', 366757063).with('uniqueparentid', 0)
  2878. .with('uitreeindex', 5)
  2879. .with('classname', 'TextView')
  2880. .with('resource-id', 'com.android.gallery3d:id/action_delete')
  2881. .with('content-desc', 'Delete')
  2882.  
  2883. $ruiObj.isExist
  2884.  
  2885. waitsecond(0)
  2886. end
  2887.  
  2888. tcase << TestAction.new(:TextView_ActionDelete_4) do
  2889. $ruiObj = RUIObject.new.with('objectid', -1653355804).with('selfid', -340367424).with('textdescid', 366757063).with('uniqueparentid', 0)
  2890. .with('uitreeindex', 5)
  2891. .with('classname', 'TextView')
  2892. .with('resource-id', 'com.android.gallery3d:id/action_delete')
  2893. .with('content-desc', 'Delete')
  2894.  
  2895. $ruiObj.click
  2896.  
  2897. waitsecond(2)
  2898. end
  2899.  
  2900. tcase << TestAction.new(:Button_Button1_6) do
  2901. $ruiObj = RUIObject.new.with('objectid', -1700448190).with('selfid', 982364851).with('textdescid', -621990409).with('uniqueparentid', 0).with('classresourceid', 1834539358)
  2902. .with('uitreeindex', 2)
  2903. .with('classname', 'Button')
  2904. .with('resource-id', 'android:id/button1')
  2905. .with('text', 'DELETE')
  2906.  
  2907. $ruiObj.click
  2908.  
  2909. waitsecond(2)
  2910. end
  2911.  
  2912. tcase << TestAction.new(:scriptAction_5) do
  2913. $myTestResult = checkLastExistResult
  2914.  
  2915. if $myTestResult == false
  2916. $myFailReason == "Picture is not found"
  2917. end
  2918. logStopTest("05_01_07_06_MultiMedia")
  2919. end
  2920.  
  2921. tcase << TestAction.new(:pressBack_6) do
  2922. pressBack
  2923. end
  2924.  
  2925. tcase << TestAction.new(:pressBack_7) do
  2926. pressBack
  2927. end
  2928.  
  2929. tcase << TestAction.new(:pressHome_8) do
  2930. pressHome
  2931. end
  2932.  
  2933. tcase.run(loopTime)
  2934.  
  2935. end
  2936.  
  2937. def self.MultiMedia_05_01_07_10(loopTime)
  2938.  
  2939. tcase = TestCase.new("MultiMedia_05_01_07_10")
  2940.  
  2941. tcase << TestAction.new(:scriptAction_1) do
  2942. logStartTest("05_01_07_10_MultiMedia")
  2943. end
  2944.  
  2945. tcase << TestAction.new(:gotoApp_1) do
  2946. gotoApp('YouTube')
  2947.  
  2948. waitsecond(2)
  2949. end
  2950.  
  2951. tcase << TestAction.new(:TextView_LaterButton_2) do
  2952. $ruiObj = RUIObject.new.with('objectid', 949353906).with('selfid', 702590847).with('textdescid', -874020510).with('uniqueparentid', 0)
  2953. .with('uitreeindex', 4)
  2954. .with('classname', 'TextView')
  2955. .with('resource-id', 'com.google.android.youtube:id/later_button')
  2956. .with('text', 'LATER')
  2957.  
  2958. $ruiObj.click
  2959.  
  2960. waitsecond(2)
  2961. end
  2962.  
  2963. tcase << TestAction.new(:TextView_Dismiss_2) do
  2964. $ruiObj = RUIObject.new.with('objectid', 118887004).with('selfid', 517159).with('textdescid', 1827199643).with('uniqueparentid', 0)
  2965. .with('uitreeindex', 5)
  2966. .with('classname', 'TextView')
  2967. .with('resource-id', 'com.google.android.youtube:id/dismiss')
  2968. .with('text', 'Not now')
  2969.  
  2970. $ruiObj.click
  2971.  
  2972. waitsecond(1)
  2973. end
  2974.  
  2975. tcase << TestAction.new(:Button_Image_2) do
  2976. $ruiObj = RUIObject.new.with('objectid', 875876029).with('selfid', 1315484302).with('textdescid', 1788421122).with('uniqueparentid', 0)
  2977. .with('uitreeindex', 4)
  2978. .with('classname', 'Button')
  2979. .with('resource-id', 'com.google.android.youtube:id/image')
  2980. .with('content-desc', 'Home')
  2981.  
  2982. $ruiObj.click
  2983.  
  2984. waitsecond(1)
  2985. end
  2986.  
  2987. tcase << TestAction.new(:ImageView_Thumbnail_3) do
  2988. $ruiObj = RUIObject.new.with('objectid', 875683821).with('selfid', -2120336906).with('textdescid', 1376394707).with('uniqueparentid', 0)
  2989. .with('uitreeindex', 10)
  2990. .with('pretext', 'WATCH MORE')
  2991. .with('classname', 'ImageView')
  2992. .with('resource-id', 'com.google.android.youtube:id/thumbnail')
  2993.  
  2994. $ruiObj.select('Similiar').click
  2995. end
  2996.  
  2997. tcase << TestAction.new(:wait10second_3) do
  2998. waitsecond(10)
  2999. end
  3000.  
  3001. tcase << TestAction.new(:TextView_SubscribeButton_4) do
  3002. $ruiObj = RUIObject.new.with('objectid', 1730328459).with('selfid', 1783143723).with('textdescid', -408811077).with('uniqueparentid', 0).with('classresourceid', -757100379)
  3003. .with('uitreeindex', 10)
  3004. .with('classname', 'TextView')
  3005. .with('resource-id', 'com.google.android.youtube:id/subscribe_button')
  3006. .with('content-desc', 'Subscribe to this channel')
  3007. .with('text', 'Subscribe')
  3008.  
  3009. $ruiObj.select('Similiar').isExist
  3010. end
  3011.  
  3012. tcase << TestAction.new(:scriptAction_9) do
  3013. $myTestResult = checkLastExistResult
  3014.  
  3015. if $myTestResult == false
  3016. $myFailReason == "Video Streaming does not work"
  3017. end
  3018. logStopTest("05_01_07_10_MultiMedia")
  3019. end
  3020.  
  3021. tcase << TestAction.new(:pressBack_10) do
  3022. pressBack
  3023. end
  3024.  
  3025. tcase << TestAction.new(:pressBack_11) do
  3026. pressBack
  3027. end
  3028.  
  3029. tcase << TestAction.new(:pressHome_12) do
  3030. pressHome
  3031. end
  3032.  
  3033. tcase.run(loopTime)
  3034.  
  3035. end
  3036.  
  3037. def self.MultiTasking_05_01_08_01(loopTime)
  3038.  
  3039. tcase = TestCase.new("MultiTasking_05_01_08_01")
  3040.  
  3041. tcase << TestAction.new(:scriptAction_StartTest) do
  3042. logStartTest("05_01_08_01_MultiTasking")
  3043. end
  3044.  
  3045. tcase << TestAction.new(:gotoApp_1_1) do
  3046. gotoApp('Phone')
  3047.  
  3048. waitsecond(2)
  3049. end
  3050.  
  3051. tcase << TestAction.new(:TextView_Tabtext_21) do
  3052. $ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 566119687).with('textdescid', 1861262411).with('uniqueparentid', 0)
  3053. .with('uitreeindex', 2)
  3054. .with('classname', 'TextView')
  3055. .with('resource-id', 'com.android.contacts:id/tabText')
  3056. .with('text', 'Dial')
  3057.  
  3058. $ruiObj.click
  3059.  
  3060. waitsecond(2)
  3061. end
  3062.  
  3063. tcase << TestAction.new(:EditText_Digits_4) do
  3064. $ruiObj = RUIObject.new.with('objectid', 477485968).with('selfid', -1326421482).with('textdescid', 1917163152).with('uniqueparentid', 0)
  3065. .with('uitreeindex', 7)
  3066. .with('classname', 'EditText')
  3067. .with('resource-id', 'com.android.contacts:id/digits')
  3068.  
  3069. $ruiObj.inputtext('511')
  3070.  
  3071. waitsecond(2)
  3072. end
  3073.  
  3074. tcase << TestAction.new(:ImageButton_Btnlogscall_6) do
  3075. $vzwCallButton = $ruiObj = RUIObject.new.with('objectid', -1934426254).with('selfid', -2053967649).with('textdescid', -911487124).with('uniqueparentid', 0)
  3076. .with('uitreeindex', 21)
  3077. .with('classname', 'ImageButton')
  3078. .with('resource-id', 'com.android.contacts:id/btnLogsCall')
  3079. .with('content-desc', 'Call')
  3080.  
  3081. $tmusCallButton = RUIObject.new.with('objectid', -1313327681).with('selfid', -460279496).with('textdescid', -1259661061).with('uniqueparentid', 0)
  3082. .with('uitreeindex', 58)
  3083. .with('classname', 'ImageButton')
  3084. .with('resource-id', 'com.android.contacts:id/btnVoLTE')
  3085. .with('content-desc', 'VoLTE call')
  3086.  
  3087. if $vzwCallButton.isExist
  3088. $vzwCallButton.click
  3089. elsif $tmusCallButton.isExist
  3090. $tmusCallButton.click
  3091. end
  3092.  
  3093. $ruiObj.click
  3094.  
  3095. waitsecond(1)
  3096. end
  3097.  
  3098. tcase << TestAction.new(:wait10second_3) do
  3099. waitsecond(5)
  3100. end
  3101.  
  3102. tcase << TestAction.new(:Button_Endbutton_2) do
  3103. $ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
  3104. .with('uitreeindex', 10)
  3105. .with('classname', 'Button')
  3106. .with('resource-id', 'com.android.incallui:id/endButton')
  3107. .with('text', 'End')
  3108.  
  3109. $ruiObj.isExist
  3110. end
  3111.  
  3112. tcase << TestAction.new(:scriptAction_4) do
  3113. $myTestResult = checkLastExistResult
  3114.  
  3115. if $myTestResult == false
  3116. $myFailReason = "End button not found"
  3117. end
  3118. logStopTest("05_01_08_01_MultiTasking")
  3119.  
  3120. end
  3121.  
  3122. tcase << TestAction.new(:pressHome_2) do
  3123. pressHome
  3124. end
  3125.  
  3126. tcase.run(loopTime)
  3127.  
  3128. end
  3129.  
  3130. def self.MultiTasking_05_01_08_02(loopTime)
  3131.  
  3132. tcase = TestCase.new("MultiTasking_05_01_08_02")
  3133.  
  3134. tcase << TestAction.new(:scriptAction_StartTestLog) do
  3135. logStartTest("05_01_08_02_MultiTasking")
  3136. end
  3137.  
  3138. tcase << TestAction.new(:gotoApp_1_1) do
  3139. gotoApp('Contacts')
  3140.  
  3141. waitsecond(2)
  3142. end
  3143.  
  3144. tcase << TestAction.new(:gotoApp_1_2) do
  3145. gotoApp('Messaging')
  3146.  
  3147. waitsecond(2)
  3148. end
  3149.  
  3150. tcase << TestAction.new(:gotoApp_1_3) do
  3151. gotoApp('Phone')
  3152.  
  3153. waitsecond(2)
  3154. end
  3155.  
  3156. tcase << TestAction.new(:gotoApp_1_4) do
  3157. gotoApp('Play Store')
  3158.  
  3159. waitsecond(2)
  3160. end
  3161.  
  3162. tcase << TestAction.new(:gotoApp_2) do
  3163. gotoApp('Camera')
  3164.  
  3165. waitsecond(2)
  3166. end
  3167.  
  3168. tcase << TestAction.new(:gotoApp_1_5_1) do
  3169. gotoApp('Chrome')
  3170.  
  3171. waitsecond(2)
  3172. end
  3173.  
  3174. tcase << TestAction.new(:ImageButton_MenuButton_2) do
  3175. $ruiObj = RUIObject.new.with('objectid', 554731264).with('selfid', -17041368).with('textdescid', 1097269587).with('uniqueparentid', 0)
  3176. .with('uitreeindex', 19)
  3177. .with('classname', 'ImageButton')
  3178. .with('resource-id', 'com.android.chrome:id/menu_button')
  3179. .with('content-desc', 'More options')
  3180.  
  3181. $ruiObj.isExist
  3182.  
  3183. waitsecond(0)
  3184. end
  3185.  
  3186. tcase << TestAction.new(:scriptAction_LogStopTest) do
  3187. $myTestResult = checkLastExistResult
  3188. if $myTestResult == false
  3189. $myFailReason = "Apps not loaded"
  3190. end
  3191. logStopTest("05_01_08_02_MultiTasking")
  3192. end
  3193.  
  3194. tcase << TestAction.new(:pressBack_6) do
  3195. pressBack
  3196. end
  3197.  
  3198. tcase << TestAction.new(:pressBack_7) do
  3199. pressBack
  3200. end
  3201.  
  3202. tcase.run(loopTime)
  3203.  
  3204. end
  3205.  
  3206. def self.MultiTasking_05_01_08_03(loopTime)
  3207.  
  3208. tcase = TestCase.new("MultiTasking_05_01_08_03")
  3209.  
  3210. tcase << TestAction.new(:scriptAction_3) do
  3211. wakeUp()
  3212.  
  3213. waitsecond(1)
  3214. end
  3215.  
  3216. tcase << TestAction.new(:scriptAction_StartTestLog_1) do
  3217. logStartTest("05_01_08_03_MultiTasking")
  3218. end
  3219.  
  3220. tcase << TestAction.new(:gotoApp_1_1) do
  3221. gotoApp('Phone')
  3222. end
  3223.  
  3224. tcase << TestAction.new(:Button_Endbutton_2_1_1) do
  3225. $ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
  3226. .with('uitreeindex', 8)
  3227. .with('classname', 'Button')
  3228. .with('resource-id', 'com.android.incallui:id/endButton')
  3229. .with('text', 'End')
  3230.  
  3231. $ruiObj.isExist
  3232.  
  3233. waitsecond(1)
  3234. end
  3235.  
  3236. tcase << TestAction.new(:scriptAction_4_1) do
  3237. $UIDev.swipe(200,
  3238. $UIDev.getDisplayHeight-300,
  3239. $UIDev.getDisplayWidth-50,
  3240. $UIDev.getDisplayHeight-300,
  3241. 10)
  3242. end
  3243.  
  3244. tcase << TestAction.new(:Button_Endbutton_6_1) do
  3245. $ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
  3246. .with('uitreeindex', 12)
  3247. .with('classname', 'Button')
  3248. .with('resource-id', 'com.android.incallui:id/endButton')
  3249. .with('text', 'End')
  3250.  
  3251. $ruiObj.click
  3252.  
  3253. waitsecond(1)
  3254. end
  3255.  
  3256. tcase << TestAction.new(:scriptAction_LogStopTest) do
  3257. $myTestResult = checkLastExistResult
  3258.  
  3259. if $myTestResult == false
  3260. $myFailReason = "End button not found"
  3261. end
  3262. logStopTest("05_01_08_03_MultiTasking")
  3263. end
  3264.  
  3265. tcase << TestAction.new(:pressHome_20) do
  3266. pressHome
  3267. end
  3268.  
  3269. tcase.run(loopTime)
  3270.  
  3271. end
  3272.  
  3273. def self.MultiTasking_05_01_08_04(loopTime)
  3274.  
  3275. tcase = TestCase.new("MultiTasking_05_01_08_04")
  3276.  
  3277. tcase << TestAction.new(:scriptAction_StartTestLog) do
  3278. logStartTest("05_01_08_04_MultiTasking")
  3279. end
  3280.  
  3281. tcase << TestAction.new(:gotoApp_1_1) do
  3282. gotoApp('Chrome')
  3283. end
  3284.  
  3285. tcase << TestAction.new(:Button_TermsAccept_5) do
  3286. $ruiObj = RUIObject.new.with('objectid', 1131623741).with('selfid', 659232449).with('textdescid', -1120600562).with('uniqueparentid', 0)
  3287. .with('uitreeindex', 4)
  3288. .with('classname', 'Button')
  3289. .with('resource-id', 'com.android.chrome:id/terms_accept')
  3290. .with('text', 'Accept continue')
  3291.  
  3292. $ruiObj.click
  3293. end
  3294.  
  3295. tcase << TestAction.new(:Button_PositiveButton_6) do
  3296. $ruiObj = RUIObject.new.with('objectid', -1302979962).with('selfid', 780691289).with('textdescid', 1735628115).with('uniqueparentid', 0)
  3297. .with('uitreeindex', 5)
  3298. .with('classname', 'Button')
  3299. .with('resource-id', 'com.android.chrome:id/positive_button')
  3300. .with('text', 'Next')
  3301.  
  3302. $ruiObj.click
  3303. end
  3304.  
  3305. tcase << TestAction.new(:Button_PositiveButton_7) do
  3306. $ruiObj = RUIObject.new.with('objectid', -953817212).with('selfid', 780402664).with('textdescid', 1478534434).with('uniqueparentid', 0)
  3307. .with('uitreeindex', 7)
  3308. .with('classname', 'Button')
  3309. .with('resource-id', 'com.android.chrome:id/positive_button')
  3310. .with('text', 'Done')
  3311.  
  3312. $ruiObj.click
  3313. end
  3314.  
  3315. tcase << TestAction.new(:EditText_UrlBar_8) do
  3316. $ruiObj = RUIObject.new.with('objectid', 882195433).with('selfid', 613381324).with('textdescid', 1578254679).with('uniqueparentid', 0)
  3317. .with('uitreeindex', 7)
  3318. .with('classname', 'EditText')
  3319. .with('resource-id', 'com.android.chrome:id/url_bar')
  3320.  
  3321. $ruiObj.inputtext('www.att.com')
  3322.  
  3323. waitsecond(1)
  3324. end
  3325.  
  3326. tcase << TestAction.new(:pressEnter_5_1) do
  3327. pressEnter
  3328.  
  3329. waitsecond(4)
  3330. end
  3331.  
  3332. tcase << TestAction.new(:wait2second_2) do
  3333. waitsecond(2)
  3334. end
  3335.  
  3336. tcase << TestAction.new(:scriptAction_LogStopTest) do
  3337. $reload = RUIObject.new.with('objectid', -1485276626).with('selfid', 131798869).with('textdescid', -1148751605).with('uniqueparentid', -932380963)
  3338. .with('uitreeindex', 1)
  3339. .with('classname', 'Button')
  3340. .with('content-desc', 'RELOAD').exists?
  3341.  
  3342. $progressBar = RUIObject.new.with('objectid', 460148827).with('selfid', -703099949).with('textdescid', 1379711781).with('uniqueparentid', 0)
  3343. .with('uitreeindex', 4)
  3344. .with('pretext', 'Block')
  3345. .with('classname', 'ProgressBar')
  3346. .with('resource-id', 'com.android.chrome:id/progress').exists?
  3347.  
  3348. if ($progressBar or $reload) == true
  3349. $myTestResult = false
  3350. else
  3351. $myTestResult = true
  3352. end
  3353. if $myTestResult == false
  3354. $myFailReason = "Browser is not starting"
  3355. end
  3356. logStopTest("05_01_08_04_MultiTasking")
  3357. end
  3358.  
  3359. tcase << TestAction.new(:pressHome_1) do
  3360. pressHome
  3361. end
  3362.  
  3363. tcase.run(loopTime)
  3364.  
  3365. end
  3366.  
  3367. def self.MultiTasking_05_01_08_05(loopTime)
  3368.  
  3369. tcase = TestCase.new("MultiTasking_05_01_08_05")
  3370.  
  3371. tcase << TestAction.new(:scriptAction_StartTestLog) do
  3372. logStartTest("05_01_08_05_MultiTasking")
  3373. end
  3374.  
  3375. tcase << TestAction.new(:gotoApp_1_1) do
  3376. gotoApp('Contacts')
  3377.  
  3378. waitsecond(2)
  3379. end
  3380.  
  3381. tcase << TestAction.new(:gotoApp_1_2) do
  3382. gotoApp('Messaging')
  3383.  
  3384. waitsecond(2)
  3385. end
  3386.  
  3387. tcase << TestAction.new(:gotoApp_1_3) do
  3388. gotoApp('Phone')
  3389.  
  3390. waitsecond(2)
  3391. end
  3392.  
  3393. tcase << TestAction.new(:gotoApp_1_4) do
  3394. gotoApp('Play Store')
  3395.  
  3396. waitsecond(2)
  3397. end
  3398.  
  3399. tcase << TestAction.new(:gotoApp_2) do
  3400. gotoApp('Camera')
  3401.  
  3402. waitsecond(2)
  3403. end
  3404.  
  3405. tcase << TestAction.new(:gotoApp_1_5) do
  3406. gotoApp('Chrome')
  3407.  
  3408. waitsecond(2)
  3409. end
  3410.  
  3411. tcase << TestAction.new(:ImageButton_MenuButton_2) do
  3412. $ruiObj = RUIObject.new.with('objectid', 286278959).with('selfid', -17041368).with('textdescid', 536559428).with('uniqueparentid', 0)
  3413. .with('uitreeindex', 15)
  3414. .with('classname', 'ImageButton')
  3415. .with('resource-id', 'com.android.chrome:id/menu_button')
  3416. .with('content-desc', 'More options')
  3417.  
  3418. $ruiObj.isExist
  3419.  
  3420. waitsecond(0)
  3421. end
  3422.  
  3423. tcase << TestAction.new(:scriptAction_LogStopTest) do
  3424. $myTestResult = checkLastExistResult
  3425. if $myTestResult == false
  3426. $myFailReason = "End button not found"
  3427. end
  3428. logStopTest("05_01_08_05_MultiTasking")
  3429. end
  3430.  
  3431. tcase << TestAction.new(:pressBack_3) do
  3432. pressBack
  3433. end
  3434.  
  3435. tcase << TestAction.new(:pressBack_4) do
  3436. pressBack
  3437. end
  3438.  
  3439. tcase.run(loopTime)
  3440.  
  3441. end
  3442.  
  3443. def self.MultiTasking_05_01_08_06(loopTime)
  3444.  
  3445. tcase = TestCase.new("MultiTasking_05_01_08_06")
  3446.  
  3447. tcase << TestAction.new(:scriptAction_StartTestLog) do
  3448. logStartTest("05_01_08_06_MultiTasking")
  3449. end
  3450.  
  3451. tcase << TestAction.new(:gotoApp_1_1) do
  3452. gotoApp('Chrome')
  3453.  
  3454. waitsecond(2)
  3455. end
  3456.  
  3457. tcase << TestAction.new(:ImageButton_MenuButton_2) do
  3458. $ruiObj = RUIObject.new.with('objectid', 286278959).with('selfid', -17041368).with('textdescid', 536559428).with('uniqueparentid', 0)
  3459. .with('uitreeindex', 101)
  3460. .with('classname', 'ImageButton')
  3461. .with('resource-id', 'com.android.chrome:id/menu_button')
  3462. .with('content-desc', 'More options')
  3463.  
  3464. $ruiObj.isExist
  3465.  
  3466. waitsecond(0)
  3467. end
  3468.  
  3469. tcase << TestAction.new(:scriptAction_LogStopTest) do
  3470. $myTestResult = checkLastExistResult
  3471.  
  3472. if $myTestResult == false
  3473. $myFailReason = "End button not found"
  3474. end
  3475. logStopTest("05_01_08_06_MultiTasking")
  3476. end
  3477.  
  3478. tcase << TestAction.new(:pressHome_1) do
  3479. pressHome
  3480. end
  3481.  
  3482. tcase.run(loopTime)
  3483.  
  3484. end
  3485.  
  3486. def self.NFC_05_01_11_01(loopTime)
  3487.  
  3488. tcase = TestCase.new("NFC_05_01_11_01")
  3489.  
  3490. tcase << TestAction.new(:scriptAction_StartTestLog) do
  3491. logStartTest("05_01_11_01_NFC")
  3492. end
  3493.  
  3494. tcase << TestAction.new(:gotoApp_3) do
  3495. gotoApp('Settings')
  3496.  
  3497. waitsecond(2)
  3498. end
  3499.  
  3500. tcase << TestAction.new(:TextView_Title_2) do
  3501. $ruiObj = RUIObject.new.with('objectid', 674368800).with('selfid', -2078686330).with('textdescid', -957350501).with('uniqueparentid', 0)
  3502. .with('uitreeindex', 2)
  3503. .with('classname', 'TextView')
  3504. .with('resource-id', 'android:id/title')
  3505. .with('text', 'Networks')
  3506.  
  3507. $ruiObj.click
  3508.  
  3509. waitsecond(1)
  3510. end
  3511.  
  3512. tcase << TestAction.new(:swipeDown_6) do
  3513. swipe_vertical 500
  3514.  
  3515. waitsecond(2)
  3516. end
  3517.  
  3518. tcase << TestAction.new(:TextView_Title_4) do
  3519. $ruiObj = RUIObject.new.with('objectid', -487328458).with('selfid', 347833004).with('textdescid', -1018549621).with('uniqueparentid', 0).with('classresourceid', 490183159)
  3520. .with('uitreeindex', 28)
  3521. .with('classname', 'TextView')
  3522. .with('resource-id', 'android:id/title')
  3523. .with('text', 'Share connect')
  3524.  
  3525. $ruiObj.click
  3526.  
  3527. waitsecond(1)
  3528. end
  3529.  
  3530. tcase << TestAction.new(:Switch_Switchwidget_25) do
  3531. $ruiObj = RUIObject.new.with('objectid', 2120363415).with('selfid', 2013927764).with('textdescid', -1882088).with('uniqueparentid', 0).with('classresourceid', -1664951417)
  3532. .with('uitreeindex', 7)
  3533. .with('classname', 'Switch')
  3534. .with('resource-id', 'com.android.settings:id/switchWidget')
  3535.  
  3536. $ruiObj.select('ItemFirst').click
  3537.  
  3538. waitsecond(2)
  3539. end
  3540.  
  3541. tcase << TestAction.new(:Button_Button1_5) do
  3542. $ruiObj = RUIObject.new.with('objectid', -1399075268).with('selfid', -1526282700).with('textdescid', -93090416).with('uniqueparentid', 0).with('classresourceid', 1834539358)
  3543. .with('uitreeindex', 3)
  3544. .with('classname', 'Button')
  3545. .with('resource-id', 'android:id/button1')
  3546. .with('text', 'TURN OFF')
  3547.  
  3548. $ruiObj.click
  3549.  
  3550. waitsecond(2)
  3551. end
  3552.  
  3553. tcase << TestAction.new(:wait8second_12) do
  3554. waitsecond(10)
  3555. end
  3556.  
  3557. tcase << TestAction.new(:Switch_Switchwidget_4) do
  3558. $ruiObj = RUIObject.new.with('objectid', 2120363415).with('selfid', 2013927764).with('textdescid', -1882088).with('uniqueparentid', 0).with('classresourceid', -1664951417)
  3559. .with('uitreeindex', 7)
  3560. .with('classname', 'Switch')
  3561. .with('resource-id', 'com.android.settings:id/switchWidget')
  3562.  
  3563. $ruiObj.select('ItemFirst').click
  3564.  
  3565. waitsecond(2)
  3566. end
  3567.  
  3568. tcase << TestAction.new(:wait8second_12_1) do
  3569. waitsecond(10)
  3570. end
  3571.  
  3572. tcase << TestAction.new(:pressBack_7) do
  3573. pressBack
  3574. end
  3575.  
  3576. tcase << TestAction.new(:pressBack_8) do
  3577. pressBack
  3578. end
  3579.  
  3580. tcase << TestAction.new(:pressBack_18) do
  3581. pressBack
  3582. end
  3583.  
  3584. tcase << TestAction.new(:pressBack_18_1) do
  3585. pressBack
  3586. end
  3587.  
  3588. tcase << TestAction.new(:pressHome_2) do
  3589. pressHome
  3590. end
  3591.  
  3592. tcase << TestAction.new(:scriptAction_LogStopTest) do
  3593. $myTestResult = checkLastExistResult
  3594.  
  3595. if $myTestResult == false
  3596. $myFailReason = "End button not found"
  3597. end
  3598. logStopTest("05_01_11_01_NFC")
  3599. end
  3600.  
  3601. tcase.run(loopTime)
  3602.  
  3603. end
  3604.  
  3605. def self.PIM_05_01_06_01(loopTime)
  3606.  
  3607. tcase = TestCase.new("PIM_05_01_06_01")
  3608.  
  3609. tcase << TestAction.new(:scriptAction_StartTestLog) do
  3610. logStartTest("05_01_06_01_PIM")
  3611. end
  3612.  
  3613. tcase << TestAction.new(:gotoApp_4) do
  3614. gotoApp('Calendar')
  3615.  
  3616. waitsecond(2)
  3617. end
  3618.  
  3619. tcase << TestAction.new(:ImageView_3) do
  3620. $ruiObj = RUIObject.new.with('objectid', -30724256).with('selfid', 1125864064).with('textdescid', -952451904).with('uniqueparentid', 0)
  3621. .with('uitreeindex', 23)
  3622. .with('pretext', 'SAT')
  3623. .with('classname', 'ImageView')
  3624.  
  3625. $ruiObj.click
  3626.  
  3627. waitsecond(2)
  3628. end
  3629.  
  3630. tcase << TestAction.new(:EditText_Title_7) do
  3631. $ruiObj = RUIObject.new.with('objectid', -308497519).with('selfid', 2023914653).with('textdescid', -973488465).with('uniqueparentid', 0).with('classresourceid', 1943514993)
  3632. .with('uitreeindex', 4)
  3633. .with('classname', 'EditText')
  3634. .with('resource-id', 'com.android.calendar:id/title')
  3635.  
  3636. $ruiObj.inputtext('Event')
  3637.  
  3638. waitsecond(2)
  3639. end
  3640.  
  3641. tcase << TestAction.new(:Button_BtnDone_9) do
  3642. $ruiObj = RUIObject.new.with('objectid', 2099795980).with('selfid', 2133354936).with('textdescid', -644044497).with('uniqueparentid', 0)
  3643. .with('uitreeindex', 32)
  3644. .with('classname', 'Button')
  3645. .with('resource-id', 'com.android.calendar:id/btn_done')
  3646. .with('text', 'SAVE')
  3647.  
  3648. $ruiObj.click
  3649.  
  3650. waitsecond(2)
  3651. end
  3652.  
  3653. tcase << TestAction.new(:wait1second_11) do
  3654. waitsecond(1)
  3655. end
  3656.  
  3657. tcase << TestAction.new(:scriptAction_LogStopTest) do
  3658. $myTestResult = checkLastExistResult
  3659.  
  3660. if $myTestResult == false
  3661. $myFailReason = "End button not found"
  3662. end
  3663. logStopTest("05_01_06_01_PIM")
  3664. end
  3665.  
  3666. tcase << TestAction.new(:pressBack_14) do
  3667. pressBack
  3668. end
  3669.  
  3670. tcase << TestAction.new(:pressBack_16) do
  3671. pressBack
  3672. end
  3673.  
  3674. tcase << TestAction.new(:pressHome_2) do
  3675. pressHome
  3676. end
  3677.  
  3678. tcase.run(loopTime)
  3679.  
  3680. end
  3681.  
  3682. def self.PIM_05_01_06_02(loopTime)
  3683.  
  3684. tcase = TestCase.new("PIM_05_01_06_02")
  3685.  
  3686. tcase << TestAction.new(:scriptAction_StartTestLog) do
  3687. logStartTest("05_01_06_02_PIM")
  3688. end
  3689.  
  3690. tcase << TestAction.new(:gotoApp_21) do
  3691. gotoApp('Clock')
  3692.  
  3693. waitsecond(2)
  3694. end
  3695.  
  3696. tcase << TestAction.new(:Button_Button1_2) do
  3697. $ruiObj = RUIObject.new.with('objectid', -1592541968).with('selfid', -1318451484).with('textdescid', 1176208020).with('uniqueparentid', 0)
  3698. .with('uitreeindex', 4)
  3699. .with('classname', 'Button')
  3700. .with('resource-id', 'android:id/button1')
  3701. .with('text', 'OK')
  3702.  
  3703. $ruiObj.click
  3704.  
  3705. waitsecond(2)
  3706. end
  3707.  
  3708. tcase << TestAction.new(:TextView_Title_4) do
  3709. $ruiObj = RUIObject.new.with('objectid', 1224190759).with('selfid', -1121994128).with('textdescid', 1363275560).with('uniqueparentid', 0)
  3710. .with('uitreeindex', 2)
  3711. .with('classname', 'TextView')
  3712. .with('resource-id', 'android:id/title')
  3713. .with('text', 'Alarm')
  3714.  
  3715. $ruiObj.click
  3716.  
  3717. waitsecond(2)
  3718. end
  3719.  
  3720. tcase << TestAction.new(:ImageView_Fab_5) do
  3721. $ruiObj = RUIObject.new.with('objectid', -476403250).with('selfid', -466463568).with('textdescid', -1883598830).with('uniqueparentid', 0)
  3722. .with('uitreeindex', 8)
  3723. .with('classname', 'ImageView')
  3724. .with('resource-id', 'com.lge.clock:id/fab')
  3725.  
  3726. $ruiObj.click
  3727.  
  3728. waitsecond(2)
  3729. end
  3730.  
  3731. tcase << TestAction.new(:swipeDown_7) do
  3732. swipe_vertical 500
  3733.  
  3734. waitsecond(2)
  3735. end
  3736.  
  3737. tcase << TestAction.new(:EditText_MemoInput_9) do
  3738. $ruiObj = RUIObject.new.with('objectid', -560595495).with('selfid', 370574885).with('textdescid', -198591129).with('uniqueparentid', 0).with('classresourceid', -1797104135)
  3739. .with('uitreeindex', 23)
  3740. .with('classname', 'EditText')
  3741. .with('resource-id', 'com.lge.clock:id/memo_input')
  3742.  
  3743. $ruiObj.inputtext('Alarm1')
  3744.  
  3745. waitsecond(2)
  3746. end
  3747.  
  3748. tcase << TestAction.new(:Button_Savebutton_12) do
  3749. $ruiObj = RUIObject.new.with('objectid', -902674558).with('selfid', -575419535).with('textdescid', -816404443).with('uniqueparentid', 0)
  3750. .with('uitreeindex', 30)
  3751. .with('classname', 'Button')
  3752. .with('resource-id', 'com.lge.clock:id/saveButton')
  3753. .with('text', 'SAVE')
  3754.  
  3755. $ruiObj.click
  3756.  
  3757. waitsecond(2)
  3758. end
  3759.  
  3760. tcase << TestAction.new(:wait1second_14) do
  3761. waitsecond(1)
  3762. end
  3763.  
  3764. tcase << TestAction.new(:Switch_AlarmListItemButton_16) do
  3765. $ruiObj = RUIObject.new.with('objectid', -104098710).with('selfid', -385149075).with('textdescid', 1204227435).with('uniqueparentid', 0)
  3766. .with('uitreeindex', 10)
  3767. .with('classname', 'Switch')
  3768. .with('resource-id', 'com.lge.clock:id/alarm_list_item_button')
  3769. .with('text', 'ON')
  3770.  
  3771. $ruiObj.isExist
  3772.  
  3773. waitsecond(2)
  3774. end
  3775.  
  3776. tcase << TestAction.new(:scriptAction_LogStopTest) do
  3777. $myTestResult = checkLastExistResult
  3778.  
  3779. if $myTestResult == false
  3780. $myFailReason = "End button not found"
  3781. end
  3782. logStopTest("05_01_06_02_PIM")
  3783. end
  3784.  
  3785. tcase << TestAction.new(:pressBack_7) do
  3786. pressBack
  3787. end
  3788.  
  3789. tcase << TestAction.new(:pressBack_20) do
  3790. pressBack
  3791. end
  3792.  
  3793. tcase << TestAction.new(:pressHome_2) do
  3794. pressHome
  3795. end
  3796.  
  3797. tcase.run(loopTime)
  3798.  
  3799. end
  3800.  
  3801. def self.PIM_05_01_06_03(loopTime)
  3802.  
  3803. tcase = TestCase.new("PIM_05_01_06_03")
  3804.  
  3805. tcase << TestAction.new(:scriptAction_StartTestLog) do
  3806. logStartTest("05_01_06_03_PIM")
  3807.  
  3808. waitsecond(1)
  3809. end
  3810.  
  3811. tcase << TestAction.new(:gotoApp_2) do
  3812. gotoApp('Calendar')
  3813.  
  3814. waitsecond(1)
  3815. end
  3816.  
  3817. tcase << TestAction.new(:ImageButton_Open_2) do
  3818. $ruiObj = RUIObject.new.with('objectid', 1598382174).with('selfid', 1589392844).with('textdescid', -1452260343).with('uniqueparentid', 0)
  3819. .with('uitreeindex', 0)
  3820. .with('classname', 'ImageButton')
  3821. .with('content-desc', 'Open navigation drawer')
  3822.  
  3823. $ruiObj.click
  3824.  
  3825. waitsecond(2)
  3826. end
  3827.  
  3828. tcase << TestAction.new(:TextView_ButtonView_7) do
  3829. $ruiObj = RUIObject.new.with('objectid', 603982191).with('selfid', -270658080).with('textdescid', 1995102261).with('uniqueparentid', 0).with('classresourceid', 1399022470)
  3830. .with('uitreeindex', 25)
  3831. .with('classname', 'TextView')
  3832. .with('resource-id', 'com.android.calendar:id/button_view')
  3833. .with('text', 'Day')
  3834.  
  3835. $ruiObj.click
  3836.  
  3837. waitsecond(2)
  3838. end
  3839.  
  3840. tcase << TestAction.new(:ImageButton_More_9) do
  3841. $ruiObj = RUIObject.new.with('objectid', -612680593).with('selfid', 1290820192).with('textdescid', 366665732).with('uniqueparentid', 0)
  3842. .with('uitreeindex', 6)
  3843. .with('classname', 'ImageButton')
  3844. .with('content-desc', 'More options')
  3845.  
  3846. $ruiObj.click
  3847.  
  3848. waitsecond(2)
  3849. end
  3850.  
  3851. tcase << TestAction.new(:TextView_Title_11) do
  3852. $ruiObj = RUIObject.new.with('objectid', 188068915).with('selfid', -342341268).with('textdescid', 1772893384).with('uniqueparentid', 0).with('classresourceid', 490183159)
  3853. .with('uitreeindex', 0)
  3854. .with('classname', 'TextView')
  3855. .with('resource-id', 'android:id/title')
  3856. .with('text', 'Delete')
  3857.  
  3858. $ruiObj.click
  3859.  
  3860. waitsecond(2)
  3861. end
  3862.  
  3863. tcase << TestAction.new(:CheckBox_ActionSelectallCheckbox_16) do
  3864. $ruiObj = RUIObject.new.with('objectid', -855663087).with('selfid', 1343055516).with('textdescid', 1579914132).with('uniqueparentid', 0)
  3865. .with('uitreeindex', 0)
  3866. .with('classname', 'CheckBox')
  3867. .with('resource-id', 'com.android.calendar:id/action_selectall_checkbox')
  3868. .with('text', 'Select all')
  3869.  
  3870. $ruiObj.click
  3871.  
  3872. waitsecond(2)
  3873. end
  3874.  
  3875. tcase << TestAction.new(:Button_DeleteAgenda_18) do
  3876. $ruiObj = RUIObject.new.with('objectid', 572018530).with('selfid', 1307339797).with('textdescid', -303618793).with('uniqueparentid', 0)
  3877. .with('uitreeindex', 16)
  3878. .with('classname', 'Button')
  3879. .with('resource-id', 'com.android.calendar:id/delete_agenda')
  3880. .with('text', 'DELETE')
  3881.  
  3882. $ruiObj.click
  3883.  
  3884. waitsecond(2)
  3885. end
  3886.  
  3887. tcase << TestAction.new(:Button_Button1_20) do
  3888. $ruiObj = RUIObject.new.with('objectid', -122532739).with('selfid', 982364851).with('textdescid', 1617680178).with('uniqueparentid', 0)
  3889. .with('uitreeindex', 2)
  3890. .with('classname', 'Button')
  3891. .with('resource-id', 'android:id/button1')
  3892. .with('text', 'DELETE')
  3893.  
  3894. $ruiObj.click
  3895.  
  3896. waitsecond(2)
  3897. end
  3898.  
  3899. tcase << TestAction.new(:wait1second_22) do
  3900. waitsecond(1)
  3901. end
  3902.  
  3903. tcase << TestAction.new(:ImageButton_Open_24) do
  3904. $ruiObj = RUIObject.new.with('objectid', 1598382174).with('selfid', 1589392844).with('textdescid', -1452260343).with('uniqueparentid', 0)
  3905. .with('uitreeindex', 0)
  3906. .with('classname', 'ImageButton')
  3907. .with('content-desc', 'Open navigation drawer')
  3908.  
  3909. $ruiObj.click
  3910.  
  3911. waitsecond(2)
  3912. end
  3913.  
  3914. tcase << TestAction.new(:TextView_ButtonView_26) do
  3915. $ruiObj = RUIObject.new.with('objectid', 603982191).with('selfid', 1899312068).with('textdescid', 2008206737).with('uniqueparentid', 0).with('classresourceid', 1399022470)
  3916. .with('uitreeindex', 18)
  3917. .with('classname', 'TextView')
  3918. .with('resource-id', 'com.android.calendar:id/button_view')
  3919. .with('text', 'Month')
  3920.  
  3921. $ruiObj.click
  3922.  
  3923. waitsecond(2)
  3924. end
  3925.  
  3926. tcase << TestAction.new(:scriptAction_LogStopTest) do
  3927. $myTestResult = checkLastExistResult
  3928.  
  3929. if $myTestResult == false
  3930. $myFailReason = "End button not found"
  3931. end
  3932. logStopTest("05_01_06_03_PIM")
  3933. end
  3934.  
  3935. tcase << TestAction.new(:pressBack_9) do
  3936. pressBack
  3937. end
  3938.  
  3939. tcase << TestAction.new(:pressBack_28) do
  3940. pressBack
  3941. end
  3942.  
  3943. tcase << TestAction.new(:pressHome_2) do
  3944. pressHome
  3945. end
  3946.  
  3947. tcase.run(loopTime)
  3948.  
  3949. end
  3950.  
  3951. def self.PIM_05_01_06_04(loopTime)
  3952.  
  3953. tcase = TestCase.new("PIM_05_01_06_04")
  3954.  
  3955. tcase << TestAction.new(:scriptAction_StartTestLog) do
  3956. logStartTest("05_01_06_04_PIM")
  3957. end
  3958.  
  3959. tcase << TestAction.new(:gotoApp_21) do
  3960. gotoApp('Clock')
  3961.  
  3962. waitsecond(2)
  3963. end
  3964.  
  3965. tcase << TestAction.new(:TextView_Title_21) do
  3966. $ruiObj = RUIObject.new.with('objectid', -322510520).with('selfid', -1121994128).with('textdescid', 2047918567).with('uniqueparentid', 0)
  3967. .with('uitreeindex', 2)
  3968. .with('classname', 'TextView')
  3969. .with('resource-id', 'android:id/title')
  3970. .with('text', 'Alarm')
  3971.  
  3972. $ruiObj.click
  3973.  
  3974. waitsecond(1)
  3975. end
  3976.  
  3977. tcase << TestAction.new(:TextView_DeleteAlarmMenu_5) do
  3978. $ruiObj = RUIObject.new.with('objectid', -627640121).with('selfid', 2100473433).with('textdescid', 1981482564).with('uniqueparentid', 0)
  3979. .with('uitreeindex', 1)
  3980. .with('classname', 'TextView')
  3981. .with('resource-id', 'com.lge.clock:id/delete_alarm_menu')
  3982. .with('content-desc', 'Delete')
  3983.  
  3984. $ruiObj.click
  3985.  
  3986. waitsecond(1)
  3987. end
  3988.  
  3989. tcase << TestAction.new(:CheckBox_Checkall_4) do
  3990. $ruiObj = RUIObject.new.with('objectid', 856038081).with('selfid', 2027227245).with('textdescid', 767376767).with('uniqueparentid', 0)
  3991. .with('uitreeindex', 0)
  3992. .with('classname', 'CheckBox')
  3993. .with('resource-id', 'com.lge.clock:id/checkall')
  3994.  
  3995. $ruiObj.click
  3996.  
  3997. waitsecond(2)
  3998. end
  3999.  
  4000. tcase << TestAction.new(:Button_BtnDelete_6) do
  4001. $ruiObj = RUIObject.new.with('objectid', -568781847).with('selfid', 1633729950).with('textdescid', 1056600734).with('uniqueparentid', 0)
  4002. .with('uitreeindex', 15)
  4003. .with('classname', 'Button')
  4004. .with('resource-id', 'com.lge.clock:id/btn_Delete')
  4005. .with('text', 'DELETE')
  4006.  
  4007. $ruiObj.click
  4008.  
  4009. waitsecond(2)
  4010. end
  4011.  
  4012. tcase << TestAction.new(:Button_Button1_4) do
  4013. $ruiObj = RUIObject.new.with('objectid', -242247236).with('selfid', 982364851).with('textdescid', 1048802673).with('uniqueparentid', 0).with('classresourceid', 1834539358)
  4014. .with('uitreeindex', 2)
  4015. .with('classname', 'Button')
  4016. .with('resource-id', 'android:id/button1')
  4017. .with('text', 'DELETE')
  4018.  
  4019. $ruiObj.click
  4020.  
  4021. waitsecond(2)
  4022. end
  4023.  
  4024. tcase << TestAction.new(:TextView_NoContentsText_5) do
  4025. $ruiObj = RUIObject.new.with('objectid', -906561874).with('selfid', 2062356648).with('textdescid', -1982958191).with('uniqueparentid', 0)
  4026. .with('uitreeindex', 6)
  4027. .with('classname', 'TextView')
  4028. .with('resource-id', 'com.lge.clock:id/no_contents_text')
  4029. .with('text', 'No alarms')
  4030.  
  4031. $ruiObj.isExist
  4032.  
  4033. waitsecond(1)
  4034. end
  4035.  
  4036. tcase << TestAction.new(:pressBack_15) do
  4037. pressBack
  4038. end
  4039.  
  4040. tcase << TestAction.new(:pressBack_16) do
  4041. pressBack
  4042. end
  4043.  
  4044. tcase << TestAction.new(:pressHome_2) do
  4045. pressHome
  4046. end
  4047.  
  4048. tcase << TestAction.new(:scriptAction_LogStopTest) do
  4049. $myTestResult = checkLastExistResult
  4050.  
  4051. if $myTestResult == false
  4052. $myFailReason = "End button not found"
  4053. end
  4054. logStopTest("05_01_06_04_PIM")
  4055. end
  4056.  
  4057. tcase.run(loopTime)
  4058.  
  4059. end
  4060.  
  4061. def self.StoreFrontDownload_05_01_05_01(loopTime)
  4062.  
  4063. tcase = TestCase.new("StoreFrontDownload_05_01_05_01")
  4064.  
  4065. tcase << TestAction.new(:scriptAction_1) do
  4066. logStartTest("05_01_05_07_StoreFrontDownload")
  4067. end
  4068.  
  4069. tcase << TestAction.new(:gotoApp_2) do
  4070. gotoApp('Play Store')
  4071.  
  4072. waitsecond(1)
  4073. end
  4074.  
  4075. tcase << TestAction.new(:ImageView_SearchBoxIdleText_5) do
  4076. $ruiObj = RUIObject.new.with('objectid', 1987043402).with('selfid', 88317888).with('textdescid', -133777698).with('uniqueparentid', 0)
  4077. .with('uitreeindex', 32)
  4078. .with('classname', 'ImageView')
  4079. .with('resource-id', 'com.android.vending:id/search_box_idle_text')
  4080. .with('content-desc', 'Search')
  4081.  
  4082. $ruiObj.click
  4083.  
  4084. waitsecond(1)
  4085. end
  4086.  
  4087. tcase << TestAction.new(:EditText_SearchBoxTextInput_6) do
  4088. $ruiObj = RUIObject.new.with('objectid', 1660565057).with('selfid', 209465679).with('textdescid', -62090753).with('uniqueparentid', 0)
  4089. .with('uitreeindex', 32)
  4090. .with('classname', 'EditText')
  4091. .with('resource-id', 'com.android.vending:id/search_box_text_input')
  4092.  
  4093. $ruiObj.inputtext('ColorNote')
  4094.  
  4095. waitsecond(1)
  4096. end
  4097.  
  4098. tcase << TestAction.new(:TextView_SuggestText_7_Click_ColorNote) do
  4099. $ruiObj = RUIObject.new.with('objectid', 193809363).with('selfid', 208620854).with('textdescid', 1052874934).with('uniqueparentid', 0)
  4100. .with('uitreeindex', 36)
  4101. .with('classname', 'TextView')
  4102. .with('resource-id', 'com.android.vending:id/suggest_text')
  4103. .with('text', 'ColorNote Notepad Notes')
  4104.  
  4105. $ruiObj.click
  4106.  
  4107. waitsecond(1)
  4108. end
  4109.  
  4110. tcase << TestAction.new(:TextView_LiTitle_2) do
  4111. $ruiObj = RUIObject.new.with('objectid', 1456557201).with('selfid', -1969590474).with('textdescid', 83190698).with('uniqueparentid', 0)
  4112. .with('uitreeindex', 5)
  4113. .with('classname', 'TextView')
  4114. .with('resource-id', 'com.android.vending:id/li_title')
  4115. .with('content-desc', 'App: ColorNote Notepad Notes')
  4116. .with('text', 'ColorNote Notepad Notes')
  4117.  
  4118. $ruiObj.click
  4119.  
  4120. waitsecond(1)
  4121. end
  4122.  
  4123. tcase << TestAction.new(:Button_UninstallButton_15_pressed) do
  4124. $ruiObj = RUIObject.new.with('objectid', -1388871150).with('selfid', -895718918).with('textdescid', -1334831508).with('uniqueparentid', 0)
  4125. .with('uitreeindex', 7)
  4126. .with('classname', 'Button')
  4127. .with('resource-id', 'com.android.vending:id/uninstall_button')
  4128. .with('text', 'UNINSTALL')
  4129.  
  4130. $ruiObj.click
  4131.  
  4132. waitsecond(1)
  4133. end
  4134.  
  4135. tcase << TestAction.new(:Button_Button1_16_pressed_OK) do
  4136. $ruiObj = RUIObject.new.with('objectid', 1379336962).with('selfid', -1318451484).with('textdescid', -1993773146).with('uniqueparentid', 0)
  4137. .with('uitreeindex', 2)
  4138. .with('classname', 'Button')
  4139. .with('resource-id', 'android:id/button1')
  4140. .with('text', 'OK')
  4141.  
  4142. $ruiObj.click
  4143.  
  4144. waitsecond(8)
  4145. end
  4146.  
  4147. tcase << TestAction.new(:Button_BuyButton_1_1) do
  4148. $ruiObj = RUIObject.new.with('objectid', -329901969).with('selfid', -652886121).with('textdescid', 992432790).with('uniqueparentid', 0)
  4149. .with('uitreeindex', 7)
  4150. .with('classname', 'Button')
  4151. .with('resource-id', 'com.android.vending:id/buy_button')
  4152. .with('text', 'INSTALL')
  4153.  
  4154. $ruiObj.click
  4155.  
  4156. waitsecond(2)
  4157. end
  4158.  
  4159. tcase << TestAction.new(:Button_PositiveButton_2_1) do
  4160. $ruiObj = RUIObject.new.with('objectid', 1281581194).with('selfid', -1901489946).with('textdescid', -1976674237).with('uniqueparentid', 0)
  4161. .with('uitreeindex', 2)
  4162. .with('classname', 'Button')
  4163. .with('resource-id', 'com.android.vending:id/positive_button')
  4164. .with('text', 'CONTINUE')
  4165.  
  4166. $ruiObj.click
  4167.  
  4168. waitsecond(2)
  4169. end
  4170.  
  4171. tcase << TestAction.new(:scriptAction_CheckPass) do
  4172. $myTestResult = checkLastExistResult
  4173.  
  4174. if $myTestResult == false
  4175. $myFailReason == "Install Failed"
  4176. end
  4177. logStopTest("05_01_05_07_StoreFrontDownload")
  4178. end
  4179.  
  4180. tcase << TestAction.new(:pressBack_16) do
  4181. pressBack
  4182. end
  4183.  
  4184. tcase << TestAction.new(:pressBack_17) do
  4185. pressBack
  4186. end
  4187.  
  4188. tcase << TestAction.new(:pressHome_19) do
  4189. pressHome
  4190. end
  4191.  
  4192. tcase.run(loopTime)
  4193.  
  4194. end
  4195.  
  4196. def self.StoreFrontDownload_05_01_05_02(loopTime)
  4197.  
  4198. tcase = TestCase.new("StoreFrontDownload_05_01_05_02")
  4199.  
  4200. tcase << TestAction.new(:scriptAction_1) do
  4201. logStartTest("05_01_05_02_StoreFrontDownload")
  4202. end
  4203.  
  4204. tcase << TestAction.new(:gotoApp_2) do
  4205. gotoApp('Play Store')
  4206.  
  4207. waitsecond(8)
  4208. end
  4209.  
  4210. tcase << TestAction.new(:ImageView_SearchBoxIdleText_5) do
  4211. $ruiObj = RUIObject.new.with('objectid', 1987043402).with('selfid', 88317888).with('textdescid', -133777698).with('uniqueparentid', 0)
  4212. .with('uitreeindex', 32)
  4213. .with('classname', 'ImageView')
  4214. .with('resource-id', 'com.android.vending:id/search_box_idle_text')
  4215. .with('content-desc', 'Search')
  4216.  
  4217. $ruiObj.click
  4218.  
  4219. waitsecond(1)
  4220. end
  4221.  
  4222. tcase << TestAction.new(:EditText_SearchBoxTextInput_6) do
  4223. $ruiObj = RUIObject.new.with('objectid', 1660565057).with('selfid', 209465679).with('textdescid', -62090753).with('uniqueparentid', 0)
  4224. .with('uitreeindex', 32)
  4225. .with('classname', 'EditText')
  4226. .with('resource-id', 'com.android.vending:id/search_box_text_input')
  4227.  
  4228. $ruiObj.inputtext('ColorNote')
  4229.  
  4230. waitsecond(1)
  4231. end
  4232.  
  4233. tcase << TestAction.new(:pressEnter_2) do
  4234. pressEnter
  4235.  
  4236. waitsecond(4)
  4237. end
  4238.  
  4239. tcase << TestAction.new(:TextView_LiTitle_4) do
  4240. $ruiObj = RUIObject.new.with('objectid', 1456557201).with('selfid', -1969590474).with('textdescid', 83190698).with('uniqueparentid', 0)
  4241. .with('uitreeindex', 5)
  4242. .with('classname', 'TextView')
  4243. .with('resource-id', 'com.android.vending:id/li_title')
  4244. .with('content-desc', 'App: ColorNote Notepad Notes')
  4245. .with('text', 'ColorNote Notepad Notes')
  4246.  
  4247. $ruiObj.click
  4248.  
  4249. waitsecond(2)
  4250. end
  4251.  
  4252. tcase << TestAction.new(:Button_UninstallButton_UnInstall_exist) do
  4253. $ruiObj = RUIObject.new.with('objectid', -1388871150).with('selfid', -895718918).with('textdescid', -1334831508).with('uniqueparentid', 0)
  4254. .with('uitreeindex', 7)
  4255. .with('classname', 'Button')
  4256. .with('resource-id', 'com.android.vending:id/uninstall_button')
  4257. .with('text', 'UNINSTALL')
  4258.  
  4259. $ruiObj.isExist
  4260. ifFailJumpTo(:Button_BuyButton_1)
  4261.  
  4262. waitsecond(1)
  4263. end
  4264.  
  4265. tcase << TestAction.new(:Button_UninstallButton_UninstallCK_1) do
  4266. $ruiObj = RUIObject.new.with('objectid', -1388871150).with('selfid', -895718918).with('textdescid', -1334831508).with('uniqueparentid', 0)
  4267. .with('uitreeindex', 7)
  4268. .with('classname', 'Button')
  4269. .with('resource-id', 'com.android.vending:id/uninstall_button')
  4270. .with('text', 'UNINSTALL')
  4271.  
  4272. $ruiObj.click
  4273.  
  4274. waitsecond(1)
  4275. end
  4276.  
  4277. tcase << TestAction.new(:Button_Button1_Clk_OK) do
  4278. $ruiObj = RUIObject.new.with('objectid', 1379336962).with('selfid', -1318451484).with('textdescid', -1993773146).with('uniqueparentid', 0)
  4279. .with('uitreeindex', 2)
  4280. .with('classname', 'Button')
  4281. .with('resource-id', 'android:id/button1')
  4282. .with('text', 'OK')
  4283.  
  4284. $ruiObj.click
  4285.  
  4286. waitsecond(8)
  4287. end
  4288.  
  4289. tcase << TestAction.new(:Button_BuyButton_1) do
  4290. $ruiObj = RUIObject.new.with('objectid', 1237348910).with('selfid', -652886121).with('textdescid', 538738615).with('uniqueparentid', 0)
  4291. .with('uitreeindex', 7)
  4292. .with('classname', 'Button')
  4293. .with('resource-id', 'com.android.vending:id/buy_button')
  4294. .with('text', 'INSTALL')
  4295.  
  4296. $ruiObj.click
  4297.  
  4298. waitsecond(2)
  4299. end
  4300.  
  4301. tcase << TestAction.new(:Button_ContinueButton_2) do
  4302. $ruiObj = RUIObject.new.with('objectid', -1553570735).with('selfid', 1461394585).with('textdescid', 1663670089).with('uniqueparentid', 0)
  4303. .with('uitreeindex', 7)
  4304. .with('classname', 'Button')
  4305. .with('resource-id', 'com.android.vending:id/continue_button')
  4306. .with('text', 'ACCEPT')
  4307.  
  4308. $ruiObj.click
  4309.  
  4310. waitsecond(8)
  4311. end
  4312.  
  4313. tcase << TestAction.new(:Button_Button1_2) do
  4314. $ruiObj = RUIObject.new.with('objectid', 1379336962).with('selfid', 1349887951).with('textdescid', -101886821).with('uniqueparentid', 0)
  4315. .with('uitreeindex', 1)
  4316. .with('classname', 'Button')
  4317. .with('resource-id', 'android:id/button1')
  4318. .with('text', 'Continue')
  4319.  
  4320. $ruiObj.click
  4321.  
  4322. waitsecond(8)
  4323. end
  4324.  
  4325. tcase << TestAction.new(:Button_UninstallButton_4) do
  4326. $ruiObj = RUIObject.new.with('objectid', -1388871150).with('selfid', -895718918).with('textdescid', -1334831508).with('uniqueparentid', 0)
  4327. .with('uitreeindex', 7)
  4328. .with('classname', 'Button')
  4329. .with('resource-id', 'com.android.vending:id/uninstall_button')
  4330. .with('text', 'UNINSTALL')
  4331.  
  4332. $ruiObj.isExist
  4333.  
  4334. waitsecond(1)
  4335. end
  4336.  
  4337. tcase << TestAction.new(:scriptAction_CheckPass) do
  4338. $myTestResult = checkLastExistResult
  4339.  
  4340. if $myTestResult == false
  4341. $myFailReason == "Install Failed"
  4342. end
  4343. logStopTest("05_01_05_02_StoreFrontDownload")
  4344. end
  4345.  
  4346. tcase << TestAction.new(:pressBack_16) do
  4347. pressBack
  4348. end
  4349.  
  4350. tcase << TestAction.new(:pressBack_17) do
  4351. pressBack
  4352. end
  4353.  
  4354. tcase << TestAction.new(:pressHome_19) do
  4355. pressHome
  4356. end
  4357.  
  4358. tcase.run(loopTime)
  4359.  
  4360. end
  4361.  
  4362. def self.StoreFrontDownload_05_01_05_03(loopTime)
  4363.  
  4364. tcase = TestCase.new("StoreFrontDownload_05_01_05_03")
  4365.  
  4366. tcase << TestAction.new(:scriptAction_1) do
  4367. logStartTest("05_01_05_02_StoreFrontDownload")
  4368. end
  4369.  
  4370. tcase << TestAction.new(:gotoApp_2) do
  4371. gotoApp('Play Store')
  4372.  
  4373. waitsecond(4)
  4374. end
  4375.  
  4376. tcase << TestAction.new(:ImageView_SearchBoxIdleText_5) do
  4377. $ruiObj = RUIObject.new.with('objectid', 1987043402).with('selfid', 88317888).with('textdescid', -133777698).with('uniqueparentid', 0)
  4378. .with('uitreeindex', 32)
  4379. .with('classname', 'ImageView')
  4380. .with('resource-id', 'com.android.vending:id/search_box_idle_text')
  4381. .with('content-desc', 'Search')
  4382.  
  4383. $ruiObj.click
  4384.  
  4385. waitsecond(1)
  4386. end
  4387.  
  4388. tcase << TestAction.new(:EditText_SearchBoxTextInput_6) do
  4389. $ruiObj = RUIObject.new.with('objectid', 1660565057).with('selfid', 209465679).with('textdescid', -62090753).with('uniqueparentid', 0)
  4390. .with('uitreeindex', 32)
  4391. .with('classname', 'EditText')
  4392. .with('resource-id', 'com.android.vending:id/search_box_text_input')
  4393.  
  4394. $ruiObj.inputtext('ColorNote')
  4395.  
  4396. waitsecond(1)
  4397. end
  4398.  
  4399. tcase << TestAction.new(:pressEnter_2) do
  4400. pressEnter
  4401.  
  4402. waitsecond(4)
  4403. end
  4404.  
  4405. tcase << TestAction.new(:Button_UNINSTALL_2) do
  4406. $ruiObj = RUIObject.new.with('objectid', 2010819753).with('selfid', 1103650544).with('textdescid', -1596508299).with('uniqueparentid', 0)
  4407. .with('uitreeindex', 16)
  4408. .with('classname', 'Button')
  4409. .with('text', 'UNINSTALL')
  4410.  
  4411. $ruiObj.click
  4412.  
  4413. waitsecond(2)
  4414. end
  4415.  
  4416. tcase << TestAction.new(:Button_Button1_Clk_OK) do
  4417. $ruiObj = RUIObject.new.with('objectid', 1379336962).with('selfid', -1318451484).with('textdescid', -1993773146).with('uniqueparentid', 0)
  4418. .with('uitreeindex', 2)
  4419. .with('classname', 'Button')
  4420. .with('resource-id', 'android:id/button1')
  4421. .with('text', 'OK')
  4422.  
  4423. $ruiObj.click
  4424.  
  4425. waitsecond(8)
  4426. end
  4427.  
  4428. tcase << TestAction.new(:Button_INSTALL_4) do
  4429. $ruiObj = RUIObject.new.with('objectid', 2010819753).with('selfid', 998476585).with('textdescid', 841801628).with('uniqueparentid', 0)
  4430. .with('uitreeindex', 17)
  4431. .with('classname', 'Button')
  4432. .with('text', 'INSTALL')
  4433.  
  4434. $ruiObj.click
  4435.  
  4436. waitsecond(2)
  4437. end
  4438.  
  4439. tcase << TestAction.new(:Button_PositiveButton_4) do
  4440. $ruiObj = RUIObject.new.with('objectid', 1281581194).with('selfid', -1901489946).with('textdescid', -1976674237).with('uniqueparentid', 0)
  4441. .with('uitreeindex', 2)
  4442. .with('classname', 'Button')
  4443. .with('resource-id', 'com.android.vending:id/positive_button')
  4444. .with('text', 'CONTINUE')
  4445.  
  4446. $ruiObj.click
  4447.  
  4448. waitsecond(2)
  4449. end
  4450.  
  4451. tcase << TestAction.new(:wait1second_6) do
  4452. waitsecond(1)
  4453. end
  4454.  
  4455. tcase << TestAction.new(:Button_UNINSTALL_6) do
  4456. $ruiObj = RUIObject.new.with('objectid', 2010819753).with('selfid', 1103650544).with('textdescid', -1596508299).with('uniqueparentid', 0)
  4457. .with('uitreeindex', 16)
  4458. .with('classname', 'Button')
  4459. .with('text', 'UNINSTALL')
  4460.  
  4461. $ruiObj.isExist
  4462.  
  4463. waitsecond(0)
  4464. end
  4465.  
  4466. tcase << TestAction.new(:scriptAction_CheckPass) do
  4467. $myTestResult = checkLastExistResult
  4468.  
  4469. if $myTestResult == false
  4470. $myFailReason == "Install Failed"
  4471. end
  4472. logStopTest("05_01_05_02_StoreFrontDownload")
  4473. end
  4474.  
  4475. tcase << TestAction.new(:pressBack_16) do
  4476. pressBack
  4477. end
  4478.  
  4479. tcase << TestAction.new(:pressBack_17) do
  4480. pressBack
  4481. end
  4482.  
  4483. tcase << TestAction.new(:pressHome_19) do
  4484. pressHome
  4485. end
  4486.  
  4487. tcase.run(loopTime)
  4488.  
  4489. end
  4490.  
  4491. def self.StoreFrontDownload_05_01_05_04(loopTime)
  4492.  
  4493. tcase = TestCase.new("StoreFrontDownload_05_01_05_04")
  4494.  
  4495. tcase << TestAction.new(:scriptAction_1) do
  4496. logStartTest("05_01_05_07_StoreFrontDownload")
  4497. end
  4498.  
  4499. tcase << TestAction.new(:gotoApp_2) do
  4500. gotoApp('Play Store')
  4501.  
  4502. waitsecond(1)
  4503. end
  4504.  
  4505. tcase << TestAction.new(:ImageView_SearchBoxIdleText_5) do
  4506. $ruiObj = RUIObject.new.with('objectid', 1987043402).with('selfid', 88317888).with('textdescid', -133777698).with('uniqueparentid', 0)
  4507. .with('uitreeindex', 32)
  4508. .with('classname', 'ImageView')
  4509. .with('resource-id', 'com.android.vending:id/search_box_idle_text')
  4510. .with('content-desc', 'Search')
  4511.  
  4512. $ruiObj.click
  4513.  
  4514. waitsecond(1)
  4515. end
  4516.  
  4517. tcase << TestAction.new(:EditText_SearchBoxTextInput_6) do
  4518. $ruiObj = RUIObject.new.with('objectid', 1660565057).with('selfid', 209465679).with('textdescid', -62090753).with('uniqueparentid', 0)
  4519. .with('uitreeindex', 32)
  4520. .with('classname', 'EditText')
  4521. .with('resource-id', 'com.android.vending:id/search_box_text_input')
  4522.  
  4523. $ruiObj.inputtext('ColorNote')
  4524.  
  4525. waitsecond(2)
  4526. end
  4527.  
  4528. tcase << TestAction.new(:TextView_SuggestText_7_Click_ColorNote) do
  4529. $ruiObj = RUIObject.new.with('objectid', 193809363).with('selfid', 208620854).with('textdescid', 1052874934).with('uniqueparentid', 0)
  4530. .with('uitreeindex', 36)
  4531. .with('classname', 'TextView')
  4532. .with('resource-id', 'com.android.vending:id/suggest_text')
  4533. .with('text', 'ColorNote Notepad Notes')
  4534.  
  4535. $ruiObj.click
  4536.  
  4537. waitsecond(2)
  4538. end
  4539.  
  4540. tcase << TestAction.new(:Button_UninstallButton_15_pressed) do
  4541. $ruiObj = RUIObject.new.with('objectid', -1388871150).with('selfid', -895718918).with('textdescid', -1334831508).with('uniqueparentid', 0)
  4542. .with('uitreeindex', 7)
  4543. .with('classname', 'Button')
  4544. .with('resource-id', 'com.android.vending:id/uninstall_button')
  4545. .with('text', 'UNINSTALL')
  4546.  
  4547. $ruiObj.click
  4548.  
  4549. waitsecond(2)
  4550. end
  4551.  
  4552. tcase << TestAction.new(:Button_Button1_16_pressed_OK) do
  4553. $ruiObj = RUIObject.new.with('objectid', 1379336962).with('selfid', -1318451484).with('textdescid', -1993773146).with('uniqueparentid', 0)
  4554. .with('uitreeindex', 2)
  4555. .with('classname', 'Button')
  4556. .with('resource-id', 'android:id/button1')
  4557. .with('text', 'OK')
  4558.  
  4559. $ruiObj.click
  4560.  
  4561. waitsecond(8)
  4562. end
  4563.  
  4564. tcase << TestAction.new(:Button_BuyButton_1_1) do
  4565. $ruiObj = RUIObject.new.with('objectid', -329901969).with('selfid', -652886121).with('textdescid', 992432790).with('uniqueparentid', 0)
  4566. .with('uitreeindex', 7)
  4567. .with('classname', 'Button')
  4568. .with('resource-id', 'com.android.vending:id/buy_button')
  4569. .with('text', 'INSTALL')
  4570.  
  4571. $ruiObj.click
  4572.  
  4573. waitsecond(2)
  4574. end
  4575.  
  4576. tcase << TestAction.new(:scriptAction_CheckPass) do
  4577. $myTestResult = checkLastExistResult
  4578.  
  4579. if $myTestResult == false
  4580. $myFailReason == "Install Failed"
  4581. end
  4582. logStopTest("05_01_05_07_StoreFrontDownload")
  4583. end
  4584.  
  4585. tcase << TestAction.new(:pressBack_16) do
  4586. pressBack
  4587. end
  4588.  
  4589. tcase << TestAction.new(:pressBack_17) do
  4590. pressBack
  4591. end
  4592.  
  4593. tcase << TestAction.new(:pressHome_19) do
  4594. pressHome
  4595. end
  4596.  
  4597. tcase.run(loopTime)
  4598.  
  4599. end
  4600.  
  4601. def self.StoreFrontDownload_05_01_05_05(loopTime)
  4602.  
  4603. tcase = TestCase.new("StoreFrontDownload_05_01_05_05")
  4604.  
  4605. tcase << TestAction.new(:scriptAction_1) do
  4606. logStartTest("05_01_05_05_StoreFrontDownload")
  4607. end
  4608.  
  4609. tcase << TestAction.new(:gotoApp_2) do
  4610. gotoApp('ColorNote')
  4611.  
  4612. waitsecond(2)
  4613. end
  4614.  
  4615. tcase << TestAction.new(:Button_PermissionAllowButton_2) do
  4616. $ruiObj = RUIObject.new.with('objectid', -886457929).with('selfid', 1443382411).with('textdescid', 270556320).with('uniqueparentid', 0)
  4617. .with('uitreeindex', 3)
  4618. .with('classname', 'Button')
  4619. .with('resource-id', 'com.android.packageinstaller:id/permission_allow_button')
  4620. .with('text', 'ALLOW')
  4621.  
  4622. $ruiObj.click
  4623.  
  4624. waitsecond(1)
  4625. end
  4626.  
  4627. tcase << TestAction.new(:TextView_EmptyText_AddNoteCK) do
  4628. $ruiObj = RUIObject.new.with('objectid', -1225710509).with('selfid', -126164144).with('textdescid', -1803056542).with('uniqueparentid', 0)
  4629. .with('uitreeindex', 6)
  4630. .with('classname', 'TextView')
  4631. .with('resource-id', 'com.socialnmobile.dictapps.notepad.color.note:id/empty_text')
  4632. .with('text', 'Add Note')
  4633.  
  4634. $ruiObj.isExist
  4635.  
  4636. waitsecond(1)
  4637. end
  4638.  
  4639. tcase << TestAction.new(:pressBack_4) do
  4640. pressBack
  4641. end
  4642.  
  4643. tcase << TestAction.new(:scriptAction_True_False) do
  4644. $myTestResult = checkLastExistResult
  4645.  
  4646. if $myTestResult == false
  4647. $myFailReason == "Store Front is not loaded"
  4648. end
  4649. logStopTest("05_01_05_05_StoreFrontDownload")
  4650. end
  4651.  
  4652. tcase << TestAction.new(:pressHome_1) do
  4653. pressHome
  4654. end
  4655.  
  4656. tcase.run(loopTime)
  4657.  
  4658. end
  4659.  
  4660. def self.StoreFrontDownload_05_01_05_06(loopTime)
  4661.  
  4662. tcase = TestCase.new("StoreFrontDownload_05_01_05_06")
  4663.  
  4664. tcase << TestAction.new(:scriptAction_1) do
  4665. logStartTest("05_01_05_06_StoreFrontDownload")
  4666. end
  4667.  
  4668. tcase << TestAction.new(:gotoApp_2) do
  4669. gotoApp('Play Store')
  4670.  
  4671. waitsecond(1)
  4672. end
  4673.  
  4674. tcase << TestAction.new(:ImageView_SearchBoxIdleText_12) do
  4675. $ruiObj = RUIObject.new.with('objectid', 1987043402).with('selfid', 88317888).with('textdescid', -133777698).with('uniqueparentid', 0)
  4676. .with('uitreeindex', 28)
  4677. .with('classname', 'ImageView')
  4678. .with('resource-id', 'com.android.vending:id/search_box_idle_text')
  4679. .with('content-desc', 'Search')
  4680.  
  4681. $ruiObj.click
  4682.  
  4683. waitsecond(1)
  4684. end
  4685.  
  4686. tcase << TestAction.new(:EditText_SearchBoxTextInput_13) do
  4687. $ruiObj = RUIObject.new.with('objectid', 1660565057).with('selfid', 209465679).with('textdescid', -62090753).with('uniqueparentid', 0)
  4688. .with('uitreeindex', 28)
  4689. .with('classname', 'EditText')
  4690. .with('resource-id', 'com.android.vending:id/search_box_text_input')
  4691.  
  4692. $ruiObj.inputtext('ColorNote')
  4693.  
  4694. waitsecond(1)
  4695. end
  4696.  
  4697. tcase << TestAction.new(:TextView_SuggestText_16) do
  4698. $ruiObj = RUIObject.new.with('objectid', 193809363).with('selfid', 208620854).with('textdescid', 1052874934).with('uniqueparentid', 0)
  4699. .with('uitreeindex', 32)
  4700. .with('classname', 'TextView')
  4701. .with('resource-id', 'com.android.vending:id/suggest_text')
  4702. .with('text', 'ColorNote Notepad Notes')
  4703.  
  4704. $ruiObj.click
  4705.  
  4706. waitsecond(1)
  4707. end
  4708.  
  4709. tcase << TestAction.new(:TextView_LiTitle_2) do
  4710. $ruiObj = RUIObject.new.with('objectid', 1456557201).with('selfid', -1969590474).with('textdescid', 83190698).with('uniqueparentid', 0)
  4711. .with('uitreeindex', 5)
  4712. .with('classname', 'TextView')
  4713. .with('resource-id', 'com.android.vending:id/li_title')
  4714. .with('content-desc', 'App: ColorNote Notepad Notes')
  4715. .with('text', 'ColorNote Notepad Notes')
  4716.  
  4717. $ruiObj.click
  4718.  
  4719. waitsecond(1)
  4720. end
  4721.  
  4722. tcase << TestAction.new(:Button_LaunchButton_18) do
  4723. $ruiObj = RUIObject.new.with('objectid', 515078971).with('selfid', 328139855).with('textdescid', 387228145).with('uniqueparentid', 0)
  4724. .with('uitreeindex', 8)
  4725. .with('classname', 'Button')
  4726. .with('resource-id', 'com.android.vending:id/launch_button')
  4727. .with('text', 'OPEN')
  4728.  
  4729. $ruiObj.click
  4730.  
  4731. waitsecond(1)
  4732. end
  4733.  
  4734. tcase << TestAction.new(:TextView_EmptyText_AddNoteCK) do
  4735. $ruiObj = RUIObject.new.with('objectid', -1225710509).with('selfid', -126164144).with('textdescid', -1803056542).with('uniqueparentid', 0)
  4736. .with('uitreeindex', 6)
  4737. .with('classname', 'TextView')
  4738. .with('resource-id', 'com.socialnmobile.dictapps.notepad.color.note:id/empty_text')
  4739. .with('text', 'Add Note')
  4740.  
  4741. $ruiObj.isExist
  4742.  
  4743. waitsecond(1)
  4744. end
  4745.  
  4746. tcase << TestAction.new(:Button_PermissionAllowButton_1_1) do
  4747. $ruiObj = RUIObject.new.with('objectid', -886457929).with('selfid', 1443382411).with('textdescid', 270556320).with('uniqueparentid', 0)
  4748. .with('uitreeindex', 3)
  4749. .with('classname', 'Button')
  4750. .with('resource-id', 'com.android.packageinstaller:id/permission_allow_button')
  4751. .with('text', 'ALLOW')
  4752.  
  4753. $ruiObj.click
  4754.  
  4755. waitsecond(2)
  4756. end
  4757.  
  4758. tcase << TestAction.new(:pressBack_20) do
  4759. pressBack
  4760. end
  4761.  
  4762. tcase << TestAction.new(:scriptAction_22) do
  4763. $myTestResult = checkLastExistResult
  4764.  
  4765. if $myTestResult == false
  4766. $myFailReason == "Open DL app from Store Front Fail"
  4767. end
  4768. logStopTest("05_01_05_06_StoreFrontDownload")
  4769. end
  4770.  
  4771. tcase << TestAction.new(:pressBack_23) do
  4772. pressBack
  4773. end
  4774.  
  4775. tcase << TestAction.new(:pressBack_2) do
  4776. pressBack
  4777. end
  4778.  
  4779. tcase << TestAction.new(:pressHome_2) do
  4780. pressHome
  4781. end
  4782.  
  4783. tcase.run(loopTime)
  4784.  
  4785. end
  4786.  
  4787. def self.StoreFrontDownload_05_01_05_07(loopTime)
  4788.  
  4789. tcase = TestCase.new("StoreFrontDownload_05_01_05_07")
  4790.  
  4791. tcase << TestAction.new(:scriptAction_1) do
  4792. logStartTest("05_01_05_07_StoreFrontDownload")
  4793. end
  4794.  
  4795. tcase << TestAction.new(:gotoApp_2) do
  4796. gotoApp('Play Store')
  4797.  
  4798. waitsecond(1)
  4799. end
  4800.  
  4801. tcase << TestAction.new(:ImageView_SearchBoxIdleText_5) do
  4802. $ruiObj = RUIObject.new.with('objectid', 1987043402).with('selfid', 88317888).with('textdescid', -133777698).with('uniqueparentid', 0)
  4803. .with('uitreeindex', 32)
  4804. .with('classname', 'ImageView')
  4805. .with('resource-id', 'com.android.vending:id/search_box_idle_text')
  4806. .with('content-desc', 'Search')
  4807.  
  4808. $ruiObj.click
  4809.  
  4810. waitsecond(1)
  4811. end
  4812.  
  4813. tcase << TestAction.new(:EditText_SearchBoxTextInput_6) do
  4814. $ruiObj = RUIObject.new.with('objectid', 1660565057).with('selfid', 209465679).with('textdescid', -62090753).with('uniqueparentid', 0)
  4815. .with('uitreeindex', 32)
  4816. .with('classname', 'EditText')
  4817. .with('resource-id', 'com.android.vending:id/search_box_text_input')
  4818.  
  4819. $ruiObj.inputtext('ColorNote')
  4820.  
  4821. waitsecond(1)
  4822. end
  4823.  
  4824. tcase << TestAction.new(:TextView_SuggestText_7_Click_ColorNote) do
  4825. $ruiObj = RUIObject.new.with('objectid', 193809363).with('selfid', 208620854).with('textdescid', 1052874934).with('uniqueparentid', 0)
  4826. .with('uitreeindex', 36)
  4827. .with('classname', 'TextView')
  4828. .with('resource-id', 'com.android.vending:id/suggest_text')
  4829. .with('text', 'ColorNote Notepad Notes')
  4830.  
  4831. $ruiObj.click
  4832.  
  4833. waitsecond(1)
  4834. end
  4835.  
  4836. tcase << TestAction.new(:TextView_LiTitle_2) do
  4837. $ruiObj = RUIObject.new.with('objectid', 1456557201).with('selfid', -1969590474).with('textdescid', 83190698).with('uniqueparentid', 0)
  4838. .with('uitreeindex', 5)
  4839. .with('classname', 'TextView')
  4840. .with('resource-id', 'com.android.vending:id/li_title')
  4841. .with('content-desc', 'App: ColorNote Notepad Notes')
  4842. .with('text', 'ColorNote Notepad Notes')
  4843.  
  4844. $ruiObj.click
  4845.  
  4846. waitsecond(1)
  4847. end
  4848.  
  4849. tcase << TestAction.new(:Button_UninstallButton_15_pressed) do
  4850. $ruiObj = RUIObject.new.with('objectid', -1388871150).with('selfid', -895718918).with('textdescid', -1334831508).with('uniqueparentid', 0)
  4851. .with('uitreeindex', 7)
  4852. .with('classname', 'Button')
  4853. .with('resource-id', 'com.android.vending:id/uninstall_button')
  4854. .with('text', 'UNINSTALL')
  4855.  
  4856. $ruiObj.click
  4857.  
  4858. waitsecond(1)
  4859. end
  4860.  
  4861. tcase << TestAction.new(:Button_Button1_16_pressed_OK) do
  4862. $ruiObj = RUIObject.new.with('objectid', 1379336962).with('selfid', -1318451484).with('textdescid', -1993773146).with('uniqueparentid', 0)
  4863. .with('uitreeindex', 2)
  4864. .with('classname', 'Button')
  4865. .with('resource-id', 'android:id/button1')
  4866. .with('text', 'OK')
  4867.  
  4868. $ruiObj.click
  4869.  
  4870. waitsecond(8)
  4871. end
  4872.  
  4873. tcase << TestAction.new(:Button_BuyButton_18_Install) do
  4874. $ruiObj = RUIObject.new.with('objectid', 1237348910).with('selfid', -652886121).with('textdescid', 538738615).with('uniqueparentid', 0)
  4875. .with('uitreeindex', 7)
  4876. .with('classname', 'Button')
  4877. .with('resource-id', 'com.android.vending:id/buy_button')
  4878. .with('text', 'INSTALL')
  4879.  
  4880. $ruiObj.isExist
  4881.  
  4882. waitsecond(1)
  4883. end
  4884.  
  4885. tcase << TestAction.new(:scriptAction_CheckPass) do
  4886. $myTestResult = checkLastExistResult
  4887.  
  4888. if $myTestResult == false
  4889. $myFailReason == "Install Failed"
  4890. end
  4891. logStopTest("05_01_05_07_StoreFrontDownload")
  4892. end
  4893.  
  4894. tcase << TestAction.new(:pressBack_16) do
  4895. pressBack
  4896. end
  4897.  
  4898. tcase << TestAction.new(:pressBack_17) do
  4899. pressBack
  4900. end
  4901.  
  4902. tcase << TestAction.new(:pressHome_19) do
  4903. pressHome
  4904. end
  4905.  
  4906. tcase.run(loopTime)
  4907.  
  4908. end
  4909.  
  4910. def self.StoreFrontDownload_05_01_05_08(loopTime)
  4911.  
  4912. tcase = TestCase.new("StoreFrontDownload_05_01_05_08")
  4913.  
  4914. tcase << TestAction.new(:scriptAction_1) do
  4915. logStartTest("05_01_05_02_StoreFrontDownload")
  4916. end
  4917.  
  4918. tcase << TestAction.new(:gotoApp_2) do
  4919. gotoApp('Play Store')
  4920.  
  4921. waitsecond(8)
  4922. end
  4923.  
  4924. tcase << TestAction.new(:ImageView_SearchBoxIdleText_5) do
  4925. $ruiObj = RUIObject.new.with('objectid', 1987043402).with('selfid', 88317888).with('textdescid', -133777698).with('uniqueparentid', 0)
  4926. .with('uitreeindex', 32)
  4927. .with('classname', 'ImageView')
  4928. .with('resource-id', 'com.android.vending:id/search_box_idle_text')
  4929. .with('content-desc', 'Search')
  4930.  
  4931. $ruiObj.click
  4932.  
  4933. waitsecond(1)
  4934. end
  4935.  
  4936. tcase << TestAction.new(:EditText_SearchBoxTextInput_6) do
  4937. $ruiObj = RUIObject.new.with('objectid', 1660565057).with('selfid', 209465679).with('textdescid', -62090753).with('uniqueparentid', 0)
  4938. .with('uitreeindex', 32)
  4939. .with('classname', 'EditText')
  4940. .with('resource-id', 'com.android.vending:id/search_box_text_input')
  4941.  
  4942. $ruiObj.inputtext('ColorNote')
  4943.  
  4944. waitsecond(1)
  4945. end
  4946.  
  4947. tcase << TestAction.new(:pressEnter_2) do
  4948. pressEnter
  4949.  
  4950. waitsecond(4)
  4951. end
  4952.  
  4953. tcase << TestAction.new(:TextView_LiTitle_2) do
  4954. $ruiObj = RUIObject.new.with('objectid', 1456557201).with('selfid', -1969590474).with('textdescid', 83190698).with('uniqueparentid', 0)
  4955. .with('uitreeindex', 1)
  4956. .with('classname', 'TextView')
  4957. .with('resource-id', 'com.android.vending:id/li_title')
  4958. .with('content-desc', 'App: ColorNote Notepad Notes')
  4959. .with('text', 'ColorNote Notepad Notes')
  4960.  
  4961. $ruiObj.click
  4962.  
  4963. waitsecond(2)
  4964. end
  4965.  
  4966. tcase << TestAction.new(:Button_UninstallButton_UnInstall_exist) do
  4967. $ruiObj = RUIObject.new.with('objectid', -1388871150).with('selfid', -895718918).with('textdescid', -1334831508).with('uniqueparentid', 0)
  4968. .with('uitreeindex', 7)
  4969. .with('classname', 'Button')
  4970. .with('resource-id', 'com.android.vending:id/uninstall_button')
  4971. .with('text', 'UNINSTALL')
  4972.  
  4973. $ruiObj.isExist
  4974. ifFailJumpTo(:Button_BuyButton_1)
  4975.  
  4976. waitsecond(1)
  4977. end
  4978.  
  4979. tcase << TestAction.new(:Button_UninstallButton_UninstallCK_1) do
  4980. $ruiObj = RUIObject.new.with('objectid', -1388871150).with('selfid', -895718918).with('textdescid', -1334831508).with('uniqueparentid', 0)
  4981. .with('uitreeindex', 7)
  4982. .with('classname', 'Button')
  4983. .with('resource-id', 'com.android.vending:id/uninstall_button')
  4984. .with('text', 'UNINSTALL')
  4985.  
  4986. $ruiObj.click
  4987.  
  4988. waitsecond(1)
  4989. end
  4990.  
  4991. tcase << TestAction.new(:Button_Button1_Clk_OK) do
  4992. $ruiObj = RUIObject.new.with('objectid', 1379336962).with('selfid', -1318451484).with('textdescid', -1993773146).with('uniqueparentid', 0)
  4993. .with('uitreeindex', 2)
  4994. .with('classname', 'Button')
  4995. .with('resource-id', 'android:id/button1')
  4996. .with('text', 'OK')
  4997.  
  4998. $ruiObj.click
  4999.  
  5000. waitsecond(8)
  5001. end
  5002.  
  5003. tcase << TestAction.new(:Button_BuyButton_1) do
  5004. $ruiObj = RUIObject.new.with('objectid', 1237348910).with('selfid', -652886121).with('textdescid', 538738615).with('uniqueparentid', 0)
  5005. .with('uitreeindex', 7)
  5006. .with('classname', 'Button')
  5007. .with('resource-id', 'com.android.vending:id/buy_button')
  5008. .with('text', 'INSTALL')
  5009.  
  5010. $ruiObj.click
  5011.  
  5012. waitsecond(2)
  5013. end
  5014.  
  5015. tcase << TestAction.new(:Button_PositiveButton_4) do
  5016. $ruiObj = RUIObject.new.with('objectid', 1281581194).with('selfid', -1901489946).with('textdescid', -1976674237).with('uniqueparentid', 0)
  5017. .with('uitreeindex', 2)
  5018. .with('classname', 'Button')
  5019. .with('resource-id', 'com.android.vending:id/positive_button')
  5020. .with('text', 'CONTINUE')
  5021.  
  5022. $ruiObj.click
  5023.  
  5024. waitsecond(2)
  5025. end
  5026.  
  5027. tcase << TestAction.new(:wait1second_6) do
  5028. waitsecond(1)
  5029. end
  5030.  
  5031. tcase << TestAction.new(:Button_UninstallButton_4) do
  5032. $ruiObj = RUIObject.new.with('objectid', -1388871150).with('selfid', -895718918).with('textdescid', -1334831508).with('uniqueparentid', 0)
  5033. .with('uitreeindex', 7)
  5034. .with('classname', 'Button')
  5035. .with('resource-id', 'com.android.vending:id/uninstall_button')
  5036. .with('text', 'UNINSTALL')
  5037.  
  5038. $ruiObj.isExist
  5039.  
  5040. waitsecond(1)
  5041. end
  5042.  
  5043. tcase << TestAction.new(:scriptAction_CheckPass) do
  5044. $myTestResult = checkLastExistResult
  5045.  
  5046. if $myTestResult == false
  5047. $myFailReason == "Install Failed"
  5048. end
  5049. logStopTest("05_01_05_02_StoreFrontDownload")
  5050. end
  5051.  
  5052. tcase << TestAction.new(:pressBack_16) do
  5053. pressBack
  5054. end
  5055.  
  5056. tcase << TestAction.new(:pressBack_17) do
  5057. pressBack
  5058. end
  5059.  
  5060. tcase << TestAction.new(:pressHome_19) do
  5061. pressHome
  5062. end
  5063.  
  5064. tcase.run(loopTime)
  5065.  
  5066. end
  5067.  
  5068. def self.Telephony_05_01_01_01(loopTime)
  5069.  
  5070. tcase = TestCase.new("Telephony_05_01_01_01")
  5071.  
  5072. tcase << TestAction.new(:scriptAction_StartTest_1) do
  5073. logStartTest("05_01_01_01_Telephony")
  5074. end
  5075.  
  5076. tcase << TestAction.new(:pressHome_4) do
  5077. pressHome
  5078. end
  5079.  
  5080. tcase << TestAction.new(:TextView_Phone_2) do
  5081. $ruiObj = RUIObject.new.with('objectid', -479243074).with('selfid', 1134672426).with('textdescid', 1322329030).with('uniqueparentid', 0)
  5082. .with('uitreeindex', 9)
  5083. .with('classname', 'TextView')
  5084. .with('content-desc', 'Phone')
  5085. .with('text', 'Phone')
  5086.  
  5087. $ruiObj.click
  5088.  
  5089. waitsecond(1)
  5090. end
  5091.  
  5092. tcase << TestAction.new(:TextView_Tabtext_2) do
  5093. $ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 1015283306).with('textdescid', -1384079800).with('uniqueparentid', 0)
  5094. .with('uitreeindex', 4)
  5095. .with('classname', 'TextView')
  5096. .with('resource-id', 'com.android.contacts:id/tabText')
  5097. .with('text', 'Contacts')
  5098.  
  5099. $ruiObj.click
  5100.  
  5101. waitsecond(1)
  5102. end
  5103.  
  5104. tcase << TestAction.new(:TextView_MenuUnifiedSearch_2) do
  5105. $ruiObj = RUIObject.new.with('objectid', 706565921).with('selfid', 1315899886).with('textdescid', 449577447).with('uniqueparentid', 0)
  5106. .with('uitreeindex', 1)
  5107. .with('classname', 'TextView')
  5108. .with('resource-id', 'com.android.contacts:id/menu_unified_search')
  5109. .with('content-desc', 'Search')
  5110.  
  5111. $ruiObj.click
  5112.  
  5113. waitsecond(1)
  5114. end
  5115.  
  5116. tcase << TestAction.new(:EditText_SearchSrcText_4) do
  5117. $ruiObj = RUIObject.new.with('objectid', 588070375).with('selfid', -959326622).with('textdescid', -497243406).with('uniqueparentid', 0)
  5118. .with('uitreeindex', 6)
  5119. .with('classname', 'EditText')
  5120. .with('resource-id', 'android:id/search_src_text')
  5121. .with('content-desc', 'Search contacts')
  5122.  
  5123. $ruiObj.inputtext('A01')
  5124.  
  5125. waitsecond(1)
  5126. end
  5127.  
  5128. tcase << TestAction.new(:scriptAction_10_1) do
  5129. sendBTCmd('pressHome')
  5130. end
  5131.  
  5132. tcase << TestAction.new(:ImageView_Button1_4) do
  5133. $ruiObj = RUIObject.new.with('objectid', 527611238).with('selfid', 643737864).with('textdescid', -1665703716).with('uniqueparentid', 0).with('classresourceid', -1143292048)
  5134. .with('uitreeindex', 7)
  5135. .with('pretext', 'A01 a01?0')
  5136. .with('classname', 'ImageView')
  5137. .with('resource-id', 'android:id/button1')
  5138. .with('content-desc', 'Call A01 a01')
  5139.  
  5140. $ruiObj.click
  5141.  
  5142. waitsecond(12)
  5143. end
  5144.  
  5145. tcase << TestAction.new(:scriptAction_10) do
  5146. sendBTCmd('answerCall')
  5147.  
  5148. waitsecond(8)
  5149. end
  5150.  
  5151. tcase << TestAction.new(:scriptAction_10_1) do
  5152. sendBTCmd('endCall')
  5153.  
  5154. waitsecond(1)
  5155. end
  5156.  
  5157. tcase << TestAction.new(:scriptAction_LogStopTest_1_1) do
  5158. $myTestResult = checkLastBTCmdResult
  5159. if $myTestResult == false
  5160. $myFailReason = "Call not come to other dev"
  5161. end
  5162. logStopTest("05_01_01_01_Telephony")
  5163.  
  5164. end
  5165.  
  5166. tcase << TestAction.new(:Button_Endbutton_2) do
  5167. $ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
  5168. .with('uitreeindex', 8)
  5169. .with('classname', 'Button')
  5170. .with('resource-id', 'com.android.incallui:id/endButton')
  5171. .with('text', 'End')
  5172.  
  5173. $ruiObj.click
  5174.  
  5175. waitsecond(1)
  5176. end
  5177.  
  5178. tcase << TestAction.new(:pressBack_3) do
  5179. pressBack
  5180. end
  5181.  
  5182. tcase << TestAction.new(:pressBack_4) do
  5183. pressBack
  5184. end
  5185.  
  5186. tcase.run(loopTime)
  5187.  
  5188. end
  5189.  
  5190. def self.Telephony_05_01_01_03(loopTime)
  5191.  
  5192. tcase = TestCase.new("Telephony_05_01_01_03")
  5193.  
  5194. tcase << TestAction.new(:scriptAction_StartTest_1) do
  5195. logStartTest("05_01_01_03_Telephony")
  5196. end
  5197.  
  5198. tcase << TestAction.new(:gotoApp_1_1) do
  5199. gotoApp('Phone')
  5200. end
  5201.  
  5202. tcase << TestAction.new(:TextView_Tabtext_2) do
  5203. $ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 715664122).with('textdescid', 24268628).with('uniqueparentid', 0)
  5204. .with('uitreeindex', 3)
  5205. .with('classname', 'TextView')
  5206. .with('resource-id', 'com.android.contacts:id/tabText')
  5207. .with('text', 'Call logs')
  5208.  
  5209. $ruiObj.click
  5210.  
  5211. waitsecond(2)
  5212. end
  5213.  
  5214. tcase << TestAction.new(:ImageView_SecondaryActionIcon_4) do
  5215. $ruiObj = RUIObject.new.with('objectid', 1053896352).with('selfid', -1241359936).with('textdescid', 579079266).with('uniqueparentid', 0).with('classresourceid', -550590844)
  5216. .with('uitreeindex', 9)
  5217. .with('classname', 'ImageView')
  5218. .with('resource-id', 'com.android.contacts:id/secondary_action_icon')
  5219. .with('content-desc', 'Call A01 a01')
  5220.  
  5221. $ruiObj.click
  5222.  
  5223. waitsecond(2)
  5224. end
  5225.  
  5226. tcase << TestAction.new(:wait8second_31) do
  5227. waitsecond(8)
  5228. end
  5229.  
  5230. tcase << TestAction.new(:scriptAction_10_1) do
  5231. sendBTCmd('answerCall')
  5232.  
  5233. waitsecond(8)
  5234. end
  5235.  
  5236. tcase << TestAction.new(:scriptAction_10_1_1) do
  5237. sendBTCmd('endCall')
  5238.  
  5239. waitsecond(1)
  5240. end
  5241.  
  5242. tcase << TestAction.new(:scriptAction_LogStopTest) do
  5243. $myTestResult = checkLastBTCmdResult
  5244. if $myTestResult == false
  5245. $myFailReason = "Call not come to other dev"
  5246. end
  5247. logStopTest("05_01_01_03_Telephony")
  5248.  
  5249. end
  5250.  
  5251. tcase << TestAction.new(:Button_Endbutton_6) do
  5252. $ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
  5253. .with('uitreeindex', 8)
  5254. .with('classname', 'Button')
  5255. .with('resource-id', 'com.android.incallui:id/endButton')
  5256. .with('text', 'End')
  5257.  
  5258. $ruiObj.click
  5259.  
  5260. waitsecond(1)
  5261. end
  5262.  
  5263. tcase << TestAction.new(:pressBack_1) do
  5264. pressBack
  5265. end
  5266.  
  5267. tcase << TestAction.new(:pressBack_2) do
  5268. pressBack
  5269. end
  5270.  
  5271. tcase << TestAction.new(:pressHome_6) do
  5272. pressHome
  5273. end
  5274.  
  5275. tcase.run(loopTime)
  5276.  
  5277. end
  5278.  
  5279. def self.Telephony_05_01_01_05(loopTime)
  5280.  
  5281. tcase = TestCase.new("Telephony_05_01_01_05")
  5282.  
  5283. tcase << TestAction.new(:pressHome_2) do
  5284. pressHome
  5285. end
  5286.  
  5287. tcase << TestAction.new(:scriptAction_StartTestLog_1) do
  5288. logStartTest("05_01_01_05_Telephony")
  5289. end
  5290.  
  5291. tcase << TestAction.new(:scriptAction_BTMakeCall) do
  5292. sendBTCmd("makeCall(#{db('CallNumber')[0]}.to_s)")
  5293.  
  5294. waitsecond(8)
  5295. end
  5296.  
  5297. tcase << TestAction.new(:wait8second_12) do
  5298. waitsecond(18)
  5299. end
  5300.  
  5301. tcase << TestAction.new(:wait8second_14) do
  5302. waitsecond(8)
  5303. end
  5304.  
  5305. tcase << TestAction.new(:answerSwipe_1) do
  5306. $UIDev.swipe(288,2083.5,828,1192.5,10)
  5307.  
  5308.  
  5309. waitsecond(8)
  5310. end
  5311.  
  5312. tcase << TestAction.new(:Button_Endbutton_2_1) do
  5313. $ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
  5314. .with('uitreeindex', 10)
  5315. .with('classname', 'Button')
  5316. .with('resource-id', 'com.android.incallui:id/endButton')
  5317. .with('text', 'End')
  5318.  
  5319. $ruiObj.isExist
  5320.  
  5321. waitsecond(0)
  5322. end
  5323.  
  5324. tcase << TestAction.new(:scriptAction_LogStopTest_1) do
  5325. $myTestResult = checkLastExistResult
  5326. if $myTestResult == false
  5327. $myFailReason = "End button not found"
  5328. end
  5329. logStopTest("05_01_01_05_Telephony")
  5330.  
  5331. end
  5332.  
  5333. tcase << TestAction.new(:Button_Endbutton_2_1_1) do
  5334. $ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
  5335. .with('uitreeindex', 10)
  5336. .with('classname', 'Button')
  5337. .with('resource-id', 'com.android.incallui:id/endButton')
  5338. .with('text', 'End')
  5339.  
  5340. $ruiObj.click
  5341.  
  5342. waitsecond(0)
  5343. end
  5344.  
  5345. tcase << TestAction.new(:pressBack_1) do
  5346. pressBack
  5347. end
  5348.  
  5349. tcase << TestAction.new(:pressBack_2) do
  5350. pressBack
  5351. end
  5352.  
  5353. tcase << TestAction.new(:pressHome_24) do
  5354. pressHome
  5355.  
  5356. waitsecond(0)
  5357. end
  5358.  
  5359. tcase.run(loopTime)
  5360.  
  5361. end
  5362.  
  5363. def self.Telephony_05_01_01_06(loopTime)
  5364.  
  5365. tcase = TestCase.new("Telephony_05_01_01_06")
  5366.  
  5367. tcase << TestAction.new(:scriptAction_StartTestLog) do
  5368. logStartTest("05_01_01_06_Telephony")
  5369. end
  5370.  
  5371. tcase << TestAction.new(:gotoApp_3) do
  5372. gotoApp('Phone')
  5373. end
  5374.  
  5375. tcase << TestAction.new(:TextView_Tabtext_2) do
  5376. $ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 1015283306).with('textdescid', -1384079800).with('uniqueparentid', 0)
  5377. .with('uitreeindex', 4)
  5378. .with('classname', 'TextView')
  5379. .with('resource-id', 'com.android.contacts:id/tabText')
  5380. .with('text', 'Contacts')
  5381.  
  5382. $ruiObj.click
  5383.  
  5384. waitsecond(1)
  5385. end
  5386.  
  5387. tcase << TestAction.new(:TextView_MenuUnifiedSearch_2) do
  5388. $ruiObj = RUIObject.new.with('objectid', 706565921).with('selfid', 1315899886).with('textdescid', 449577447).with('uniqueparentid', 0)
  5389. .with('uitreeindex', 1)
  5390. .with('classname', 'TextView')
  5391. .with('resource-id', 'com.android.contacts:id/menu_unified_search')
  5392. .with('content-desc', 'Search')
  5393.  
  5394. $ruiObj.click
  5395.  
  5396. waitsecond(1)
  5397. end
  5398.  
  5399. tcase << TestAction.new(:EditText_SearchSrcText_2) do
  5400. $ruiObj = RUIObject.new.with('objectid', 588070375).with('selfid', -959326622).with('textdescid', -497243406).with('uniqueparentid', 0)
  5401. .with('uitreeindex', 6)
  5402. .with('classname', 'EditText')
  5403. .with('resource-id', 'android:id/search_src_text')
  5404. .with('content-desc', 'Search contacts')
  5405.  
  5406. $ruiObj.inputtext('tn tn')
  5407.  
  5408. waitsecond(1)
  5409. end
  5410.  
  5411. tcase << TestAction.new(:TextView_tn_6) do
  5412. $ruiObj = RUIObject.new.with('objectid', 1836583107).with('selfid', -71120562).with('textdescid', 984860861).with('uniqueparentid', 0).with('classresourceid', -938935918)
  5413. .with('uitreeindex', 13)
  5414. .with('classname', 'TextView')
  5415. .with('content-desc', 'tn tn')
  5416. .with('text', 'tn tn')
  5417.  
  5418. $ruiObj.select('ItemFirst').click
  5419.  
  5420. waitsecond(1)
  5421. end
  5422.  
  5423. tcase << TestAction.new(:TextView_MenuDelete_2) do
  5424. $ruiObj = RUIObject.new.with('objectid', -1318735913).with('selfid', 1219450656).with('textdescid', 2068859689).with('uniqueparentid', 0)
  5425. .with('uitreeindex', 23)
  5426. .with('pretext', 'NOTIFICATION SOUND')
  5427. .with('classname', 'TextView')
  5428. .with('resource-id', 'com.android.contacts:id/menu_delete')
  5429.  
  5430. $ruiObj.click
  5431.  
  5432. waitsecond(1)
  5433. end
  5434.  
  5435. tcase << TestAction.new(:Button_Button1_43) do
  5436. $ruiObj = RUIObject.new.with('objectid', -195446968).with('selfid', 982364851).with('textdescid', -1387444483).with('uniqueparentid', 0)
  5437. .with('uitreeindex', 2)
  5438. .with('classname', 'Button')
  5439. .with('resource-id', 'android:id/button1')
  5440. .with('text', 'DELETE')
  5441.  
  5442. $ruiObj.isExist
  5443.  
  5444. waitsecond(1)
  5445. end
  5446.  
  5447. tcase << TestAction.new(:Button_Button1_22_1) do
  5448. $ruiObj = RUIObject.new.with('objectid', -195446968).with('selfid', -1318451484).with('textdescid', 917278956).with('uniqueparentid', 0)
  5449. .with('uitreeindex', 2)
  5450. .with('classname', 'Button')
  5451. .with('resource-id', 'android:id/button1')
  5452. .with('text', 'OK')
  5453.  
  5454. $ruiObj.click
  5455.  
  5456. waitsecond(1)
  5457. end
  5458.  
  5459. tcase << TestAction.new(:scriptAction_LogStopTest) do
  5460. $myTestResult = checkLastExistResult
  5461. if $myTestResult == false
  5462. $myFailReason = "End button not found"
  5463. end
  5464. logStopTest("05_01_01_06_Telephony")
  5465. end
  5466.  
  5467. tcase << TestAction.new(:pressBack_2) do
  5468. pressBack
  5469. end
  5470.  
  5471. tcase << TestAction.new(:pressBack_3) do
  5472. pressBack
  5473. end
  5474.  
  5475. tcase.run(loopTime)
  5476.  
  5477. end
  5478.  
  5479. def self.Telephony_05_01_01_07(loopTime)
  5480.  
  5481. tcase = TestCase.new("Telephony_05_01_01_07")
  5482.  
  5483. tcase << TestAction.new(:scriptAction_StartTestLog) do
  5484. logStartTest("05_01_01_07_Telephony")
  5485. end
  5486.  
  5487. tcase << TestAction.new(:gotoApp_3) do
  5488. gotoApp('Phone')
  5489.  
  5490. waitsecond(1)
  5491. end
  5492.  
  5493. tcase << TestAction.new(:TextView_Tabtext_2) do
  5494. $ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 1015283306).with('textdescid', -1384079800).with('uniqueparentid', 0)
  5495. .with('uitreeindex', 4)
  5496. .with('classname', 'TextView')
  5497. .with('resource-id', 'com.android.contacts:id/tabText')
  5498. .with('text', 'Contacts')
  5499.  
  5500. $ruiObj.click
  5501.  
  5502. waitsecond(1)
  5503. end
  5504.  
  5505. tcase << TestAction.new(:FrameLayout_FloatingActionButtonContainer_2) do
  5506. $ruiObj = RUIObject.new.with('objectid', 565383936).with('selfid', 1632442836).with('textdescid', -1928520608).with('uniqueparentid', 0)
  5507. .with('classname', 'FrameLayout')
  5508. .with('resource-id', 'com.android.contacts:id/floating_action_button_container')
  5509. .with('content-desc', 'New contact')
  5510.  
  5511. $ruiObj.click
  5512.  
  5513. waitsecond(2)
  5514. end
  5515.  
  5516. tcase << TestAction.new(:EditText_14) do
  5517. $ruiObj = RUIObject.new.with('objectid', -2023645967).with('selfid', 1666676343).with('textdescid', 1691484495).with('uniqueparentid', 0).with('classresourceid', 1666676343)
  5518. .with('uitreeindex', 6)
  5519. .with('pretext', 'Phone?0')
  5520. .with('classname', 'EditText')
  5521.  
  5522. $ruiObj.inputtext('tn tn')
  5523.  
  5524. waitsecond(1)
  5525. end
  5526.  
  5527. tcase << TestAction.new(:ImageButton_AddContactButton_2) do
  5528. $ruiObj = RUIObject.new.with('objectid', 168201771).with('selfid', 2046190261).with('textdescid', 1812475979).with('uniqueparentid', 0)
  5529. .with('uitreeindex', 8)
  5530. .with('classname', 'ImageButton')
  5531. .with('resource-id', 'com.android.contacts:id/add_contact_button')
  5532. .with('content-desc', 'New contact')
  5533.  
  5534. $ruiObj.click
  5535.  
  5536. waitsecond(2)
  5537. end
  5538.  
  5539. tcase << TestAction.new(:EditText_4) do
  5540. $ruiObj = RUIObject.new.with('objectid', 1622197326).with('selfid', 1666676343).with('textdescid', -1251490414).with('uniqueparentid', 0).with('classresourceid', 1666676343)
  5541. .with('uitreeindex', 10)
  5542. .with('pretext', 'Phone?1')
  5543. .with('classname', 'EditText')
  5544.  
  5545. $ruiObj.inputtext('00000000')
  5546.  
  5547. waitsecond(1)
  5548. end
  5549.  
  5550. tcase << TestAction.new(:Button_BtnSave_4) do
  5551. $ruiObj = RUIObject.new.with('objectid', 344009592).with('selfid', -1684371128).with('textdescid', -1561576549).with('uniqueparentid', 0)
  5552. .with('uitreeindex', 19)
  5553. .with('classname', 'Button')
  5554. .with('resource-id', 'com.android.contacts:id/btn_save')
  5555. .with('text', 'SAVE')
  5556.  
  5557. $ruiObj.isExist
  5558.  
  5559. waitsecond(1)
  5560. end
  5561.  
  5562. tcase << TestAction.new(:Button_BtnSave_20) do
  5563. $ruiObj = RUIObject.new.with('objectid', 344009592).with('selfid', -1684339352).with('textdescid', -1560591493).with('uniqueparentid', 0)
  5564. .with('uitreeindex', 16)
  5565. .with('classname', 'Button')
  5566. .with('resource-id', 'com.android.contacts:id/btn_save')
  5567. .with('text', 'Save')
  5568.  
  5569. $ruiObj.click
  5570.  
  5571. waitsecond(1)
  5572. end
  5573.  
  5574. tcase << TestAction.new(:scriptAction_LogStopTest) do
  5575. $myTestResult = checkLastExistResult
  5576. if $myTestResult == false
  5577. $myFailReason = "Contact is not saved"
  5578. end
  5579. logStopTest("05_01_01_07_Telephony")
  5580. end
  5581.  
  5582. tcase << TestAction.new(:pressBack_5) do
  5583. pressBack
  5584. end
  5585.  
  5586. tcase << TestAction.new(:pressBack_6) do
  5587. pressBack
  5588. end
  5589.  
  5590. tcase.run(loopTime)
  5591.  
  5592. end
  5593.  
  5594. def self.VideoCall_01(loopTime)
  5595.  
  5596. tcase = TestCase.new("VideoCall_01")
  5597.  
  5598. tcase << TestAction.new(:scriptAction_StartTest_1) do
  5599. logStartTest("VideoCall_01")
  5600. end
  5601.  
  5602. tcase << TestAction.new(:pressHome_4) do
  5603. pressHome
  5604. end
  5605.  
  5606. tcase << TestAction.new(:TextView_Phone_2) do
  5607. $ruiObj = RUIObject.new.with('objectid', -479243074).with('selfid', 1134672426).with('textdescid', 1322329030).with('uniqueparentid', 0)
  5608. .with('uitreeindex', 9)
  5609. .with('classname', 'TextView')
  5610. .with('content-desc', 'Phone')
  5611. .with('text', 'Phone')
  5612.  
  5613. $ruiObj.click
  5614.  
  5615. waitsecond(1)
  5616. end
  5617.  
  5618. tcase << TestAction.new(:TextView_Tabtext_2) do
  5619. $ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 1015283306).with('textdescid', -1384079800).with('uniqueparentid', 0)
  5620. .with('uitreeindex', 4)
  5621. .with('classname', 'TextView')
  5622. .with('resource-id', 'com.android.contacts:id/tabText')
  5623. .with('text', 'Contacts')
  5624.  
  5625. $ruiObj.click
  5626.  
  5627. waitsecond(1)
  5628. end
  5629.  
  5630. tcase << TestAction.new(:EditText_SearchSrcText_2) do
  5631. $ruiObj = RUIObject.new.with('objectid', 588070375).with('selfid', -959326622).with('textdescid', -497243406).with('uniqueparentid', 0)
  5632. .with('uitreeindex', 6)
  5633. .with('classname', 'EditText')
  5634. .with('resource-id', 'android:id/search_src_text')
  5635. .with('content-desc', 'Search contacts')
  5636.  
  5637. $ruiObj.inputtext('A01 a01')
  5638.  
  5639. waitsecond(1)
  5640. end
  5641.  
  5642. tcase << TestAction.new(:TextView_A01_4) do
  5643. $ruiObj = RUIObject.new.with('objectid', -728261803).with('selfid', -2094016618).with('textdescid', -1517178717).with('uniqueparentid', 0).with('classresourceid', -938935918)
  5644. .with('uitreeindex', 12)
  5645. .with('classname', 'TextView')
  5646. .with('content-desc', 'A01 a01')
  5647. .with('text', 'A01 a01')
  5648.  
  5649. $ruiObj.click
  5650.  
  5651. waitsecond(1)
  5652. end
  5653.  
  5654. tcase << TestAction.new(:ImageView_EabActionButton_2) do
  5655. $ruiObj = RUIObject.new.with('objectid', -209436562).with('selfid', 14418249).with('textdescid', 2097401202).with('uniqueparentid', 0).with('classresourceid', -1382351217)
  5656. .with('uitreeindex', 9)
  5657. .with('classname', 'ImageView')
  5658. .with('resource-id', 'com.android.contacts:id/eab_action_button')
  5659.  
  5660. $ruiObj.click
  5661.  
  5662. waitsecond(1)
  5663. end
  5664.  
  5665. tcase << TestAction.new(:wait8second_31) do
  5666. waitsecond(8)
  5667. end
  5668.  
  5669. tcase << TestAction.new(:scriptAction_18_1) do
  5670. sendBTCmd('answerCall')
  5671.  
  5672. waitsecond(8)
  5673. end
  5674.  
  5675. tcase << TestAction.new(:scriptAction_18_1_1) do
  5676. sendBTCmd('endCall')
  5677.  
  5678. waitsecond(2)
  5679. end
  5680.  
  5681. tcase << TestAction.new(:scriptAction_LogStopTest_1_1) do
  5682. $myTestResult = checkLastBTCmdResult
  5683. if $myTestResult == false
  5684. $myFailReason = "Call not come to other dev"
  5685. end
  5686. logStopTest("VideoCall_01")
  5687.  
  5688. end
  5689.  
  5690. tcase << TestAction.new(:Button_ButtonEndCall_4) do
  5691. $ruiObj = RUIObject.new.with('objectid', 449066258).with('selfid', 2024460923).with('textdescid', -1859117805).with('uniqueparentid', 0)
  5692. .with('uitreeindex', 8)
  5693. .with('classname', 'Button')
  5694. .with('resource-id', 'com.android.incallui:id/button_end_call')
  5695. .with('text', 'End')
  5696.  
  5697. $ruiObj.click
  5698.  
  5699. waitsecond(1)
  5700. end
  5701.  
  5702. tcase << TestAction.new(:pressBack_3) do
  5703. pressBack
  5704. end
  5705.  
  5706. tcase << TestAction.new(:pressBack_4) do
  5707. pressBack
  5708. end
  5709.  
  5710. tcase.run(loopTime)
  5711.  
  5712. end
  5713.  
  5714. def self.VideoTelephony_05_01_14_01(loopTime)
  5715.  
  5716. tcase = TestCase.new("VideoTelephony_05_01_14_01")
  5717.  
  5718. tcase << TestAction.new(:scriptAction_StartTest_1) do
  5719. logStartTest("VideoCall_01")
  5720. end
  5721.  
  5722. tcase << TestAction.new(:pressHome_1_1) do
  5723. pressHome
  5724.  
  5725. waitsecond(2)
  5726. end
  5727.  
  5728. tcase << TestAction.new(:TextView_Phone_2) do
  5729. $ruiObj = RUIObject.new.with('objectid', -479243074).with('selfid', 1134672426).with('textdescid', 1322329030).with('uniqueparentid', 0)
  5730. .with('uitreeindex', 9)
  5731. .with('classname', 'TextView')
  5732. .with('content-desc', 'Phone')
  5733. .with('text', 'Phone')
  5734.  
  5735. $ruiObj.click
  5736.  
  5737. waitsecond(1)
  5738. end
  5739.  
  5740. tcase << TestAction.new(:TextView_Tabtext_2) do
  5741. $ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 1015283306).with('textdescid', -1384079800).with('uniqueparentid', 0)
  5742. .with('uitreeindex', 4)
  5743. .with('classname', 'TextView')
  5744. .with('resource-id', 'com.android.contacts:id/tabText')
  5745. .with('text', 'Contacts')
  5746.  
  5747. $ruiObj.click
  5748.  
  5749. waitsecond(1)
  5750. end
  5751.  
  5752. tcase << TestAction.new(:EditText_SearchSrcText_2) do
  5753. $ruiObj = RUIObject.new.with('objectid', 588070375).with('selfid', -959326622).with('textdescid', -497243406).with('uniqueparentid', 0)
  5754. .with('uitreeindex', 6)
  5755. .with('classname', 'EditText')
  5756. .with('resource-id', 'android:id/search_src_text')
  5757. .with('content-desc', 'Search contacts')
  5758.  
  5759. $ruiObj.inputtext('A01 a01')
  5760.  
  5761. waitsecond(1)
  5762. end
  5763.  
  5764. tcase << TestAction.new(:TextView_A01_4) do
  5765. $ruiObj = RUIObject.new.with('objectid', -728261803).with('selfid', -2094016618).with('textdescid', -1517178717).with('uniqueparentid', 0).with('classresourceid', -938935918)
  5766. .with('uitreeindex', 12)
  5767. .with('classname', 'TextView')
  5768. .with('content-desc', 'A01 a01')
  5769. .with('text', 'A01 a01')
  5770.  
  5771. $ruiObj.click
  5772.  
  5773. waitsecond(1)
  5774. end
  5775.  
  5776. tcase << TestAction.new(:VideoCallButton) do
  5777. $attVideoCallButton = RUIObject.new.with('objectid', -209436562).with('selfid', 14418249).with('textdescid', 2097401202).with('uniqueparentid', 0).with('classresourceid', -1382351217)
  5778. .with('uitreeindex', 9)
  5779. .with('classname', 'ImageView')
  5780. .with('resource-id', 'com.android.contacts:id/eab_action_button')
  5781.  
  5782. $uplusVideoCallButton = RUIObject.new.with('objectid', -284633982).with('selfid', -1819582550).with('textdescid', -721488607).with('uniqueparentid', 0).with('classresourceid', 745414969)
  5783. .with('uitreeindex', 12)
  5784. .with('classname', 'ImageView')
  5785. .with('resource-id', 'com.android.contacts:id/first_action_button')
  5786. .with('content-desc', 'Video call')
  5787.  
  5788. if $attVideoCallButton.isExist
  5789. $attVideoCallButton.click
  5790. elsif $uplusVideoCallButton.isExist
  5791. $uplusVideoCallButton.click
  5792. end
  5793.  
  5794. waitsecond(2)
  5795. end
  5796.  
  5797. tcase << TestAction.new(:ImageView_FirstActionButton_4) do
  5798. $ruiObj = RUIObject.new.with('objectid', -284633982).with('selfid', -1819582550).with('textdescid', -721488607).with('uniqueparentid', 0).with('classresourceid', 745414969)
  5799. .with('uitreeindex', 12)
  5800. .with('classname', 'ImageView')
  5801. .with('resource-id', 'com.android.contacts:id/first_action_button')
  5802. .with('content-desc', 'Video call')
  5803.  
  5804. $ruiObj.click
  5805.  
  5806. waitsecond(2)
  5807. end
  5808.  
  5809. tcase << TestAction.new(:wait8second_31) do
  5810. waitsecond(8)
  5811. end
  5812.  
  5813. tcase << TestAction.new(:scriptAction_18_1) do
  5814. sendBTCmd('answerCall')
  5815.  
  5816. waitsecond(8)
  5817. end
  5818.  
  5819. tcase << TestAction.new(:TextView_Callstatelabel_1_1) do
  5820. $ruiObj = RUIObject.new.with('objectid', -611515845).with('selfid', -821184504).with('textdescid', -1124622931).with('uniqueparentid', 0)
  5821. .with('uitreeindex', 5)
  5822. .with('classname', 'TextView')
  5823. .with('resource-id', 'com.android.incallui:id/callStateLabel')
  5824. .with('text', 'Incoming call')
  5825.  
  5826. $ruiObj.isNotExist
  5827. end
  5828.  
  5829. tcase << TestAction.new(:scriptAction_18_1_1) do
  5830. endCall
  5831.  
  5832. waitsecond(2)
  5833. end
  5834.  
  5835. tcase << TestAction.new(:scriptAction_LogStopTest_1_1) do
  5836. $myTestResult = checkLastBTCmdResult
  5837. if $myTestResult == false
  5838. $myFailReason = "Call not come to other dev"
  5839. end
  5840. logStopTest("VideoCall_01")
  5841.  
  5842. end
  5843.  
  5844. tcase << TestAction.new(:Button_ButtonEndCall_4) do
  5845. $ruiObj = RUIObject.new.with('objectid', 449066258).with('selfid', 2024460923).with('textdescid', -1859117805).with('uniqueparentid', 0)
  5846. .with('uitreeindex', 8)
  5847. .with('classname', 'Button')
  5848. .with('resource-id', 'com.android.incallui:id/button_end_call')
  5849. .with('text', 'End')
  5850.  
  5851. $ruiObj.click
  5852.  
  5853. waitsecond(1)
  5854. end
  5855.  
  5856. tcase << TestAction.new(:pressBack_3) do
  5857. pressBack
  5858. end
  5859.  
  5860. tcase << TestAction.new(:pressBack_4) do
  5861. pressBack
  5862. end
  5863.  
  5864. tcase << TestAction.new(:pressHome_1) do
  5865. pressHome
  5866.  
  5867. waitsecond(2)
  5868. end
  5869.  
  5870. tcase.run(loopTime)
  5871.  
  5872. end
  5873.  
  5874. def self.VideoTelephony_05_01_14_02(loopTime)
  5875.  
  5876. tcase = TestCase.new("VideoTelephony_05_01_14_02")
  5877.  
  5878. tcase << TestAction.new(:scriptAction_StartTest_1) do
  5879. logStartTest("VideoCall_02")
  5880. end
  5881.  
  5882. tcase << TestAction.new(:pressHome_2) do
  5883. pressHome
  5884.  
  5885. waitsecond(2)
  5886. end
  5887.  
  5888. tcase << TestAction.new(:TextView_Phone_2) do
  5889. $ruiObj = RUIObject.new.with('objectid', -479243074).with('selfid', 1134672426).with('textdescid', 1322329030).with('uniqueparentid', 0)
  5890. .with('uitreeindex', 9)
  5891. .with('classname', 'TextView')
  5892. .with('content-desc', 'Phone')
  5893. .with('text', 'Phone')
  5894.  
  5895. $ruiObj.click
  5896.  
  5897. waitsecond(1)
  5898. end
  5899.  
  5900. tcase << TestAction.new(:TextView_Tabtext_4) do
  5901. $ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 1015283306).with('textdescid', -1384079800).with('uniqueparentid', 0)
  5902. .with('uitreeindex', 4)
  5903. .with('classname', 'TextView')
  5904. .with('resource-id', 'com.android.contacts:id/tabText')
  5905. .with('text', 'Contacts')
  5906.  
  5907. $ruiObj.click
  5908.  
  5909. waitsecond(2)
  5910. end
  5911.  
  5912. tcase << TestAction.new(:EditText_SearchSrcText_6) do
  5913. $ruiObj = RUIObject.new.with('objectid', 588070375).with('selfid', -959326622).with('textdescid', -497243406).with('uniqueparentid', 0)
  5914. .with('uitreeindex', 6)
  5915. .with('classname', 'EditText')
  5916. .with('resource-id', 'android:id/search_src_text')
  5917. .with('content-desc', 'Search contacts')
  5918.  
  5919. $ruiObj.inputtext('A01 a01')
  5920.  
  5921. waitsecond(2)
  5922. end
  5923.  
  5924. tcase << TestAction.new(:TextView_A01_8) do
  5925. $ruiObj = RUIObject.new.with('objectid', -728261803).with('selfid', -2094016618).with('textdescid', -1517178717).with('uniqueparentid', 0).with('classresourceid', -938935918)
  5926. .with('uitreeindex', 12)
  5927. .with('classname', 'TextView')
  5928. .with('content-desc', 'A01 a01')
  5929. .with('text', 'A01 a01')
  5930.  
  5931. $ruiObj.click
  5932.  
  5933. waitsecond(2)
  5934. end
  5935.  
  5936. tcase << TestAction.new(:ImageView_FirstActionButton_10) do
  5937. $ruiObj = RUIObject.new.with('objectid', -284633982).with('selfid', -1819582550).with('textdescid', -721488607).with('uniqueparentid', 0).with('classresourceid', 745414969)
  5938. .with('uitreeindex', 10)
  5939. .with('classname', 'ImageView')
  5940. .with('resource-id', 'com.android.contacts:id/first_action_button')
  5941. .with('content-desc', 'Video call')
  5942.  
  5943. $ruiObj.click
  5944.  
  5945. waitsecond(2)
  5946. end
  5947.  
  5948. tcase << TestAction.new(:wait8second_2) do
  5949. waitsecond(8)
  5950. end
  5951.  
  5952. tcase << TestAction.new(:scriptAction_18_1) do
  5953. sendBTCmd('answerCall')
  5954.  
  5955. waitsecond(8)
  5956. end
  5957.  
  5958. tcase << TestAction.new(:TextView_Callstatelabel_1_1_1) do
  5959. $ruiObj = RUIObject.new.with('objectid', -611515845).with('selfid', -821184504).with('textdescid', -1124622931).with('uniqueparentid', 0)
  5960. .with('uitreeindex', 5)
  5961. .with('classname', 'TextView')
  5962. .with('resource-id', 'com.android.incallui:id/callStateLabel')
  5963. .with('text', 'Incoming call')
  5964.  
  5965. $ruiObj.isNotExist
  5966. end
  5967.  
  5968. tcase << TestAction.new(:scriptAction_18_1_1) do
  5969. sendBTCmd('endCall')
  5970.  
  5971. waitsecond(2)
  5972. end
  5973.  
  5974. tcase << TestAction.new(:scriptAction_LogStopTest_1_1) do
  5975. $myTestResult = checkLastBTCmdResult
  5976. if $myTestResult == false
  5977. $myFailReason = "Call not come to other dev"
  5978. end
  5979. logStopTest("VideoCall_02")
  5980. end
  5981.  
  5982. tcase << TestAction.new(:Button_ButtonEndCall_4) do
  5983. $ruiObj = RUIObject.new.with('objectid', 449066258).with('selfid', 2024460923).with('textdescid', -1859117805).with('uniqueparentid', 0)
  5984. .with('uitreeindex', 8)
  5985. .with('classname', 'Button')
  5986. .with('resource-id', 'com.android.incallui:id/button_end_call')
  5987. .with('text', 'End')
  5988.  
  5989. $ruiObj.click
  5990.  
  5991. waitsecond(1)
  5992. end
  5993.  
  5994. tcase << TestAction.new(:pressBack_3) do
  5995. pressBack
  5996. end
  5997.  
  5998. tcase << TestAction.new(:pressBack_4) do
  5999. pressBack
  6000. end
  6001.  
  6002. tcase << TestAction.new(:pressHome_12) do
  6003. pressHome
  6004.  
  6005. waitsecond(2)
  6006. end
  6007.  
  6008. tcase.run(loopTime)
  6009.  
  6010. end
  6011.  
  6012. def self.VideoTelephony_05_01_14_03(loopTime)
  6013.  
  6014. tcase = TestCase.new("VideoTelephony_05_01_14_03")
  6015.  
  6016. tcase << TestAction.new(:scriptAction_StartTest_1) do
  6017. logStartTest("VideoCall_03")
  6018. end
  6019.  
  6020. tcase << TestAction.new(:scriptAction_18_1_1) do
  6021. sendBTCmd("makeVideoCall('#{db('CallNumber')[0]}')")
  6022.  
  6023. waitsecond(32)
  6024. end
  6025.  
  6026. tcase << TestAction.new(:scriptAction_26) do
  6027. $UIDev.swipe(288,2083.5,828,1192.5,10)
  6028.  
  6029.  
  6030. waitsecond(8)
  6031. end
  6032.  
  6033. tcase << TestAction.new(:TextView_Callstatelabel_1_1_1_1) do
  6034. $ruiObj = RUIObject.new.with('objectid', -611515845).with('selfid', -821184504).with('textdescid', -1124622931).with('uniqueparentid', 0)
  6035. .with('uitreeindex', 5)
  6036. .with('classname', 'TextView')
  6037. .with('resource-id', 'com.android.incallui:id/callStateLabel')
  6038. .with('text', 'Incoming call')
  6039.  
  6040. $ruiObj.isNotExist
  6041. end
  6042.  
  6043. tcase << TestAction.new(:scriptAction_2) do
  6044. endCall
  6045.  
  6046. waitsecond(2)
  6047. end
  6048.  
  6049. tcase << TestAction.new(:scriptAction_LogStopTest_1_1_1) do
  6050. $myTestResult = checkLastBTCmdResult
  6051. if $myTestResult == false
  6052. $myFailReason = "Call not come to other dev"
  6053. end
  6054. logStopTest("VideoCall_03")
  6055. end
  6056.  
  6057. tcase.run(loopTime)
  6058.  
  6059. end
  6060.  
  6061. def self.VideoTelephony_05_01_14_04(loopTime)
  6062.  
  6063. tcase = TestCase.new("VideoTelephony_05_01_14_04")
  6064.  
  6065. tcase << TestAction.new(:scriptAction_StartTest_1) do
  6066. logStartTest("VideoCall_04")
  6067. end
  6068.  
  6069. tcase << TestAction.new(:scriptAction_18_1_1) do
  6070. sendBTCmd("makeVideoCall('#{db('CallNumber')[0]}')")
  6071.  
  6072. waitsecond(32)
  6073. end
  6074.  
  6075. tcase << TestAction.new(:scriptAction_26) do
  6076. answerCall
  6077.  
  6078. waitsecond(8)
  6079. end
  6080.  
  6081. tcase << TestAction.new(:TextView_Callstatelabel_1_1_1_1_1) do
  6082. $ruiObj = RUIObject.new.with('objectid', -611515845).with('selfid', -821184504).with('textdescid', -1124622931).with('uniqueparentid', 0)
  6083. .with('uitreeindex', 5)
  6084. .with('classname', 'TextView')
  6085. .with('resource-id', 'com.android.incallui:id/callStateLabel')
  6086. .with('text', 'Incoming call')
  6087.  
  6088. $ruiObj.isNotExist
  6089. end
  6090.  
  6091. tcase << TestAction.new(:scriptAction_2) do
  6092. endCall
  6093.  
  6094. waitsecond(2)
  6095. end
  6096.  
  6097. tcase << TestAction.new(:scriptAction_LogStopTest_1_1_1) do
  6098. $myTestResult = checkLastBTCmdResult
  6099. if $myTestResult == false
  6100. $myFailReason = "Call not come to other dev"
  6101. end
  6102. logStopTest("VideoCall_04")
  6103. end
  6104.  
  6105. tcase.run(loopTime)
  6106.  
  6107. end
  6108.  
  6109. def self.VideoTelephony_05_01_14_05(loopTime)
  6110.  
  6111. tcase = TestCase.new("VideoTelephony_05_01_14_05")
  6112.  
  6113. tcase << TestAction.new(:scriptAction_StartTest_1) do
  6114. logStartTest("VideoCall_05")
  6115. end
  6116.  
  6117. tcase << TestAction.new(:TextView_Phone_2) do
  6118. $ruiObj = RUIObject.new.with('objectid', -479243074).with('selfid', 1134672426).with('textdescid', 1322329030).with('uniqueparentid', 0)
  6119. .with('uitreeindex', 9)
  6120. .with('classname', 'TextView')
  6121. .with('content-desc', 'Phone')
  6122. .with('text', 'Phone')
  6123.  
  6124. $ruiObj.click
  6125.  
  6126. waitsecond(1)
  6127. end
  6128.  
  6129. tcase << TestAction.new(:TextView_Tabtext_23) do
  6130. $ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 566119687).with('textdescid', 1861262411).with('uniqueparentid', 0)
  6131. .with('uitreeindex', 2)
  6132. .with('classname', 'TextView')
  6133. .with('resource-id', 'com.android.contacts:id/tabText')
  6134. .with('text', 'Dial')
  6135.  
  6136. $ruiObj.click
  6137.  
  6138. waitsecond(2)
  6139. end
  6140.  
  6141. tcase << TestAction.new(:scriptAction_2) do
  6142. $ruiObj = RUIObject.new.with('objectid', 477485968).with('selfid', -1326421482).with('textdescid', 1917163152).with('uniqueparentid', 0)
  6143. .with('uitreeindex', 7)
  6144. .with('classname', 'EditText')
  6145. .with('resource-id', 'com.android.contacts:id/digits')
  6146.  
  6147. $ruiObj.inputtext("#{db('CallNumber')[1]}")
  6148.  
  6149. waitsecond(2)
  6150. end
  6151.  
  6152. tcase << TestAction.new(:ImageButton_Btnvt_6) do
  6153. $ruiObj = RUIObject.new.with('objectid', -999718621).with('selfid', -1888469943).with('textdescid', -1795784128).with('uniqueparentid', 0)
  6154. .with('uitreeindex', 61)
  6155. .with('classname', 'ImageButton')
  6156. .with('resource-id', 'com.android.contacts:id/btnVT')
  6157. .with('content-desc', 'Video Call')
  6158.  
  6159. $ruiObj.click
  6160.  
  6161. waitsecond(2)
  6162. end
  6163.  
  6164. tcase << TestAction.new(:wait8second_2) do
  6165. waitsecond(8)
  6166. end
  6167.  
  6168. tcase << TestAction.new(:scriptAction_18_1) do
  6169. sendBTCmd('answerCall')
  6170.  
  6171. waitsecond(8)
  6172. end
  6173.  
  6174. tcase << TestAction.new(:TextView_Callstatelabel_1_1_1_1_1_1) do
  6175. $ruiObj = RUIObject.new.with('objectid', -611515845).with('selfid', -821184504).with('textdescid', -1124622931).with('uniqueparentid', 0)
  6176. .with('uitreeindex', 5)
  6177. .with('classname', 'TextView')
  6178. .with('resource-id', 'com.android.incallui:id/callStateLabel')
  6179. .with('text', 'Incoming call')
  6180.  
  6181. $ruiObj.isNotExist
  6182. end
  6183.  
  6184. tcase << TestAction.new(:scriptAction_18_1_1) do
  6185. sendBTCmd('endCall')
  6186.  
  6187. waitsecond(2)
  6188. end
  6189.  
  6190. tcase << TestAction.new(:scriptAction_LogStopTest_1_1) do
  6191. $myTestResult = checkLastBTCmdResult
  6192. if $myTestResult == false
  6193. $myFailReason = "Call not come to other dev"
  6194. end
  6195. logStopTest("VideoCall_05")
  6196. end
  6197.  
  6198. tcase << TestAction.new(:Button_ButtonEndCall_4) do
  6199. $ruiObj = RUIObject.new.with('objectid', 449066258).with('selfid', 2024460923).with('textdescid', -1859117805).with('uniqueparentid', 0)
  6200. .with('uitreeindex', 8)
  6201. .with('classname', 'Button')
  6202. .with('resource-id', 'com.android.incallui:id/button_end_call')
  6203. .with('text', 'End')
  6204.  
  6205. $ruiObj.click
  6206.  
  6207. waitsecond(1)
  6208. end
  6209.  
  6210. tcase << TestAction.new(:pressBack_3) do
  6211. pressBack
  6212. end
  6213.  
  6214. tcase << TestAction.new(:pressBack_4) do
  6215. pressBack
  6216. end
  6217.  
  6218. tcase.run(loopTime)
  6219.  
  6220. end
  6221.  
  6222. def self.WiFi_05_01_10_01(loopTime)
  6223.  
  6224. tcase = TestCase.new("WiFi_05_01_10_01")
  6225.  
  6226. tcase << TestAction.new(:scriptAction_2) do
  6227. logStartTest("05_01_10_01_WiFi")
  6228. end
  6229.  
  6230. tcase << TestAction.new(:gotoApp_5) do
  6231. gotoApp('Settings')
  6232.  
  6233. waitsecond(1)
  6234. end
  6235.  
  6236. tcase << TestAction.new(:FrameLayout_SettingsButtonContainer_4) do
  6237. $ruiObj = RUIObject.new.with('objectid', -994030416).with('selfid', 1322766864).with('textdescid', 417942116).with('uniqueparentid', 0)
  6238. .with('classname', 'FrameLayout')
  6239. .with('resource-id', 'com.android.systemui:id/settings_button_container')
  6240.  
  6241. $ruiObj.click
  6242.  
  6243. waitsecond(1)
  6244. end
  6245.  
  6246. tcase << TestAction.new(:TextView_Title_2) do
  6247. $ruiObj = RUIObject.new.with('objectid', 674368800).with('selfid', -2078686330).with('textdescid', -957350501).with('uniqueparentid', 0)
  6248. .with('uitreeindex', 2)
  6249. .with('classname', 'TextView')
  6250. .with('resource-id', 'android:id/title')
  6251. .with('text', 'Networks')
  6252.  
  6253. $ruiObj.click
  6254. end
  6255.  
  6256. tcase << TestAction.new(:swipeUp_1) do
  6257. swipe_vertical_back 500
  6258. end
  6259.  
  6260. tcase << TestAction.new(:TextView_Title_4) do
  6261. $ruiObj = RUIObject.new.with('objectid', 2008023572).with('selfid', -589731018).with('textdescid', 498664031).with('uniqueparentid', 0).with('classresourceid', 490183159)
  6262. .with('uitreeindex', 8)
  6263. .with('classname', 'TextView')
  6264. .with('resource-id', 'android:id/title')
  6265. .with('text', 'WiFi')
  6266.  
  6267. $ruiObj.click
  6268.  
  6269. waitsecond(1)
  6270. end
  6271.  
  6272. tcase << TestAction.new(:Button_Button2_2) do
  6273. $ruiObj = RUIObject.new.with('objectid', -360890209).with('selfid', -1317527958).with('textdescid', -223504546).with('uniqueparentid', 0)
  6274. .with('uitreeindex', 2)
  6275. .with('classname', 'Button')
  6276. .with('resource-id', 'android:id/button2')
  6277. .with('text', 'No')
  6278.  
  6279. $ruiObj.click
  6280.  
  6281. waitsecond(4)
  6282. end
  6283.  
  6284. tcase << TestAction.new(:Switch_ON_2_1) do
  6285. $ruiObj = RUIObject.new.with('objectid', 1178284996).with('selfid', 1645353587).with('textdescid', -1975291963).with('uniqueparentid', 0)
  6286. .with('uitreeindex', 2)
  6287. .with('classname', 'Switch')
  6288. .with('text', 'ON')
  6289.  
  6290. $ruiObj.click
  6291.  
  6292. waitsecond(2)
  6293. end
  6294.  
  6295. tcase << TestAction.new(:wait8second_6) do
  6296. waitsecond(8)
  6297. end
  6298.  
  6299. tcase << TestAction.new(:Switch_OFF_3_1) do
  6300. $ruiObj = RUIObject.new.with('objectid', 1178284996).with('selfid', -533646533).with('textdescid', -1104515187).with('uniqueparentid', 0)
  6301. .with('uitreeindex', 2)
  6302. .with('classname', 'Switch')
  6303. .with('text', 'OFF')
  6304.  
  6305. $ruiObj.click
  6306.  
  6307. waitsecond(2)
  6308. end
  6309.  
  6310. tcase << TestAction.new(:scriptAction_10_TrueFalse) do
  6311. $myTestResult = checkLastExistResult
  6312.  
  6313. if $myTestResult == false
  6314. $myFailReason = "WiFi cannot turn ON"
  6315. end
  6316. logStopTest("05_01_10_01_WiFi")
  6317.  
  6318. waitsecond(1)
  6319. end
  6320.  
  6321. tcase << TestAction.new(:pressBack_20) do
  6322. pressBack
  6323. end
  6324.  
  6325. tcase << TestAction.new(:pressBack_21) do
  6326. pressBack
  6327. end
  6328.  
  6329. tcase << TestAction.new(:pressHome_22) do
  6330. pressHome
  6331. end
  6332.  
  6333. tcase.run(loopTime)
  6334.  
  6335. end
  6336.  
  6337. def self.WiFi_05_01_10_02(loopTime)
  6338.  
  6339. tcase = TestCase.new("WiFi_05_01_10_02")
  6340.  
  6341. tcase << TestAction.new(:scriptAction_2) do
  6342. logStartTest("05_01_10_02_WiFi")
  6343. end
  6344.  
  6345. tcase << TestAction.new(:gotoApp_2) do
  6346. gotoApp('Settings')
  6347.  
  6348. waitsecond(1)
  6349. end
  6350.  
  6351. tcase << TestAction.new(:TextView_Title_2) do
  6352. $ruiObj = RUIObject.new.with('objectid', 674368800).with('selfid', -2078686330).with('textdescid', -957350501).with('uniqueparentid', 0)
  6353. .with('uitreeindex', 2)
  6354. .with('classname', 'TextView')
  6355. .with('resource-id', 'android:id/title')
  6356. .with('text', 'Networks')
  6357.  
  6358. $ruiObj.click
  6359. end
  6360.  
  6361. tcase << TestAction.new(:swipeUp_2) do
  6362. swipe_vertical_back 500
  6363. end
  6364.  
  6365. tcase << TestAction.new(:TextView_Title_21) do
  6366. $ruiObj = RUIObject.new.with('objectid', -1417852313).with('selfid', -589731018).with('textdescid', 1796571250).with('uniqueparentid', 0).with('classresourceid', 490183159)
  6367. .with('uitreeindex', 16)
  6368. .with('classname', 'TextView')
  6369. .with('resource-id', 'android:id/title')
  6370. .with('text', 'WiFi')
  6371.  
  6372. $ruiObj.click
  6373.  
  6374. waitsecond(2)
  6375. end
  6376.  
  6377. tcase << TestAction.new(:TextView_Empty_25) do
  6378. $ruiObj = RUIObject.new.with('objectid', 1333259948).with('selfid', -886975434).with('textdescid', 1201392520).with('uniqueparentid', 0)
  6379. .with('uitreeindex', 4)
  6380. .with('classname', 'TextView')
  6381. .with('resource-id', 'android:id/empty')
  6382. .with('text', 'Turn WiFi on in the upper right corner to see available networks')
  6383.  
  6384. $ruiObj.isExist
  6385. ifFailJumpTo(:wait1second_21)
  6386. end
  6387.  
  6388. tcase << TestAction.new(:Switch_ON_2_1_1) do
  6389. $ruiObj = RUIObject.new.with('objectid', 1178284996).with('selfid', 1645353587).with('textdescid', -1975291963).with('uniqueparentid', 0)
  6390. .with('uitreeindex', 2)
  6391. .with('classname', 'Switch')
  6392. .with('text', 'ON')
  6393.  
  6394. $ruiObj.click
  6395. end
  6396.  
  6397. tcase << TestAction.new(:wait1second_21) do
  6398. waitsecond(1)
  6399. end
  6400.  
  6401. tcase << TestAction.new(:check_if_wifi_is_added) do
  6402. $ruiObj = RUIObject.new.with('objectid', -1789239232).with('selfid', -789618896).with('textdescid', 272817007).with('uniqueparentid', 0).with('classresourceid', 490183159)
  6403. .with('uitreeindex', 11)
  6404. .with('classname', 'TextView')
  6405. .with('resource-id', 'android:id/title')
  6406. .with('text', 'qctcomp')
  6407.  
  6408. $ruiObj.isNotExist
  6409. ifFailJumpTo(:check_connection)
  6410.  
  6411. waitsecond(1)
  6412. end
  6413.  
  6414. tcase << TestAction.new(:Add_wifi) do
  6415. $ruiObj = RUIObject.new.with('objectid', 1634319278).with('selfid', 1290820192).with('textdescid', 371464933).with('uniqueparentid', 0)
  6416. .with('uitreeindex', 3)
  6417. .with('classname', 'ImageButton')
  6418. .with('content-desc', 'More options')
  6419.  
  6420. $ruiObj.click
  6421.  
  6422. waitsecond(1)
  6423. end
  6424.  
  6425. tcase << TestAction.new(:TextView_Title_6) do
  6426. $ruiObj = RUIObject.new.with('objectid', -1984796814).with('selfid', -392058123).with('textdescid', -1929502754).with('uniqueparentid', 0).with('classresourceid', 490183159)
  6427. .with('uitreeindex', 0)
  6428. .with('classname', 'TextView')
  6429. .with('resource-id', 'android:id/title')
  6430. .with('text', 'Add WiFi')
  6431.  
  6432. $ruiObj.click
  6433.  
  6434. waitsecond(1)
  6435. end
  6436.  
  6437. tcase << TestAction.new(:EditText_Ssid_8) do
  6438. $ruiObj = RUIObject.new.with('objectid', 1745689399).with('selfid', 1359933717).with('textdescid', -1718203447).with('uniqueparentid', 0).with('classresourceid', -1413606463)
  6439. .with('uitreeindex', 2)
  6440. .with('classname', 'EditText')
  6441. .with('resource-id', 'com.lge.wifisettings:id/ssid')
  6442.  
  6443. $ruiObj.inputtext('qctcomp')
  6444.  
  6445. waitsecond(1)
  6446. end
  6447.  
  6448. tcase << TestAction.new(:Button_Button1_10) do
  6449. $ruiObj = RUIObject.new.with('objectid', -360890210).with('selfid', -210572094).with('textdescid', 1221395928).with('uniqueparentid', 0)
  6450. .with('uitreeindex', 7)
  6451. .with('classname', 'Button')
  6452. .with('resource-id', 'android:id/button1')
  6453. .with('text', 'CONNECT')
  6454.  
  6455. $ruiObj.click
  6456.  
  6457. waitsecond(1)
  6458. end
  6459.  
  6460. tcase << TestAction.new(:check_connection) do
  6461. $ruiObj = RUIObject.new.with('objectid', 1399891586).with('selfid', -404041766).with('textdescid', 623785653).with('uniqueparentid', 0).with('classresourceid', -1930775675)
  6462. .with('uitreeindex', 10)
  6463. .with('classname', 'TextView')
  6464. .with('resource-id', 'android:id/summary')
  6465. .with('text', 'Connected')
  6466.  
  6467. $ruiObj.click
  6468.  
  6469. waitsecond(1)
  6470. end
  6471.  
  6472. tcase << TestAction.new(:Button_Button3_15) do
  6473. $ruiObj = RUIObject.new.with('objectid', -360890208).with('selfid', 1759634711).with('textdescid', 452800563).with('uniqueparentid', 0)
  6474. .with('uitreeindex', 12)
  6475. .with('classname', 'Button')
  6476. .with('resource-id', 'android:id/button3')
  6477. .with('text', 'Forget')
  6478.  
  6479. $ruiObj.click
  6480.  
  6481. waitsecond(1)
  6482. end
  6483.  
  6484. tcase << TestAction.new(:TextView_Title_14) do
  6485. $ruiObj = RUIObject.new.with('objectid', -1789239232).with('selfid', -789618896).with('textdescid', 272817007).with('uniqueparentid', 0).with('classresourceid', 490183159)
  6486. .with('uitreeindex', 15)
  6487. .with('classname', 'TextView')
  6488. .with('resource-id', 'android:id/title')
  6489. .with('text', 'qctcomp')
  6490.  
  6491. $ruiObj.click
  6492.  
  6493. waitsecond(1)
  6494. end
  6495.  
  6496. tcase << TestAction.new(:EditText_Password_17) do
  6497. $ruiObj = RUIObject.new.with('objectid', -976316462).with('selfid', -2120332491).with('textdescid', -201039218).with('uniqueparentid', 0).with('classresourceid', -714852383)
  6498. .with('uitreeindex', 2)
  6499. .with('classname', 'EditText')
  6500. .with('resource-id', 'com.lge.wifisettings:id/password')
  6501.  
  6502. $ruiObj.inputtext('12abcdef34')
  6503.  
  6504. waitsecond(1)
  6505. end
  6506.  
  6507. tcase << TestAction.new(:pressBack_20) do
  6508. pressBack
  6509. end
  6510.  
  6511. tcase << TestAction.new(:Button_Button1_18) do
  6512. $ruiObj = RUIObject.new.with('objectid', -360890210).with('selfid', -210572094).with('textdescid', 1221395928).with('uniqueparentid', 0)
  6513. .with('uitreeindex', 6)
  6514. .with('classname', 'Button')
  6515. .with('resource-id', 'android:id/button1')
  6516. .with('text', 'CONNECT')
  6517.  
  6518. $ruiObj.click
  6519.  
  6520. waitsecond(4)
  6521. end
  6522.  
  6523. tcase << TestAction.new(:TextView_Summary_2) do
  6524. $ruiObj = RUIObject.new.with('objectid', 1704199271).with('selfid', -404041766).with('textdescid', -634935376).with('uniqueparentid', 0).with('classresourceid', -1930775675)
  6525. .with('uitreeindex', 7)
  6526. .with('classname', 'TextView')
  6527. .with('resource-id', 'android:id/summary')
  6528. .with('text', 'Connected')
  6529.  
  6530. $ruiObj.isExist
  6531.  
  6532. waitsecond(1)
  6533. end
  6534.  
  6535. tcase << TestAction.new(:scriptAction_23_TrueFalse) do
  6536. $myTestResult = checkLastExistResult
  6537.  
  6538. if $myTestResult == false
  6539. $myFailReason == "WiFi cannot connected"
  6540. end
  6541. logStopTest("05_01_10_02_WiFi")
  6542. end
  6543.  
  6544. tcase << TestAction.new(:Switch_OFF_19_1) do
  6545. $ruiObj = RUIObject.new.with('objectid', 1178284996).with('selfid', -533646533).with('textdescid', -1104515187).with('uniqueparentid', 0)
  6546. .with('uitreeindex', 2)
  6547. .with('classname', 'Switch')
  6548. .with('text', 'OFF')
  6549.  
  6550. $ruiObj.click
  6551.  
  6552. waitsecond(2)
  6553. end
  6554.  
  6555. tcase << TestAction.new(:pressBack_15) do
  6556. pressBack
  6557. end
  6558.  
  6559. tcase << TestAction.new(:pressBack_16) do
  6560. pressBack
  6561. end
  6562.  
  6563. tcase << TestAction.new(:pressHome_17) do
  6564. pressHome
  6565. end
  6566.  
  6567. tcase.run(loopTime)
  6568.  
  6569. end
  6570.  
  6571. def self.WiFi_Calling_05_01_16_01(loopTime)
  6572.  
  6573. tcase = TestCase.new("WiFi_Calling_05_01_16_01")
  6574.  
  6575. tcase << TestAction.new(:scriptAction_StartTest_1) do
  6576. logStartTest("05_01_16_01_WiFI_Calling")
  6577. end
  6578.  
  6579. tcase << TestAction.new(:pressHome_4) do
  6580. pressHome
  6581. end
  6582.  
  6583. tcase << TestAction.new(:TextView_Phone_2) do
  6584. $ruiObj = RUIObject.new.with('objectid', -479243074).with('selfid', 1134672426).with('textdescid', 1322329030).with('uniqueparentid', 0)
  6585. .with('uitreeindex', 9)
  6586. .with('classname', 'TextView')
  6587. .with('content-desc', 'Phone')
  6588. .with('text', 'Phone')
  6589.  
  6590. $ruiObj.click
  6591.  
  6592. waitsecond(1)
  6593. end
  6594.  
  6595. tcase << TestAction.new(:TextView_Tabtext_2) do
  6596. $ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 1015283306).with('textdescid', -1384079800).with('uniqueparentid', 0)
  6597. .with('uitreeindex', 4)
  6598. .with('classname', 'TextView')
  6599. .with('resource-id', 'com.android.contacts:id/tabText')
  6600. .with('text', 'Contacts')
  6601.  
  6602. $ruiObj.click
  6603.  
  6604. waitsecond(1)
  6605. end
  6606.  
  6607. tcase << TestAction.new(:EditText_SearchSrcText_4) do
  6608. $ruiObj = RUIObject.new.with('objectid', 588070375).with('selfid', -959326622).with('textdescid', -497243406).with('uniqueparentid', 0)
  6609. .with('uitreeindex', 6)
  6610. .with('classname', 'EditText')
  6611. .with('resource-id', 'android:id/search_src_text')
  6612. .with('content-desc', 'Search contacts')
  6613.  
  6614. $ruiObj.inputtext('A01')
  6615.  
  6616. waitsecond(1)
  6617. end
  6618.  
  6619. tcase << TestAction.new(:scriptAction_10_1) do
  6620. sendBTCmd('pressHome')
  6621. end
  6622.  
  6623. tcase << TestAction.new(:ImageView_Button1_8) do
  6624. $ruiObj = RUIObject.new.with('objectid', -1827607533).with('selfid', 643737864).with('textdescid', -306619761).with('uniqueparentid', 0).with('classresourceid', -1143292048)
  6625. .with('uitreeindex', 13)
  6626. .with('classname', 'ImageView')
  6627. .with('resource-id', 'android:id/button1')
  6628. .with('content-desc', 'Call A01 a01')
  6629.  
  6630. $ruiObj.click
  6631.  
  6632. waitsecond(4)
  6633. end
  6634.  
  6635. tcase << TestAction.new(:wait8second_31) do
  6636. waitsecond(8)
  6637. end
  6638.  
  6639. tcase << TestAction.new(:scriptAction_10) do
  6640. sendBTCmd('answerCall')
  6641.  
  6642. waitsecond(8)
  6643. end
  6644.  
  6645. tcase << TestAction.new(:scriptAction_10_1) do
  6646.  
  6647. if rand(100) < 0
  6648.  
  6649. sendBTCmd('endCall')
  6650.  
  6651. waitsecond(1)
  6652.  
  6653. end
  6654.  
  6655. end
  6656.  
  6657. tcase << TestAction.new(:scriptAction_LogStopTest_1_1) do
  6658. $myTestResult = checkLastBTCmdResult
  6659. if $myTestResult == false
  6660. $myFailReason = "Call not come to other dev"
  6661. end
  6662. logStopTest("05_01_16_01_WiFI_Calling")
  6663.  
  6664. end
  6665.  
  6666. tcase << TestAction.new(:Button_Endbutton_2) do
  6667. $ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
  6668. .with('uitreeindex', 8)
  6669. .with('classname', 'Button')
  6670. .with('resource-id', 'com.android.incallui:id/endButton')
  6671. .with('text', 'End')
  6672.  
  6673. $ruiObj.click
  6674.  
  6675. waitsecond(1)
  6676. end
  6677.  
  6678. tcase << TestAction.new(:pressBack_3) do
  6679. pressBack
  6680. end
  6681.  
  6682. tcase << TestAction.new(:pressBack_4) do
  6683. pressBack
  6684. end
  6685.  
  6686. tcase.run(loopTime)
  6687.  
  6688. end
  6689.  
  6690. def self.WiFi_Calling_05_01_16_02(loopTime)
  6691.  
  6692. tcase = TestCase.new("WiFi_Calling_05_01_16_02")
  6693.  
  6694. tcase << TestAction.new(:scriptAction_StartTest_1) do
  6695. logStartTest("05_01_16_02_WiFI_Calling")
  6696. end
  6697.  
  6698. tcase << TestAction.new(:pressHome_4) do
  6699. pressHome
  6700. end
  6701.  
  6702. tcase << TestAction.new(:TextView_Phone_2) do
  6703. $ruiObj = RUIObject.new.with('objectid', -479243074).with('selfid', 1134672426).with('textdescid', 1322329030).with('uniqueparentid', 0)
  6704. .with('uitreeindex', 9)
  6705. .with('classname', 'TextView')
  6706. .with('content-desc', 'Phone')
  6707. .with('text', 'Phone')
  6708.  
  6709. $ruiObj.click
  6710.  
  6711. waitsecond(1)
  6712. end
  6713.  
  6714. tcase << TestAction.new(:TextView_Tabtext_21) do
  6715. $ruiObj = RUIObject.new.with('objectid', 683038235).with('selfid', 566119687).with('textdescid', 1861262411).with('uniqueparentid', 0)
  6716. .with('uitreeindex', 2)
  6717. .with('classname', 'TextView')
  6718. .with('resource-id', 'com.android.contacts:id/tabText')
  6719. .with('text', 'Dial')
  6720.  
  6721. $ruiObj.click
  6722.  
  6723. waitsecond(2)
  6724. end
  6725.  
  6726. tcase << TestAction.new(:EditText_Digits_4) do
  6727. $ruiObj = RUIObject.new.with('objectid', 477485968).with('selfid', -1326421482).with('textdescid', 1917163152).with('uniqueparentid', 0)
  6728. .with('uitreeindex', 7)
  6729. .with('classname', 'EditText')
  6730. .with('resource-id', 'com.android.contacts:id/digits')
  6731.  
  6732. $ruiObj.inputtext('18003310500')
  6733.  
  6734. waitsecond(2)
  6735. end
  6736.  
  6737. tcase << TestAction.new(:ImageButton_Btnwificall_6) do
  6738. $ruiObj = RUIObject.new.with('objectid', -1011300904).with('selfid', 328499424).with('textdescid', -1103889439).with('uniqueparentid', 0)
  6739. .with('uitreeindex', 58)
  6740. .with('classname', 'ImageButton')
  6741. .with('resource-id', 'com.android.contacts:id/btnWifiCall')
  6742. .with('content-desc', 'Wifi call')
  6743.  
  6744. $ruiObj.click
  6745.  
  6746. waitsecond(2)
  6747. end
  6748.  
  6749. tcase << TestAction.new(:wait8second_31) do
  6750. waitsecond(8)
  6751. end
  6752.  
  6753. tcase << TestAction.new(:ImageButton_Endcallbutton_10) do
  6754. $ruiObj = RUIObject.new.with('objectid', 1089223879).with('selfid', -2049926087).with('textdescid', -593798087).with('uniqueparentid', 0)
  6755. .with('uitreeindex', 30)
  6756. .with('classname', 'ImageButton')
  6757. .with('resource-id', 'com.callapp.contacts:id/endCallButton')
  6758.  
  6759. $ruiObj.click
  6760.  
  6761. waitsecond(2)
  6762. end
  6763.  
  6764. tcase << TestAction.new(:scriptAction_LogStopTest_1_1) do
  6765. $myTestResult = checkLastBTCmdResult
  6766. if $myTestResult == false
  6767. $myFailReason = "Call not come to other dev"
  6768. end
  6769. logStopTest("05_01_16_01_WiFI_Calling")
  6770.  
  6771. end
  6772.  
  6773. tcase << TestAction.new(:pressBack_3) do
  6774. pressBack
  6775. end
  6776.  
  6777. tcase << TestAction.new(:pressBack_4) do
  6778. pressBack
  6779. end
  6780.  
  6781. tcase.run(loopTime)
  6782.  
  6783. end
  6784.  
  6785. def self.WiFi_Calling_05_01_16_03(loopTime)
  6786.  
  6787. tcase = TestCase.new("WiFi_Calling_05_01_16_03")
  6788.  
  6789. tcase << TestAction.new(:pressHome_2) do
  6790. pressHome
  6791. end
  6792.  
  6793. tcase << TestAction.new(:scriptAction_StartTestLog_1) do
  6794. logStartTest("05_01_16_03_WiFI_Calling")
  6795. end
  6796.  
  6797. tcase << TestAction.new(:scriptAction_BTMakeCall) do
  6798. sendBTCmd("makeCall('#{db('CallNumber')[0]}')")
  6799.  
  6800. waitsecond(8)
  6801. end
  6802.  
  6803. tcase << TestAction.new(:wait8second_12) do
  6804. waitsecond(8)
  6805. end
  6806.  
  6807. tcase << TestAction.new(:wait8second_14) do
  6808. waitsecond(8)
  6809. end
  6810.  
  6811. tcase << TestAction.new(:answerSwipe) do
  6812. $UIDev.swipe(288,1860,288,1400,10)
  6813.  
  6814.  
  6815. waitsecond(8)
  6816. end
  6817.  
  6818. tcase << TestAction.new(:Button_Endbutton_2) do
  6819. $ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
  6820. .with('uitreeindex', 10)
  6821. .with('classname', 'Button')
  6822. .with('resource-id', 'com.android.incallui:id/endButton')
  6823. .with('text', 'End')
  6824.  
  6825. $ruiObj.isNotExist
  6826. ifFailJumpTo(:Button_Endbutton_2_1)
  6827.  
  6828. waitsecond(1)
  6829. end
  6830.  
  6831. tcase << TestAction.new(:answerSwipe_1) do
  6832. $UIDev.swipe(288,1860,288,1400,10)
  6833.  
  6834.  
  6835. waitsecond(2)
  6836. end
  6837.  
  6838. tcase << TestAction.new(:Button_Endbutton_2_1) do
  6839. $ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
  6840. .with('uitreeindex', 10)
  6841. .with('classname', 'Button')
  6842. .with('resource-id', 'com.android.incallui:id/endButton')
  6843. .with('text', 'End')
  6844.  
  6845. $ruiObj.isExist
  6846.  
  6847. waitsecond(1)
  6848. end
  6849.  
  6850. tcase << TestAction.new(:scriptAction_LogStopTest_1) do
  6851. $myTestResult = checkLastExistResult
  6852. if $myTestResult == false
  6853. $myFailReason = "End button not found"
  6854. end
  6855. logStopTest("05_01_16_03_WiFI_Calling")
  6856.  
  6857. end
  6858.  
  6859. tcase << TestAction.new(:scriptAction_BTEndCall) do
  6860. sendBTCmd('endCall')
  6861. end
  6862.  
  6863. tcase << TestAction.new(:Button_Endbutton_2_1_1) do
  6864. $ruiObj = RUIObject.new.with('objectid', -1046212790).with('selfid', 1277076029).with('textdescid', -1112021541).with('uniqueparentid', 0)
  6865. .with('uitreeindex', 10)
  6866. .with('classname', 'Button')
  6867. .with('resource-id', 'com.android.incallui:id/endButton')
  6868. .with('text', 'End')
  6869.  
  6870. $ruiObj.click
  6871.  
  6872. waitsecond(1)
  6873. end
  6874.  
  6875. tcase << TestAction.new(:pressBack_1) do
  6876. pressBack
  6877. end
  6878.  
  6879. tcase << TestAction.new(:pressBack_2) do
  6880. pressBack
  6881. end
  6882.  
  6883. tcase.run(loopTime)
  6884.  
  6885. end
  6886.  
  6887. def self.WiFi_Calling_Disabled(loopTime)
  6888.  
  6889. tcase = TestCase.new("WiFi_Calling_Disabled")
  6890.  
  6891. tcase << TestAction.new(:pressHome_1) do
  6892. pressHome
  6893.  
  6894. waitsecond(2)
  6895. end
  6896.  
  6897. tcase << TestAction.new(:scriptAction_1) do
  6898. UiDevice.getInstance.openNotification()
  6899.  
  6900. waitsecond(2)
  6901. end
  6902.  
  6903. tcase << TestAction.new(:Switch_WiFi_3) do
  6904. $ruiObj = RUIObject.new.with('objectid', -1467580294).with('selfid', -34376116).with('textdescid', -624940890).with('uniqueparentid', 0)
  6905. .with('classname', 'Switch')
  6906. .with('content-desc', 'Wi-Fi Calling on.')
  6907. .with('text', 'Off')
  6908.  
  6909. $ruiObj.click
  6910.  
  6911. waitsecond(1)
  6912. end
  6913.  
  6914. tcase << TestAction.new(:Switch_Airplane_8) do
  6915. $ruiObj = RUIObject.new.with('objectid', -1467580294).with('selfid', -1117553413).with('textdescid', -521334761).with('uniqueparentid', 0)
  6916. .with('classname', 'Switch')
  6917. .with('content-desc', 'Airplane mode on.')
  6918. .with('text', 'Off')
  6919.  
  6920. $ruiObj.click
  6921.  
  6922. waitsecond(1)
  6923. end
  6924.  
  6925. tcase << TestAction.new(:Switch_qctcomp_11) do
  6926. $ruiObj = RUIObject.new.with('objectid', -1467580294).with('selfid', 1792588571).with('textdescid', -2004855945).with('uniqueparentid', 0)
  6927. .with('classname', 'Switch')
  6928. .with('text', 'Off')
  6929.  
  6930. $ruiObj.click
  6931.  
  6932. waitsecond(1)
  6933. end
  6934.  
  6935. tcase << TestAction.new(:pressHome_15) do
  6936. pressHome
  6937.  
  6938. waitsecond(2)
  6939. end
  6940.  
  6941. tcase.run(loopTime)
  6942.  
  6943. end
  6944.  
  6945. def self.WiFi_Calling_Enabled(loopTime)
  6946.  
  6947. tcase = TestCase.new("WiFi_Calling_Enabled")
  6948.  
  6949. tcase << TestAction.new(:pressHome_1) do
  6950. pressHome
  6951.  
  6952. waitsecond(2)
  6953. end
  6954.  
  6955. tcase << TestAction.new(:scriptAction_1) do
  6956. UiDevice.getInstance.openNotification()
  6957.  
  6958. waitsecond(2)
  6959. end
  6960.  
  6961. tcase << TestAction.new(:Switch_WiFi_2) do
  6962. $ruiObj = RUIObject.new.with('objectid', -1467580294).with('selfid', 1740384654).with('textdescid', -1815263324).with('uniqueparentid', 0)
  6963. .with('classname', 'Switch')
  6964. .with('content-desc', 'Wi-Fi Calling off.')
  6965. .with('text', 'On')
  6966.  
  6967. $ruiObj.click
  6968.  
  6969. waitsecond(2)
  6970. end
  6971.  
  6972. tcase << TestAction.new(:Button_Button1_3) do
  6973. $ruiObj = RUIObject.new.with('objectid', 467706165).with('selfid', -1318451484).with('textdescid', 195214425).with('uniqueparentid', 0)
  6974. .with('uitreeindex', 4)
  6975. .with('classname', 'Button')
  6976. .with('resource-id', 'android:id/button1')
  6977. .with('text', 'OK')
  6978.  
  6979. $ruiObj.click
  6980.  
  6981. waitsecond(2)
  6982. end
  6983.  
  6984. tcase << TestAction.new(:scriptAction_5) do
  6985. UiDevice.getInstance.openNotification()
  6986.  
  6987. waitsecond(2)
  6988. end
  6989.  
  6990. tcase << TestAction.new(:Switch_Airplane_7) do
  6991. $ruiObj = RUIObject.new.with('objectid', -1467580294).with('selfid', 657207357).with('textdescid', -1711657195).with('uniqueparentid', 0)
  6992. .with('classname', 'Switch')
  6993. .with('content-desc', 'Airplane mode off.')
  6994. .with('text', 'On')
  6995.  
  6996. $ruiObj.click
  6997.  
  6998. waitsecond(2)
  6999. end
  7000.  
  7001. tcase << TestAction.new(:Button_Button1_8) do
  7002. $ruiObj = RUIObject.new.with('objectid', -1349637992).with('selfid', -1318451484).with('textdescid', 1957157436).with('uniqueparentid', 0)
  7003. .with('uitreeindex', 3)
  7004. .with('classname', 'Button')
  7005. .with('resource-id', 'android:id/button1')
  7006. .with('text', 'OK')
  7007.  
  7008. $ruiObj.click
  7009.  
  7010. waitsecond(2)
  7011. end
  7012.  
  7013. tcase << TestAction.new(:scriptAction_9) do
  7014. UiDevice.getInstance.openNotification()
  7015.  
  7016. waitsecond(2)
  7017. end
  7018.  
  7019. tcase << TestAction.new(:Switch_WiFi_12) do
  7020. $ruiObj = RUIObject.new.with('objectid', -1467580294).with('selfid', 1570561034).with('textdescid', 1428965288).with('uniqueparentid', 0)
  7021. .with('classname', 'Switch')
  7022. .with('content-desc', 'Wi-Fi off.')
  7023. .with('text', 'On')
  7024.  
  7025. $ruiObj.click
  7026.  
  7027. waitsecond(2)
  7028. end
  7029.  
  7030. tcase << TestAction.new(:pressHome_13) do
  7031. pressHome
  7032.  
  7033. waitsecond(2)
  7034. end
  7035.  
  7036. tcase.run(loopTime)
  7037.  
  7038. end
  7039.  
  7040. def self.android_ExpHandler(loopTime)
  7041.  
  7042. tcase = TestCase.new("android_ExpHandler")
  7043.  
  7044. tcase << TestAction.new(:scriptAction_check) do
  7045. $err = "system popup detected::#{takeScreenShot}::screenshot saved"
  7046. $myTestResult = false
  7047. puts $err
  7048. logcat($err)
  7049. writelog($err)
  7050. uiObj("Button").click if uiObj("Button").exists
  7051.  
  7052. waitsecond(2)
  7053. end
  7054.  
  7055. tcase.run(loopTime)
  7056.  
  7057. end
  7058.  
  7059. def self.change_3G(loopTime)
  7060.  
  7061. tcase = TestCase.new("change_3G")
  7062.  
  7063. tcase << TestAction.new(:gotoApp_16) do
  7064. gotoApp('HiddenMenuCall')
  7065. end
  7066.  
  7067. tcase << TestAction.new(:TextView_Title_2) do
  7068. $ruiObj = RUIObject.new.with('objectid', 1100751325).with('selfid', -167282287).with('textdescid', -350417171).with('uniqueparentid', 0).with('classresourceid', 490183159)
  7069. .with('uitreeindex', 1)
  7070. .with('classname', 'TextView')
  7071. .with('resource-id', 'android:id/title')
  7072. .with('text', 'LG Hidden Menu')
  7073.  
  7074. $ruiObj.click
  7075.  
  7076. waitsecond(1)
  7077. end
  7078.  
  7079. tcase << TestAction.new(:TextView_Title_87) do
  7080. $ruiObj = RUIObject.new.with('objectid', 684902757).with('selfid', 538152793).with('textdescid', -1915478867).with('uniqueparentid', 0).with('classresourceid', 490183159)
  7081. .with('uitreeindex', 4)
  7082. .with('classname', 'TextView')
  7083. .with('resource-id', 'android:id/title')
  7084. .with('text', 'Field Test')
  7085.  
  7086. $ruiObj.click
  7087.  
  7088. waitsecond(1)
  7089. end
  7090.  
  7091. tcase << TestAction.new(:TextView_Text1_10) do
  7092. $ruiObj = RUIObject.new.with('objectid', -483333610).with('selfid', -141259386).with('textdescid', -734720867).with('uniqueparentid', 0).with('classresourceid', 490068035)
  7093. .with('uitreeindex', 1)
  7094. .with('classname', 'TextView')
  7095. .with('resource-id', 'android:id/text1')
  7096. .with('text', 'Modem Settings')
  7097.  
  7098. $ruiObj.click
  7099.  
  7100. waitsecond(1)
  7101. end
  7102.  
  7103. tcase << TestAction.new(:swipeDown_12) do
  7104. swipe_vertical 500
  7105.  
  7106. waitsecond(1)
  7107. end
  7108.  
  7109. tcase << TestAction.new(:TextView_Text1_14) do
  7110. $ruiObj = RUIObject.new.with('objectid', -483333610).with('selfid', 12767364).with('textdescid', 1760273017).with('uniqueparentid', 0).with('classresourceid', 490068035)
  7111. .with('uitreeindex', 6)
  7112. .with('classname', 'TextView')
  7113. .with('resource-id', 'android:id/text1')
  7114. .with('text', 'RAT Selection')
  7115.  
  7116. $ruiObj.click
  7117.  
  7118. waitsecond(1)
  7119. end
  7120.  
  7121. tcase << TestAction.new(:TextView_Text1_2) do
  7122. $ruiObj = RUIObject.new.with('objectid', -483333610).with('selfid', -244179464).with('textdescid', 496935915).with('uniqueparentid', 0).with('classresourceid', 490068035)
  7123. .with('uitreeindex', 5)
  7124. .with('classname', 'TextView')
  7125. .with('resource-id', 'android:id/text1')
  7126. .with('text', 'GSM WCDMA')
  7127.  
  7128. $ruiObj.click
  7129.  
  7130. waitsecond(1)
  7131. end
  7132.  
  7133. tcase << TestAction.new(:Button_Button1_18) do
  7134. $ruiObj = RUIObject.new.with('objectid', 2089308220).with('selfid', -1318451484).with('textdescid', 1664978912).with('uniqueparentid', 0)
  7135. .with('uitreeindex', 1)
  7136. .with('classname', 'Button')
  7137. .with('resource-id', 'android:id/button1')
  7138. .with('text', 'OK')
  7139.  
  7140. $ruiObj.click
  7141.  
  7142. waitsecond(1)
  7143. end
  7144.  
  7145. tcase << TestAction.new(:pressBack_7) do
  7146. pressBack
  7147. end
  7148.  
  7149. tcase << TestAction.new(:pressBack_8) do
  7150. pressBack
  7151. end
  7152.  
  7153. tcase << TestAction.new(:pressBack_20) do
  7154. pressBack
  7155. end
  7156.  
  7157. tcase << TestAction.new(:pressBack_20_1) do
  7158. pressBack
  7159. end
  7160.  
  7161. tcase << TestAction.new(:pressHome_9) do
  7162. pressHome
  7163. end
  7164.  
  7165. tcase.run(loopTime)
  7166.  
  7167. end
  7168.  
  7169. def self.change_LTE(loopTime)
  7170.  
  7171. tcase = TestCase.new("change_LTE")
  7172.  
  7173. tcase << TestAction.new(:gotoApp_16_1) do
  7174. gotoApp('HiddenMenuCall')
  7175. end
  7176.  
  7177. tcase << TestAction.new(:TextView_Title_3) do
  7178. $ruiObj = RUIObject.new.with('objectid', 1100751325).with('selfid', -167282287).with('textdescid', -350417171).with('uniqueparentid', 0).with('classresourceid', 490183159)
  7179. .with('uitreeindex', 1)
  7180. .with('classname', 'TextView')
  7181. .with('resource-id', 'android:id/title')
  7182. .with('text', 'LG Hidden Menu')
  7183.  
  7184. $ruiObj.click
  7185.  
  7186. waitsecond(1)
  7187. end
  7188.  
  7189. tcase << TestAction.new(:TextView_Title_87) do
  7190. $ruiObj = RUIObject.new.with('objectid', 684902757).with('selfid', 538152793).with('textdescid', -1915478867).with('uniqueparentid', 0).with('classresourceid', 490183159)
  7191. .with('uitreeindex', 4)
  7192. .with('classname', 'TextView')
  7193. .with('resource-id', 'android:id/title')
  7194. .with('text', 'Field Test')
  7195.  
  7196. $ruiObj.click
  7197.  
  7198. waitsecond(1)
  7199. end
  7200.  
  7201. tcase << TestAction.new(:TextView_Text1_10) do
  7202. $ruiObj = RUIObject.new.with('objectid', -483333610).with('selfid', -141259386).with('textdescid', -734720867).with('uniqueparentid', 0).with('classresourceid', 490068035)
  7203. .with('uitreeindex', 1)
  7204. .with('classname', 'TextView')
  7205. .with('resource-id', 'android:id/text1')
  7206. .with('text', 'Modem Settings')
  7207.  
  7208. $ruiObj.click
  7209.  
  7210. waitsecond(1)
  7211. end
  7212.  
  7213. tcase << TestAction.new(:swipeDown_12) do
  7214. swipe_vertical 500
  7215.  
  7216. waitsecond(1)
  7217. end
  7218.  
  7219. tcase << TestAction.new(:TextView_Text1_14) do
  7220. $ruiObj = RUIObject.new.with('objectid', -483333610).with('selfid', 12767364).with('textdescid', 1760273017).with('uniqueparentid', 0).with('classresourceid', 490068035)
  7221. .with('uitreeindex', 6)
  7222. .with('classname', 'TextView')
  7223. .with('resource-id', 'android:id/text1')
  7224. .with('text', 'RAT Selection')
  7225.  
  7226. $ruiObj.click
  7227.  
  7228. waitsecond(1)
  7229. end
  7230.  
  7231. tcase << TestAction.new(:TextView_Text1_2) do
  7232. $ruiObj = RUIObject.new.with('objectid', -483333610).with('selfid', 747569194).with('textdescid', -1653100487).with('uniqueparentid', 0).with('classresourceid', 490068035)
  7233. .with('uitreeindex', 1)
  7234. .with('classname', 'TextView')
  7235. .with('resource-id', 'android:id/text1')
  7236. .with('text', 'GSM WCDMA LTE auto')
  7237.  
  7238. $ruiObj.click
  7239.  
  7240. waitsecond(1)
  7241. end
  7242.  
  7243. tcase << TestAction.new(:Button_Button1_18) do
  7244. $ruiObj = RUIObject.new.with('objectid', 2089308220).with('selfid', -1318451484).with('textdescid', 1664978912).with('uniqueparentid', 0)
  7245. .with('uitreeindex', 1)
  7246. .with('classname', 'Button')
  7247. .with('resource-id', 'android:id/button1')
  7248. .with('text', 'OK')
  7249.  
  7250. $ruiObj.click
  7251.  
  7252. waitsecond(1)
  7253. end
  7254.  
  7255. tcase << TestAction.new(:pressBack_7) do
  7256. pressBack
  7257. end
  7258.  
  7259. tcase << TestAction.new(:pressBack_8) do
  7260. pressBack
  7261. end
  7262.  
  7263. tcase << TestAction.new(:pressBack_20) do
  7264. pressBack
  7265. end
  7266.  
  7267. tcase << TestAction.new(:pressBack_20_1) do
  7268. pressBack
  7269. end
  7270.  
  7271. tcase << TestAction.new(:pressHome_9) do
  7272. pressHome
  7273. end
  7274.  
  7275. tcase.run(loopTime)
  7276.  
  7277. end
  7278.  
  7279. def self.connectWifi(loopTime)
  7280.  
  7281. tcase = TestCase.new("connectWifi")
  7282.  
  7283. tcase << TestAction.new(:scriptAction_2) do
  7284. logStartTest("Connect_to_wifi")
  7285. end
  7286.  
  7287. tcase << TestAction.new(:scriptAction_4) do
  7288. gotoSettings
  7289.  
  7290. waitsecond(2)
  7291. end
  7292.  
  7293. tcase << TestAction.new(:TextView_Title_27) do
  7294. $ruiObj = RUIObject.new.with('objectid', 674368800).with('selfid', -2078686330).with('textdescid', -957350501).with('uniqueparentid', 0)
  7295. .with('uitreeindex', 3)
  7296. .with('classname', 'TextView')
  7297. .with('resource-id', 'android:id/title')
  7298. .with('text', 'Networks')
  7299.  
  7300. $ruiObj.click
  7301.  
  7302. waitsecond(1)
  7303. end
  7304.  
  7305. tcase << TestAction.new(:swipeUp_8) do
  7306. swipe_vertical_back 500
  7307. end
  7308.  
  7309. tcase << TestAction.new(:TextView_Title_4) do
  7310. $ruiObj = RUIObject.new.with('objectid', 2008023572).with('selfid', -589731018).with('textdescid', 498664031).with('uniqueparentid', 0).with('classresourceid', 490183159)
  7311. .with('uitreeindex', 9)
  7312. .with('classname', 'TextView')
  7313. .with('resource-id', 'android:id/title')
  7314. .with('text', 'WiFi')
  7315.  
  7316. $ruiObj.click
  7317.  
  7318. waitsecond(1)
  7319. end
  7320.  
  7321. tcase << TestAction.new(:Button_Button2_2) do
  7322. $ruiObj = RUIObject.new.with('objectid', -360890209).with('selfid', 1219598511).with('textdescid', -1570382871).with('uniqueparentid', 0)
  7323. .with('uitreeindex', 2)
  7324. .with('classname', 'Button')
  7325. .with('resource-id', 'android:id/button2')
  7326. .with('text', 'CLOSE')
  7327.  
  7328. $ruiObj.click
  7329.  
  7330. waitsecond(2)
  7331. end
  7332.  
  7333. tcase << TestAction.new(:scriptAction_6) do
  7334. switchOff = RUIObject.new.with('objectid', 1178284996).with('selfid', -533646533).with('textdescid', -1104515187).with('uniqueparentid', 0)
  7335. .with('uitreeindex', 2)
  7336. .with('classname', 'Switch')
  7337. .with('text', 'OFF')
  7338.  
  7339. if switchOff.isExist
  7340. switchOff.click
  7341. end
  7342.  
  7343. waitsecond(2)
  7344. end
  7345.  
  7346. tcase << TestAction.new(:ImageButton_More_8) do
  7347. $ruiObj = RUIObject.new.with('objectid', 1634319278).with('selfid', 1290820192).with('textdescid', 371464933).with('uniqueparentid', 0)
  7348. .with('uitreeindex', 3)
  7349. .with('classname', 'ImageButton')
  7350. .with('content-desc', 'More options')
  7351.  
  7352. $ruiObj.click
  7353.  
  7354. waitsecond(2)
  7355. end
  7356.  
  7357. tcase << TestAction.new(:TextView_Title_105) do
  7358. $ruiObj = RUIObject.new.with('objectid', -1984796814).with('selfid', -392058123).with('textdescid', -1929502754).with('uniqueparentid', 0).with('classresourceid', 490183159)
  7359. .with('uitreeindex', 0)
  7360. .with('classname', 'TextView')
  7361. .with('resource-id', 'android:id/title')
  7362. .with('text', 'Add WiFi')
  7363.  
  7364. $ruiObj.click
  7365.  
  7366. waitsecond(2)
  7367. end
  7368.  
  7369. tcase << TestAction.new(:EditText_Ssid_12) do
  7370. $ruiObj = RUIObject.new.with('objectid', 1745689399).with('selfid', 1359933717).with('textdescid', -1718203447).with('uniqueparentid', 0).with('classresourceid', -1413606463)
  7371. .with('uitreeindex', 2)
  7372. .with('classname', 'EditText')
  7373. .with('resource-id', 'com.lge.wifisettings:id/ssid')
  7374.  
  7375. $ruiObj.inputtext('qctcomp')
  7376.  
  7377. waitsecond(2)
  7378. end
  7379.  
  7380. tcase << TestAction.new(:TextView_Text1_14) do
  7381. $ruiObj = RUIObject.new.with('objectid', 189805031).with('selfid', -586759035).with('textdescid', 1468089423).with('uniqueparentid', 0).with('classresourceid', 490068035)
  7382. .with('uitreeindex', 4)
  7383. .with('classname', 'TextView')
  7384. .with('resource-id', 'android:id/text1')
  7385. .with('text', 'None')
  7386.  
  7387. $ruiObj.click
  7388.  
  7389. waitsecond(2)
  7390. end
  7391.  
  7392. tcase << TestAction.new(:CheckedTextView_Text1_16) do
  7393. $ruiObj = RUIObject.new.with('objectid', -540328984).with('selfid', 1449740166).with('textdescid', -877093410).with('uniqueparentid', 0).with('classresourceid', 2074814108)
  7394. .with('uitreeindex', 2)
  7395. .with('classname', 'CheckedTextView')
  7396. .with('resource-id', 'android:id/text1')
  7397. .with('text', 'WPAWPA2 PSK')
  7398.  
  7399. $ruiObj.click
  7400.  
  7401. waitsecond(2)
  7402. end
  7403.  
  7404. tcase << TestAction.new(:EditText_Password_12) do
  7405. $ruiObj = RUIObject.new.with('objectid', -976316462).with('selfid', -2120332491).with('textdescid', -201039218).with('uniqueparentid', 0).with('classresourceid', -714852383)
  7406. .with('uitreeindex', 2)
  7407. .with('classname', 'EditText')
  7408. .with('resource-id', 'com.lge.wifisettings:id/password')
  7409.  
  7410. $ruiObj.inputtext('12abcdef34')
  7411.  
  7412. waitsecond(1)
  7413. end
  7414.  
  7415. tcase << TestAction.new(:Button_Button1_2) do
  7416. $ruiObj = RUIObject.new.with('objectid', -1696842928).with('selfid', -210572094).with('textdescid', -1246235802).with('uniqueparentid', 0).with('classresourceid', 1834539358)
  7417. .with('uitreeindex', 10)
  7418. .with('classname', 'Button')
  7419. .with('resource-id', 'android:id/button1')
  7420. .with('text', 'CONNECT')
  7421.  
  7422. $ruiObj.click
  7423.  
  7424. waitsecond(4)
  7425. end
  7426.  
  7427. tcase << TestAction.new(:Button_Button2_18) do
  7428. $ruiObj = RUIObject.new.with('objectid', 435325163).with('selfid', 871101384).with('textdescid', 1989464844).with('uniqueparentid', 0)
  7429. .with('uitreeindex', 4)
  7430. .with('classname', 'Button')
  7431. .with('resource-id', 'android:id/button2')
  7432. .with('text', 'SKIP')
  7433.  
  7434. $ruiObj.click
  7435.  
  7436. waitsecond(2)
  7437. end
  7438.  
  7439. tcase << TestAction.new(:TextView_Summary_16) do
  7440. $ruiObj = RUIObject.new.with('objectid', 1399891586).with('selfid', -404041766).with('textdescid', 623785653).with('uniqueparentid', 0).with('classresourceid', -1930775675)
  7441. .with('uitreeindex', 10)
  7442. .with('classname', 'TextView')
  7443. .with('resource-id', 'android:id/summary')
  7444. .with('text', 'Connected')
  7445.  
  7446. $ruiObj.isExist
  7447. end
  7448.  
  7449. tcase << TestAction.new(:scriptAction_23_TrueFalse) do
  7450. $myTestResult = checkLastExistResult
  7451.  
  7452. if $myTestResult == false
  7453. $myFailReason == "WiFi cannot connected"
  7454. end
  7455. logStopTest("Connect_to_wifi")
  7456. end
  7457.  
  7458. tcase << TestAction.new(:pressBack_15) do
  7459. pressBack
  7460. end
  7461.  
  7462. tcase << TestAction.new(:pressBack_16) do
  7463. pressBack
  7464. end
  7465.  
  7466. tcase << TestAction.new(:pressHome_17) do
  7467. pressHome
  7468. end
  7469.  
  7470. tcase.run(loopTime)
  7471.  
  7472. end
  7473.  
  7474. def self.disconnectWifi(loopTime)
  7475.  
  7476. tcase = TestCase.new("disconnectWifi")
  7477.  
  7478. tcase << TestAction.new(:scriptAction_2) do
  7479. gotoSettings
  7480.  
  7481. waitsecond(2)
  7482. end
  7483.  
  7484. tcase << TestAction.new(:TextView_Title_3) do
  7485. $ruiObj = RUIObject.new.with('objectid', 10212784).with('selfid', -2078686330).with('textdescid', 1550078507).with('uniqueparentid', 0)
  7486. .with('uitreeindex', 5)
  7487. .with('classname', 'TextView')
  7488. .with('resource-id', 'android:id/title')
  7489. .with('text', 'Networks')
  7490.  
  7491. $ruiObj.click
  7492.  
  7493. waitsecond(2)
  7494. end
  7495.  
  7496. tcase << TestAction.new(:swipeUp_8_1) do
  7497. swipe_vertical_back 500
  7498. end
  7499.  
  7500. tcase << TestAction.new(:TextView_Title_7) do
  7501. $ruiObj = RUIObject.new.with('objectid', 67205646).with('selfid', -589731018).with('textdescid', 397088473).with('uniqueparentid', 0).with('classresourceid', 490183159)
  7502. .with('uitreeindex', 16)
  7503. .with('classname', 'TextView')
  7504. .with('resource-id', 'android:id/title')
  7505. .with('text', 'WiFi')
  7506.  
  7507. $ruiObj.click
  7508.  
  7509. waitsecond(2)
  7510. end
  7511.  
  7512. tcase << TestAction.new(:scriptAction_9) do
  7513. $ruiObj = RUIObject.new.with('objectid', 1178284996).with('selfid', 1645353587).with('textdescid', -1975291963).with('uniqueparentid', 0)
  7514. .with('uitreeindex', 2)
  7515. .with('classname', 'Switch')
  7516. .with('text', 'ON')
  7517.  
  7518. if $ruiObj.isExist
  7519. $ruiObj.click
  7520. end
  7521.  
  7522. waitsecond(2)
  7523. end
  7524.  
  7525. tcase << TestAction.new(:pressBack_2) do
  7526. pressBack
  7527.  
  7528. waitsecond(2)
  7529. end
  7530.  
  7531. tcase << TestAction.new(:pressBack_3) do
  7532. pressBack
  7533.  
  7534. waitsecond(2)
  7535. end
  7536.  
  7537. tcase << TestAction.new(:pressBack_4) do
  7538. pressBack
  7539.  
  7540. waitsecond(2)
  7541. end
  7542.  
  7543. tcase.run(loopTime)
  7544.  
  7545. end
  7546.  
  7547. def self.enhanced_LTE_service(loopTime)
  7548.  
  7549. tcase = TestCase.new("enhanced_LTE_service")
  7550.  
  7551. tcase << TestAction.new(:pressHome_1) do
  7552. pressHome
  7553.  
  7554. waitsecond(2)
  7555. end
  7556.  
  7557. tcase << TestAction.new(:gotoApp_5_1) do
  7558. gotoApp('Settings')
  7559.  
  7560. waitsecond(1)
  7561. end
  7562.  
  7563. tcase << TestAction.new(:TextView_Title_2) do
  7564. $ruiObj = RUIObject.new.with('objectid', 10212784).with('selfid', -2078686330).with('textdescid', 1550078507).with('uniqueparentid', 0)
  7565. .with('uitreeindex', 5)
  7566. .with('classname', 'TextView')
  7567. .with('resource-id', 'android:id/title')
  7568. .with('text', 'Networks')
  7569.  
  7570. $ruiObj.click
  7571.  
  7572. waitsecond(2)
  7573. end
  7574.  
  7575. tcase << TestAction.new(:swipeDown_3) do
  7576. swipe_vertical 500
  7577.  
  7578. waitsecond(2)
  7579. end
  7580.  
  7581. tcase << TestAction.new(:TextView_Title_5) do
  7582. $ruiObj = RUIObject.new.with('objectid', -2099539841).with('selfid', -590021802).with('textdescid', -1389148054).with('uniqueparentid', 0).with('classresourceid', 490183159)
  7583. .with('uitreeindex', 34)
  7584. .with('classname', 'TextView')
  7585. .with('resource-id', 'android:id/title')
  7586. .with('text', 'More')
  7587.  
  7588. $ruiObj.click
  7589.  
  7590. waitsecond(2)
  7591. end
  7592.  
  7593. tcase << TestAction.new(:Switch_SwitchWidget_7) do
  7594. $ruiObj = RUIObject.new.with('objectid', -1128160036).with('selfid', -1798770950).with('textdescid', -613222716).with('uniqueparentid', 0).with('classresourceid', -205276468)
  7595. .with('uitreeindex', 4)
  7596. .with('classname', 'Switch')
  7597. .with('resource-id', 'android:id/switch_widget')
  7598.  
  7599. $ruiObj.click
  7600.  
  7601. waitsecond(2)
  7602. end
  7603.  
  7604. tcase.run(loopTime)
  7605.  
  7606. end
  7607.  
  7608. def self.startTest(loopTime)
  7609.  
  7610. tcase = TestCase.new("startTest")
  7611.  
  7612. tcase << TestAction.new(:pressBack_1) do
  7613. pressBack
  7614. end
  7615.  
  7616. tcase << TestAction.new(:pressBack_2) do
  7617. pressBack
  7618. end
  7619.  
  7620. tcase << TestAction.new(:pressHome_3) do
  7621. pressHome
  7622. end
  7623.  
  7624. tcase.run(loopTime)
  7625.  
  7626. end
  7627.  
  7628. def self.mainLoop(loopTime)
  7629.  
  7630. WebSocketXServer.setAutoUpdate(false)
  7631.  
  7632. index = $mainResumeMainLoop
  7633. $mainResumeMainLoop = 0
  7634.  
  7635. writelog("mainLoop::#{index}::Resume") if index > 0
  7636.  
  7637. while index < loopTime
  7638.  
  7639. $curMainLoopNum = index
  7640.  
  7641. $saveLogToGist = false
  7642. $POWERLOG = true
  7643.  
  7644.  
  7645. if rand(100) < 0
  7646.  
  7647. for mode in db('ModemMode')
  7648. puts "Change to #{mode}"
  7649. if mode == 'LTE'
  7650. writelog("Telephony_05_01_01_01_LTE")
  7651. change_LTE 1
  7652. Telephony_05_01_01_01 60
  7653. elsif mode == '3G'
  7654. writelog("Telephony_05_01_01_01_3G")
  7655. change_3G 1
  7656. Telephony_05_01_01_01 20
  7657. end
  7658.  
  7659. end
  7660.  
  7661. end
  7662.  
  7663.  
  7664.  
  7665. if rand(100) < 0
  7666.  
  7667. for mode in db('ModemMode')
  7668. puts "Change to #{mode}"
  7669. if mode == 'LTE'
  7670. writelog("Telephony_05_01_01_03_LTE")
  7671. change_LTE 1
  7672. Telephony_05_01_01_03 60
  7673. elsif mode == '3G'
  7674. writelog("Telephony_05_01_01_03_3G")
  7675. change_3G 1
  7676. Telephony_05_01_01_03 20
  7677. end
  7678.  
  7679. end
  7680.  
  7681. end
  7682.  
  7683.  
  7684. $actionParamInput = "none"
  7685. Telephony_05_01_01_01 100
  7686.  
  7687. $actionParamInput = "none"
  7688. Telephony_05_01_01_03 100
  7689.  
  7690. $actionParamInput = "none"
  7691. Telephony_05_01_01_05 100
  7692.  
  7693. $actionParamInput = "none"
  7694. Telephony_05_01_01_07 20
  7695.  
  7696. $actionParamInput = "none"
  7697. Telephony_05_01_01_06 20
  7698.  
  7699.  
  7700. if rand(100) < 0
  7701.  
  7702. for mode in db('ModemMode')
  7703. puts "Change to #{mode}"
  7704. if mode == 'LTE'
  7705. writelog("Messaging_05_01_02_03_LTE")
  7706. change_LTE 1
  7707. Messaging_05_01_02_03 30
  7708. elsif mode == '3G'
  7709. writelog("Messaging_05_01_02_03_3G")
  7710. change_3G 1
  7711. Messaging_05_01_02_03 20
  7712. end
  7713.  
  7714. end
  7715.  
  7716. end
  7717.  
  7718.  
  7719.  
  7720. if rand(100) < 0
  7721.  
  7722. for mode in db('ModemMode')
  7723. puts "Change to #{mode}"
  7724. if mode == 'LTE'
  7725. writelog("Messaging_05_01_02_05_LTE")
  7726. change_LTE 1
  7727. Messaging_05_01_02_05 30
  7728. elsif mode == '3G'
  7729. writelog("Messaging_05_01_02_05_3G")
  7730. change_3G 1
  7731. Messaging_05_01_02_05 20
  7732. end
  7733.  
  7734. end
  7735.  
  7736. end
  7737.  
  7738.  
  7739. $actionParamInput = "none"
  7740. Messaging_05_01_02_03 50
  7741.  
  7742. $actionParamInput = "none"
  7743. Messaging_05_01_02_05 50
  7744.  
  7745. $actionParamInput = "none"
  7746. Messaging_05_01_02_06 50
  7747.  
  7748.  
  7749. if rand(100) < 0
  7750.  
  7751. for mode in db('ModemMode')
  7752. puts "Change to #{mode}"
  7753. if mode == 'LTE'
  7754. writelog("Gmail_05_01_03_01_LTE")
  7755. change_LTE 1
  7756. Gmail_05_01_03_01 30
  7757. elsif mode == '3G'
  7758. writelog("Gmail_05_01_03_01_3G")
  7759. change_3G 1
  7760. Gmail_05_01_03_01 20
  7761. end
  7762.  
  7763. end
  7764.  
  7765. end
  7766.  
  7767.  
  7768.  
  7769. if rand(100) < 0
  7770.  
  7771. for mode in db('ModemMode')
  7772. puts "Change to #{mode}"
  7773. if mode == 'LTE'
  7774. writelog("Gmail_05_01_03_02_LTE")
  7775. change_LTE 1
  7776. Gmail_05_01_03_02 30
  7777. elsif mode == '3G'
  7778. writelog("Gmail_05_01_03_02_3G")
  7779. change_3G 1
  7780. Gmail_05_01_03_02 20
  7781. end
  7782.  
  7783. end
  7784.  
  7785. end
  7786.  
  7787.  
  7788. $actionParamInput = "none"
  7789. Gmail_05_01_03_01 50
  7790.  
  7791. $actionParamInput = "none"
  7792. Gmail_05_01_03_02 50
  7793.  
  7794. $actionParamInput = "none"
  7795. Gmail_05_01_03_03 50
  7796.  
  7797.  
  7798. if rand(100) < 0
  7799.  
  7800. for mode in db('ModemMode')
  7801. puts "Change to #{mode}"
  7802. if mode == 'LTE'
  7803. writelog("Browser_05_01_04_01_LTE")
  7804. change_LTE 1
  7805. Browser_05_01_04_01 30
  7806. elsif mode == '3G'
  7807. writelog("Browser_05_01_04_01_3G")
  7808. change_3G 1
  7809. Browser_05_01_04_01 20
  7810. end
  7811.  
  7812. end
  7813.  
  7814. end
  7815.  
  7816.  
  7817.  
  7818. if rand(100) < 0
  7819.  
  7820. for mode in db('ModemMode')
  7821. puts "Change to #{mode}"
  7822. if mode == 'LTE'
  7823. writelog("Browser_05_01_04_02_LTE")
  7824. change_LTE 1
  7825. Browser_05_01_04_02 30
  7826. elsif mode == '3G'
  7827. writelog("Browser_05_01_04_02_3G")
  7828. change_3G 1
  7829. Browser_05_01_04_02 20
  7830. end
  7831.  
  7832. end
  7833.  
  7834. end
  7835.  
  7836.  
  7837.  
  7838. if rand(100) < 0
  7839.  
  7840. for mode in db('ModemMode')
  7841. puts "Change to #{mode}"
  7842. if mode == 'LTE'
  7843. writelog("Browser_05_01_04_03_LTE")
  7844. change_LTE 1
  7845. Browser_05_01_04_03 6
  7846. elsif mode == '3G'
  7847. writelog("Browser_05_01_04_03_3G")
  7848. change_3G 1
  7849. Browser_05_01_04_03 4
  7850. end
  7851.  
  7852. end
  7853.  
  7854. end
  7855.  
  7856.  
  7857. $actionParamInput = "none"
  7858. Browser_05_01_04_01 50
  7859.  
  7860. $actionParamInput = "none"
  7861. Browser_05_01_04_02 50
  7862.  
  7863. $actionParamInput = "none"
  7864. Browser_05_01_04_03 10
  7865.  
  7866. $actionParamInput = "none"
  7867. StoreFrontDownload_05_01_05_01 20
  7868.  
  7869. $actionParamInput = "none"
  7870. StoreFrontDownload_05_01_05_03 10
  7871.  
  7872. $actionParamInput = "none"
  7873. StoreFrontDownload_05_01_05_04 1
  7874.  
  7875. $actionParamInput = "none"
  7876. StoreFrontDownload_05_01_05_06 20
  7877.  
  7878. $actionParamInput = "none"
  7879. StoreFrontDownload_05_01_05_08 1
  7880.  
  7881. $actionParamInput = "none"
  7882. PIM_05_01_06_01 5
  7883.  
  7884. $actionParamInput = "none"
  7885. PIM_05_01_06_02 1
  7886.  
  7887. $actionParamInput = "none"
  7888. PIM_05_01_06_03 5
  7889.  
  7890. $actionParamInput = "none"
  7891. PIM_05_01_06_04 1
  7892.  
  7893. $actionParamInput = "none"
  7894. MultiMedia_05_01_07_01 1
  7895.  
  7896. $actionParamInput = "none"
  7897. MultiMedia_05_01_07_03 1
  7898.  
  7899. $actionParamInput = "none"
  7900. MultiMedia_05_01_07_04 20
  7901.  
  7902. $actionParamInput = "none"
  7903. MultiMedia_05_01_07_05 20
  7904.  
  7905. $actionParamInput = "none"
  7906. MultiMedia_05_01_07_06 20
  7907.  
  7908. $actionParamInput = "none"
  7909. MultiMedia_05_01_07_10 10
  7910.  
  7911. $actionParamInput = "none"
  7912. MultiTasking_05_01_08_01 1
  7913.  
  7914. $actionParamInput = "none"
  7915. MultiTasking_05_01_08_02 50
  7916.  
  7917. $actionParamInput = "none"
  7918. MultiTasking_05_01_08_03 1
  7919.  
  7920. $actionParamInput = "none"
  7921. MultiTasking_05_01_08_04 1
  7922.  
  7923. $actionParamInput = "none"
  7924. MultiTasking_05_01_08_05 50
  7925.  
  7926. $actionParamInput = "none"
  7927. MultiTasking_05_01_08_06 1
  7928.  
  7929. $actionParamInput = "none"
  7930. MenuNavigation_05_01_09_01 1
  7931.  
  7932. $actionParamInput = "none"
  7933. WiFi_05_01_10_01 20
  7934.  
  7935. $actionParamInput = "none"
  7936. WiFi_05_01_10_02 20
  7937.  
  7938. $actionParamInput = "none"
  7939. NFC_05_01_11_01 1
  7940.  
  7941.  
  7942. if rand(100) < 0
  7943.  
  7944. $actionParamInput = "none"
  7945. VideoCall_01 20
  7946.  
  7947. end
  7948.  
  7949.  
  7950. $actionParamInput = "none"
  7951. VideoTelephony_05_01_14_01 50
  7952.  
  7953. $actionParamInput = "none"
  7954. VideoTelephony_05_01_14_02 25
  7955.  
  7956. $actionParamInput = "none"
  7957. VideoTelephony_05_01_14_03 25
  7958.  
  7959. $actionParamInput = "none"
  7960. connectWifi 1
  7961.  
  7962. $actionParamInput = "none"
  7963. VideoTelephony_05_01_14_04 25
  7964.  
  7965. $actionParamInput = "none"
  7966. VideoTelephony_05_01_14_05 25
  7967.  
  7968. $actionParamInput = "none"
  7969. disconnectWifi 1
  7970.  
  7971.  
  7972. if rand(100) < 0
  7973.  
  7974.  
  7975.  
  7976. waitsecond(2)
  7977.  
  7978. end
  7979.  
  7980.  
  7981.  
  7982. sendStatus("Done::mainLoop::Loop::#{index}")
  7983.  
  7984.  
  7985. writelog("Finish::Loop::#{$curMainLoopNum}")
  7986.  
  7987.  
  7988. saveLogFileToGist if $saveLogToGist
  7989.  
  7990. index += 1
  7991.  
  7992. end
  7993.  
  7994. $engineStatus = "Idle"
  7995. resetStatus
  7996. sendStatus("Finish::mainLoop::END")
  7997.  
  7998. end
  7999.  
  8000. def self.exception_handler
  8001. puts "Module Exception Hanlder..."
  8002. if ($lastPackageName == "android")
  8003. android_ExpHandler(1)
  8004. end
  8005. end
  8006.  
  8007. def self.run(loop)
  8008. mainLoop loop
  8009. end
  8010.  
  8011. end
  8012.  
  8013. $exceptionPackageNameList = []
  8014. $exceptionPackageNameList_exclude = []
  8015. $exceptionPackageNameList << "android"
  8016.  
  8017. def exception_handler
  8018. JOAN_MTBF.exception_handler
  8019. end
  8020.  
  8021. $curProjectLogFile = $useLastLogFile
  8022.  
  8023. $curProjectLogFile = "JOAN_MTBF_#{getTimeStamp}.log" if $useLastLogFile.nil?
  8024.  
  8025. $useLastLogFile = nil
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement