該文物用於論文:“通過構建活動啟動上下文對Android應用程序進行多項訪問測試”。

傳真是用於測試Android應用程序的多項訪問測試工具,該工具構建了為應用程序啟動上下文的活動,並提出了一個多入門的測試框架。
可以在https://hanada31.github.io/pdf/icse20_fax.pdf上找到該論文PDF
@InProceedings{jiwei:icse:2020,
author = {Jiwei Yan and Hao Liu and Linjie Pan and Jun Yan and Jian Zhang and Bin Liang},
title = {Multiple-Entry Testing of Android Applications by Constructing Activity Launching Contexts},
booktitle = {Proceedings of the 42nd International Conference on Software Engineering},
series = {ICSE '20},
year = {2020},
pages={457-468}}
安裝Java 1.8
安裝ANT 1.9.16
安裝Python 2.7
傳真需要Z3動態鏈接庫以及Z3/Java API的動態鏈接庫。
準備Android環境(Android SDK安裝信息,https://developer.android.com/),Android SDK工具的版本應低於25.2.3。
運行“ java -version”,“ python”,“ ant -version”,“ android create project”,以檢查這些工具是否已成功配置。
準備Android設備或模擬器,並將其連接到計算機。打開設置項目“開發人員模式”,並允許“ USB調試”。
克隆項目到您的計算機。
為了快速啟動,您可以運行:runfax.sh或runfax.bat
*要修改FAX_EX的探索時間,請更新文件faxtool script run.py中的變量exploration_time。
在我們的論文中,探索時間為一個小時(3600)。如果需要快速驗證,請在傳真(60)中使用默認值。
預處理將APK放在[apk_input_dir]下進行測試,並在[apk_output_dir]中獲取結果。
python腳本/prerocess.py [apk_input_dir] [apk_output_dir]
例如,python腳本/prerocess.py apk apk_processed
然後將暴露活動,將儀器進行儀器,然後安裝在設備上。
對於登錄所需的應用程序,您可以在安裝後首先登錄以改善勘探覆蓋範圍。
測試生成python腳本/generateTestCases.py lib/fax0108.jar [apk_input_dir] [testcase_dir] [execute_info_dir] [max_number_of_path]
例如,python腳本/generateTestcases.py lib/fax0108.jar apk result_testgen executeinfo 10000
在文件夾[testcase_dir]中獲取結果。
傳真啟動測試python腳本/launchActs.py [testcase_dir] [auginn_dir]
例如,python腳本/launchActs.py result_testgen result_launch
獲取結果文件夾[lashe_dir]。
檢測傳真啟動python腳本/findcrashes.py [testcase_dir] [aunplion_dir]的崩潰
例如,python腳本/findcrashes.py result_testgen result_launch
傳真探索測試Python腳本/fairandroidexploer.py [lunage_dir] [explore_dir] [testcase_dir] [apk_output_dir] [ea/all]
設置EA,如果您只想將EA設置為勘探條目。
如果要將所有活動設置為探索條目,請全部設置。
例如,python腳本/fairandroidexploer.py result_launch result_explore result_testgen apk_processed
在文件夾[Explore_dir]中獲取結果。
檢測傳真勘探python腳本/findcrashes.py [testcase_dir] [Explore_dir]的崩潰
例如,python腳本/findcrashes.py result_testgen result_explore
計算覆蓋範圍結果python腳本/collectlogcat.py [testcase_dir] [Explore_dir] [apk_output_dir]
例如,python腳本/collectlogcat.py result_testgen result_explore apk_processed