- TDD - Test Driven Development
- Write unit tests before or as soon as you write a new class or add methods
- Design for easy testing, limit and break dependencies
- Make sure all your test past before moving on to develop more code
- Use a testing framework like JUnit.
- Use mock objects. A mock object framework like jMock or EasyMock will help.
- Refactoring
- Use an IDE which supports refactoring, such as Eclipse.
- Read Martin Fowler's book and blog.
- Refactor frequently, don't be afraid of refactoring. If you have good set of unit tests they will quickly pickup any mistakes that might be introduced by refactoring.
- Break Dependencies
- By breaking dependencies using a technique like dependency injection, you can make writing Unit tests easier and make refactoring safer.
- During testing, inject by hand, during production use a framework such as Spring or Guice.
Sunday, December 16, 2007
Agile Development
I've been using Agile techniques for years and trying to get others to use them as well. I've read books on Agile techniques, read blogs, and written code. For people interested in exploring these techiques, I would suggest the following techniques to try out:
Labels:
Dependency Injection,
EasyMock,
Eclipse,
Guice,
jMock,
JUnit,
Spring,
Test Driven Development
What is this blog about
In my role as an internal Java Framework developer for a corporation developing web applications, I realized that many developers don't understand how to use the modern tools and techniques available to them. This blog is about presenting those tools and technique so that others can benefit from this experience.
Subscribe to:
Posts (Atom)