Building Test---Chapter 4

王朝other·作者佚名  2006-01-09
窄屏简体版  字體: |||超大  

Point1:

Make sure all tests are fully automatic and that they check their own result!

Point2:

A suite of tests is a powerful bug detector that decapites the time it takes to find bugs.

Point3:

Run your tests frequently. Localize tests whenever you compile---every test at least every day.

Point4:

When you get a bug report ,start by writing a unit test that exposes the bug.

Point5:

The key to testing is to test the areas that you are most worried about going wrong.,a key tricki with tests is to look for boundary conditions.

Point6:

It is better to write and run incomplete tests than not to run complete tests.

Point7:

Don't forget to test that exceptions are raised when things are expected to go wrong.

作者在这里提到了两种测试的不同unit tests and functional tests

unit test is a kind of test that is used to improve the productivity of programmers,it is highly localized,each works within a single package.

while functional tests are used to ensure the software as a whole works,they are often done by another group of people.

从昨天开始我接触到了JUnit,以前这个东西对我来说是完全未知的,但是由于种种原因没有去仔细研究,昨天忽然发现JUnit是由Kent Beck和Erich Gamma(<<设计模式>>作者)开发的(现在是开源项目),我不得不说:物以类聚了!JUnit

 
 
 
免责声明:本文为网络用户发布,其观点仅代表作者个人观点,与本站无关,本站仅提供信息存储服务。文中陈述内容未经本站证实,其真实性、完整性、及时性本站不作任何保证或承诺,请读者仅作参考,并请自行核实相关内容。
 
 
© 2005- 王朝網路 版權所有 導航