Test-Driven Development in a Java Environment

2 Day Course
Hands On
Code QATDDJAVA

This course has been retired. Please view currently available Agile Development Training Courses.

Modules

Collapse all

Unit tests and the xUnit framework (6 topics)

  • JUnit overview
  • The TestCase and Assert classes
  • Developing a JUnit 4 test and test suite for a class
  • Java 5 features used in JUnit 4
  • JUnit 4 versions of tests and test suites
  • JUnit and ant

Motivation for using Mock Objects (6 topics)

  • Stubs and Mocks
  • Worked example
  • EasyMock argument matchers
  • Mocking and Static methods.
  • When to use Mock Objects
  • Drawbacks of Mock Objects

Test Driven Development (9 topics)

  • Test Driven Development
  • Benefits of TDD
  • TDD Strategies - with JUnit and with fitnesse
  • TDD Process: Worked Examples with JUnit
  • TDD Process: Worked Examples with fitnesse
  • TDD Testing Best Practices
  • Exception tests
  • Performance tests
  • Fixing broken code in a speedy manner, successfully tracking down bugs using a combination of unit tests and TDD scripts

'Code Smells' (5 topics)

  • Benefits of Refactoring Code.
  • Important Refactorings
  • Testing Patterns
  • Testing Heuristics
  • Coverage

Conclusion (1 topic)

  • Pros and Cons of TDD

Prerequisites

Competence in Java, or similar object-oriented programming language.

Course PDF

Print

Sections