Test Driven Development With Eclipse
Please turn off all
Test Driven Development
Test Driven Development
Out of the Box
Demo: Complex Arithmetic
Create the Project
Your first test method
Writing the Complex class
Run the test
Debug until the test passes
Write another test
Repaired code
Any other obvious bugs?
Adding a feature
Unit Testing
Reinitialization Example
Consequences
static data is not reinitialized
Fixtures
Freeing resources after each test
Assertion Messages
Floating point assertions
Comparing floating point numbers
Integer assertions
Object comparisons: asserting object equality
Object comparisons: asserting object identity
Asserting Truth
Asserting Falsity
Asserting Nullness
Asserting Non-Nullness
Deliberately failing a test
Tests that throw Exceptions
Testing exceptional conditions
Test Suites
Test Suites
Test Suites Can Be Combined Into Larger Suites
What to Test
What Not to Test
To Learn More
Questions?
Entire Presentation as Single File
Start
|
Cafe au Lait
Copyright 2005 Elliotte Rusty Harold
Last Modified December 10, 2005