Quality Code: Software Testing Principles, Practices, and Patterns (Paperback)

Stephen Vance

買這商品的人也買了...

商品描述

 

Test-driven, test-first, and test-early development practices are helping thousands of software development organizations improve their software. Now, in Quality Code: Software Testing Principles, Practices, and Patterns, Stephen Vance builds on all that’s been learned about test-driven development, helping you achieve unprecedented levels of first-time quality. Using real-world code examples, this guide introduces patterns, principles, and more than two dozen detailed techniques for testing any software system more fully, effectively, and painlessly. Vance presents a conceptual framework to help you focus your efforts and design recommendations for improving testability across the software lifecycle, and also provides hands-on guidance to simplify testing of the full spectrum of code constructs. You’ll learn how to choose the best testing techniques for every situation, from the most common scenarios to threading. Two complete case studies put it all together, walking you through testing a brand-new Java application and an untested “legacy” JavaScript jQuery plugin. Whether you’re developing cutting-edge code for a new start-up, or maintaining an unruly old system, this guide will help you deliver exactly what you need: quality code.

 

 

• Simplify unit testing of all your code—and improve integration and system testing

• Delineate intent and implementation to promote more reliable and scalable testing

• Overcome confusion and misunderstandings about the mechanics of writing tests

• Test “side effects,” behavioral characteristics, and contextual constraints

• Understand subtle interactions between design and testability—and make them work for, not against, you

• Discover core principles that guide your key testing decisions

• Explore testing getters/setters, string handling, encapsulation, override variations, visibility, singleton patterns, error conditions, and more

• Reproduce and test complex race conditions deterministically

 

商品描述(中文翻譯)

測試驅動、先測試、早期測試的開發實踐正幫助數千個軟體開發組織提升其軟體品質。現在,在《品質代碼:軟體測試原則、實踐和模式》一書中,Stephen Vance基於測試驅動開發的所有經驗,幫助您實現前所未有的首次品質水平。本指南使用真實的程式碼範例,介紹了模式、原則和超過二十多種詳細的測試技術,以更全面、有效和無痛的方式測試任何軟體系統。Vance提出了一個概念框架,幫助您集中精力並提供改善軟體生命週期中測試性的設計建議,並提供實用指導,以簡化對各種程式碼結構的測試。您將學習如何選擇最佳的測試技術,從最常見的情境到多線程。兩個完整的案例研究將所有內容結合在一起,引導您進行全新Java應用程式和未經測試的「遺留」JavaScript jQuery插件的測試。無論您是為新創公司開發尖端程式碼,還是維護一個難以管理的舊系統,本指南都將幫助您交付您所需的優質代碼。

- 簡化所有程式碼的單元測試,並改善整合和系統測試
- 區分意圖和實現,以促進更可靠和可擴展的測試
- 克服有關撰寫測試的機制的困惑和誤解
- 測試「副作用」、行為特性和上下文限制
- 理解設計和可測試性之間微妙的互動,並使其為您所用,而不是反對您
- 探索指導您關鍵測試決策的核心原則
- 探索測試getter/setter、字串處理、封裝、覆寫變化、可見性、單例模式、錯誤條件等
- 可以確定性地重現和測試複雜的競爭條件