Practical Objects: Designing, Testing & Refactoring in Java
OO Design can only take you so far, at some point you have to implement your
UML diagrams in Code. This "hands-on" course shows how, using the JUnit
testing framework from Kent Beck and Erich Gamma, you can drastically improve
the quality of Java code. The coding process introduced by this course ensures
that Unit Test coverage is complete. After the code has been written and is
functionally working, then refactoring techniques are needed because when we
are adding functionality, keeping the design clean is not always top priority,
we just need to make it work. Using the two step process of Add Functionality,
then Refactor Design, gives the twin benefits of faster development and maintainable
code.
Duration and intended Audience
This is a 2 day intensive, hands on course. The first day focuses on Designing
and Testing, the second on Refactoring.
Participants should have a working knowledge of the Java JDK 1.1 command line
tools and UML. Familiarity with Rational Rose is useful.
Course Goals
- Learn how to use the JUnit testing framework to develop Unit Tests for Classes
- Learn how to implement UML designs in Java
- Discover the benefits of well factored code
- Get "hands-on" practice in applying the Refactoring Transformations to improve
existing designs
- be able to recognize good code and identify issues with poor code
- know how to use version control effectively
- be able to use short cycle incremental, iterative development
Course Content
- Basic Concepts
- Understanding OO development process
- Understanding the need for Test Harnesses
- Creating Test plans for OO Systems Using the JUnit test harness
- An introduction to Testing in Java
- Understanding what testing means
- Understanding why testing must be automated
- Recognizing the limitations of testing
- Using the JUnit testing framework to test classes
- An Introduction to Refactoring
- Understand what Refactoring means for Code
- Refactor Java code to improve maintainability
- Understand the benefits of well factored code
- An introduction to Design for Java
- Using informal OO Design techniques to create effective application
architectures
- Designing Java implementations from UML models
- Creating Test cases from Use Cases
- Refactoring in Java
- Refactoring Java code to improve maintainability
- Improving the quality of systems by using Incremental & Iterative development
processes
- Understanding which Refactorings to apply
- Incremental Development and the User Interface
- Adding functionality to refactored code
- Applying the techniques to UI design
- Using Application Facades to minimize dependency on specific GUI libraries
Recommended texts
Back to the Mentoring and Training Page
Pete McBreen, pete@mcbreen.ab.ca