关闭

PHPUnit袖珍指南-概述

4969人阅读 评论(2) 收藏 举报

概述

聪明的Web开发人员会告诉你,越快找到代码的错误,你就能越快修正它,长期而言,项目成本越低。好了,能最有效的检测PHP代码中的错误的工具是PHPUnit,一个开发源代码的框架,它在你不在的时候,自动进行成套的单元测试。使用PHPUnit的好处是显而易见的:

l         减少用于测试代码的工作量

l         减少总体软件缺陷

l         增加对代码的信心

l         改善你和开发源代码的团队伙伴的关系

直到现在,这个流行工具唯一的问题是缺乏文档。为了解决这个问题,O’Reilly直接找到了源头,PHPUnit口袋书指南的作者,也是PHPUnit的创造者,Sebastian Bergmann,来解决这个问题。这本书把很多难以记忆的信息,语法,PHPUnit工作的原则,统一到一起。它也带来了只有技术创造者才能提供的洞察力和睿智忠告。而且,本书也谈到了敏捷方法和极限编程中关于测试的内容。

O’Reilly口袋书指南最近的系列中,这本快速参考书把所有的答案都带到了你的指尖。那些对测试PHP代码感兴趣的Web应用程序开发者,会觉得本书是一个无价的伴侣。

 

--------------------------------------------------------------------------------------------------------------

原文:

Overview

Smart web developers will tell you that the sooner you detect your code mistakes, the quicker you can fix them, and the less the project will cost in the long run. Well, the most efficient way to detect your mistakes in PHP is with PHPUnit, an open source framework that automates unit testing by running a battery of tests as you go. The benefits of PHPUnit are significant:

 

a reduction in the effort required to frequently test code

fewer overall defects

added confidence in your code

improved relations with your open source teammates

 

 

 

The only problem with this popular testing tool was its lack of documentation-until now, that is. For this, O'Reilly went right to the source, as Sebastian Bergmann, the author of PHPUnit Pocket Guide, also happens to be PHPUnit's creator. This little book brings together hard-to-remember information, syntax, and rules for working with PHPUnit. It also delivers the insight and sage advice that can only come from the technology's creator. Coverage of testing under agile methodologies and Extreme Programming (XP) is also included.

 

The latest in O'Reilly's series of handy Pocket Guides, this quick-reference book puts all the answers are right at your fingertips. It's an invaluable companion for anyone interested in testing the PHP code they write for web applications.

0
0

查看评论
* 以上用户言论只代表其个人观点,不代表CSDN网站的观点或立场
    个人资料
    • 访问:185466次
    • 积分:2107
    • 等级:
    • 排名:第18726名
    • 原创:13篇
    • 转载:5篇
    • 译文:13篇
    • 评论:41条
    最新评论