(3.235.137.159) 您好!臺灣時間:2020/09/29 08:31
字體大小: 字級放大   字級縮小   預設字形  
回查詢結果

詳目顯示:::

我願授權國圖
本論文永久網址: 
line
研究生:簡穎超
研究生(外文):Ying-Chao Chien
論文名稱:動態延遲載入的測試覆蓋率
論文名稱(外文):Test Coverage on Dynamic Lazy Loading JavaScript
指導教授:鄭永斌鄭永斌引用關係
指導教授(外文):Yung-Pin Cheng
學位類別:碩士
校院名稱:國立中央大學
系所名稱:資訊工程學系
學門:工程學門
學類:電資工程學類
論文種類:學術論文
論文出版年:2014
畢業學年度:102
語文別:中文
論文頁數:54
中文關鍵詞:程式碼覆蓋測試覆蓋WebWeb應用程式JavaScript動態延遲載入
外文關鍵詞:Code coverageTest coverageWebWeb applicationJavaScriptDynamic lazy loading
相關次數:
  • 被引用被引用:0
  • 點閱點閱:137
  • 評分評分:系統版面圖檔系統版面圖檔系統版面圖檔系統版面圖檔系統版面圖檔
  • 下載下載:19
  • 收藏至我的研究室書目清單書目收藏:0
測試覆蓋(Test Coverage)的技術與工具至今已經有相當成熟的發展,尤其在大型的軟體系統開發中,為了能夠維持軟體的品質並降低程式臭蟲的數量,一般會導入軟體測試來驗證程式的正確性。在軟體測試時期,開發團隊可以利用測試覆蓋工具產生測試覆蓋報告,來輔助開發者了解專案的測試案例是否有涵蓋到軟體的重要功能,或是測試案例是否足夠完整。
而近年來由於Web技術逐漸成熟,以往在桌面應用程式或行動端應用程式才能夠達成的功能現在均能夠透過Web 技術達成。隨著網際網路的發展以及各大瀏覽器公司Google、Mozilla、Opera、Apple、Microsoft等對於Web的推動,促使Web應用近年來開始大幅的成長,開發者們也紛紛開始提倡Web 應用程式的模組化與重視軟體測試。Web應用程式上的測試覆蓋工具也因為開發需求而陸續問世,但是Web 應用程式與一般桌面應用程式因動態延遲載入技術上的差異,使得在Web應用程式(Web application)上的測試覆蓋所碰到的問題不同於以往。
本論文將會探討JavaScript在動態延遲載入技術上的各種實踐方式,分析它們套用在測試覆蓋技術上時會發生的問題,提出方法並加以改進。

Test coverage techniques and tools have been quite mature nowadays. In order to maintain software quality and reduce the number of software defects during developing large-scale system, developers must introduce software testing into development process to validate the correctness of programs. In software testing, test coverage is an important technique to evaluate the quality of test cases.
In recent years, due to the maturity of web technology, web applications are gradually capable of completing the tasks that could only be done by desktop programs or mobile apps. With the vigorously promotion from international browser companies such as Google, Mozilla, Opera, Apple and Microsoft…etc, developers worldwide have begun to advocate the modularity and put an emphasis on software testing of web applications. Test coverage tools on web applications have come out to meet such a need. However, there are differences between web applications and general desktop applications, particularly on dynamic lazy loading. As a result, test coverage tools suffer from new challenges and difficulties while applied to the new web programming paradigm.
This thesis researches all kinds of dynamic lazy loading approaches in JavaScript and analyzes the impact to the test coverage tool implementation. Finally, an approach is proposed to address the problem.

目錄
第一章、 緒論 1
1-1 研究動機 1
1-2 問題描述 4
第二章、 研究背景 7
2-1 程式碼覆蓋工具的instrumentation技術 7
2-2 Source Instrumentation 8
2-3 JavaScript的程式碼覆蓋工具 8
2-4 Web技術 10
2-5 Web應用程式的測試環境 11
2-6 Web應用程式的測試覆蓋架構 13
2-6-1 客戶端環境執行instrumentation 15
2-6-2 伺服器端環境執行instrumentation 17
2-6-3 Instrumentation方式的分析比較 19
2-6-4 總結 20
第三章、 分析與解決零覆蓋率問題 21
3-1 Web動態延遲載入技術分析 21
3-1-1 XMLHttpRequest (XHR) 21
3-1-2 Document.write 22
3-1-3 DOM modification API 22
3-1-4 Function Wrapping 23
3-1-5 總結 23
3-2 零覆蓋率問題之解決方式 24
3-2-1 Override原生Web API 24
3-2-2 Blanket.js的source instrumentation執行流程 25
3-2-3 Override原生XHR 25
3-2-4 Override原生DOM modification API 26
3-2-5 總結 27
第四章、 研究成果評估 29
4-1 評估案例選擇 29
4-2 評估案例一 簡易測試網頁 30
4-3 評估案例二 真實Web應用程式 32
4-3-1 評估案例一 - Firefox OS Email App 32
4-3-2 評估案例二 - Firefox OS Search App 34
4-3-3 評估案例三 - Firefox OS Communications App 37
4-4 瀏覽器支援 41
第五章、 結論與討論 42
參考文獻 44
[1] M. R. Lyu, "Design, testing, and evaluation techniques for software reliability engineering," in Euromicro Conference, 1998. Proceedings. 24th, 1998, pp. XXXIX-XXLVI vol.2.
[2] J. R. Horgan, S. London, and M. R. Lyu, "Achieving software quality with testing coverage measures," Computer, vol. 27, pp. 60-69, 1994.
[3] B. Gibson, "Enabling an accessible web 2.0," presented at the Proceedings of the 2007 international cross-disciplinary conference on Web accessibility (W4A), Banff, Canada, 2007.
[4] S. Stefanov, JavaScript Patterns O'Reilly Media, 2010.
[5] J. Burke. (2014). Why Web Modules. Available: http://requirejs.org/docs/why.html
[6] R. Sanjaya, "Web traffic reduction for infrequent update application using Green Ajax," in Information Management and Engineering (ICIME), 2010 The 2nd IEEE International Conference on, 2010, pp. 170-176.
[7] M. M. Tikir and J. K. Hollingsworth, "Efficient instrumentation for code coverage testing," presented at the Proceedings of the 2002 ACM SIGSOFT international symposium on Software testing and analysis, Roma, Italy, 2002.
[8] A. Seville. (2014). Blanket.js | Seamless javascript code coverage. Available: http://blanketjs.org/
[9] R. Lingampally, A. Gupta, and P. Jalote, "A Multipurpose Code Coverage Tool for Java," in System Sciences, 2007. HICSS 2007. 40th Annual Hawaii International Conference on, 2007, pp. 261b-261b.
[10] M. R. Lyu, J. R. Horgan, and S. London, "A coverage analysis tool for the effectiveness of software testing," in Software Reliability Engineering, 1993. Proceedings., Fourth International Symposium on, 1993, pp. 25-34.
[11] J. R. Horgan and S. London, "A data flow coverage testing tool for C," in Assessment of Quality Software Development Tools, 1992., Proceedings of the Second Symposium on, 1992, pp. 2-10.
[12] C. Pavlopoulou and M. Young, "Residual test coverage monitoring," in Software Engineering, 1999. Proceedings of the 1999 International Conference on, 1999, pp. 277-284.
[13] W. Binder, J. Hulaas, and P. Moret, "Advanced Java bytecode instrumentation," presented at the Proceedings of the 5th international symposium on Principles and practice of programming in Java, Lisboa, Portugal, 2007.
[14] P. Moret, W. Binder, \#201, and r. Tanter, "Polymorphic bytecode instrumentation," presented at the Proceedings of the tenth international conference on Aspect-oriented software development, Porto de Galinhas, Brazil, 2011.
[15] S. Tilkov and S. Vinoski, "Node.js: Using JavaScript to Build High-Performance Network Programs," Internet Computing, IEEE, vol. 14, pp. 80-83, 2010.
[16] A. Holmes and M. Kellogg, "Automating functional tests using Selenium," in Agile Conference, 2006, 2006, pp. 6 pp.-275.
[17] A. Mesbah and M. R. Prasad, "Automated cross-browser compatibility testing," presented at the Proceedings of the 33rd International Conference on Software Engineering, Waikiki, Honolulu, HI, USA, 2011.
[18] A. Miller, "A Hundred Days of Continuous Integration," in Agile, 2008. AGILE '08. Conference, 2008, pp. 289-293.
[19] JSCover - JavaScript code coverage. Available: http://tntim96.github.io/JSCover/
[20] Mozilla. (2014). XMLHttpRequest. Available: http://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest
[21] Z. Sun, X. Zhang, and L. Zhao, "The Web asynchronous communication mechanism research based on Ajax," in Education Technology and Computer (ICETC), 2010 2nd International Conference on, 2010, pp. V3-370-V3-372.
[22] Mozilla. (2014). document.write. Available: http://developer.mozilla.org/en-US/docs/Web/API/document.write
[23] Mozilla. (2014). Node.appendChild. Available: http://developer.mozilla.org/zh-TW/docs/Web/API/Node.appendChild
[24] Mozilla. (2014). Node.insertBefore. Available: http://developer.mozilla.org/en-US/docs/Web/API/Node.insertBefore
[25] Mozilla. (2014). Node.replaceChild. Available: http://developer.mozilla.org/en-US/docs/Web/API/Node.replaceChild
[26] M. Rask, "Moduler JavaScript: A Comparsion of Module Loaders," 2012.
[27] J. Burke. (2014). Why AMD. Available: http://requirejs.org/docs/whyamd.html
連結至畢業學校之論文網頁點我開啟連結
註: 此連結為研究生畢業學校所提供,不一定有電子全文可供下載,若連結有誤,請點選上方之〝勘誤回報〞功能,我們會盡快修正,謝謝!
QRCODE
 
 
 
 
 
                                                                                                                                                                                                                                                                                                                                                                                                               
第一頁 上一頁 下一頁 最後一頁 top
系統版面圖檔 系統版面圖檔