現有的Android測試工具大部分是利用撰寫程式碼的方式來製作測試腳本(Test Script),必須花費大量時間學習並撰寫測試碼,若使用錄影播放功能來編輯腳本則必須先實作程式功能才能夠進行腳本的錄製,不符合先行測試的概念,且遇到圖形介面更動的情形時,舊的腳本可能需要花很多成本來維護。本論文提出一套支援元件抽象化(Component Abstraction)的Android GUI測試工具。測試人員在PC端建立待測程式的巨集結構(Macro Structure)並編輯腳本,即可將腳本傳至Android裝置上進行自動化測試。測試人員可以藉由巨集結構重複利用已經撰寫過的腳本,減少編輯類似腳本所需花費的時間,或維護腳本時所需付出的成本。本論文以實際的Android App檢驗所提出的工具是否可實際提升Android GUI測試腳本的可讀性及可維護性。
Most current Android testing tools use source code to construct test scripts, which requires a great deal of learning and construction time. If the record/playback technique is used to create test scripts, program functionalities need to be implemented first in order to record the script. This contradicts the concept of test-driven development. Plus, if the GUI is modified, the test script may need considerable amount of effort to maintain. This thesis proposes an Android testing tool that supports component abstraction. Testers only need to construct the macro structure of the application under test from the PC-end and edit the script, which can then be transferred onto an Android device for automatic testing. Testers can reuse the scripts already written through the macro structure, which reduces the time and cost to maintain the scripts. In addition, this thesis examines whether the proposed tool really increases the readability and maintainability of Android GUI test scripts using a real Android App.