O'Reilly logo
live online training icon Live Online training

Test Driven Development in Java

Tools and techniques for writing better tests and programming efficient applications

Daniel Hinojosa

In test driven development (TDD), you first write an executable test of what your application code must do. Only then do you write the code itself and, with the test spurring you on, you improve your design. You use the same technique to implement product features, benefiting from iterative development, rapid feedback cycles, and better-defined requirements. Simply put, TDD and its supporting tools and techniques lead to better software faster.

In this live, hands-on training course, industry practitioner and TDD expert Daniel Hinojosa teaches you the basics of TDD using the Java programming language. You’ll learn about the best tools and techniques for getting started, including JUnit, EasyMock, Eclipse, and IntelliJ IDEA. You’ll then learn the mechanics through interactive group projects, Q&A, and practical challenges.

What you'll learn-and how you can apply it

By the end of this live, hands-on, online course, you’ll understand:

  • How to get started with TDD in Java
  • How to navigate major pitfalls and challenges encountered in rea- world development environments
  • How to use the best tools for building efficient applications

And you’ll be able to:

  • Implement TDD techniques in your current role as a Java developer
  • Build more efficient applications

This training course is for you because...

  • You're an experienced Java developer who wants to learn more about the tools and techniques for implementing TDD to build better software faster.


  • Working knowledge of Java
  • Understanding of an IDE such as Eclipse or IntelliJ

Recommended Preparation:

Continued learning after the course:

  • Test Driven (Book, Parts 2 and 3)

About your instructor

  • Daniel Hinojosa is a programmer, consultant, instructor, speaker, and recent author. With over 20 years of experience, he does work for private, educational, and government institutions. He is also currently a speaker on the No Fluff Just Stuff tour. Daniel loves JVM languages like Java, Groovy, and Scala, but he also dabbles with non-JVM languages like Haskell, Ruby, Python, LISP, C, and C++.

    He is an avid Pomodoro Technique Practitioner and makes every attempt to learn a new programming language every year. Daniel is the author of Testing in Scala and the video Beginning Scala Programming for O’Reilly. For downtime, he enjoys reading, swimming, Legos, football, and barbecuing.


The timeframes are only estimates and may vary according to how the class is progressing


Introduction to TDD (30 minutes)

Efficient Programming (30 minutes)

Discussion: If TDD failed, why? (5 minutes)

Break (10 minutes)

Recommended IDE Setup (15 minutes)

Group Project : Simple TDD (30 minutes)

Break (10 minutes)

Group Project (continued): Simple TDD (40 minutes)

Homework : FizzBuzz (10 minutes)


Introduction to Mocking (40 minutes)

Group Project: Checkout Books (50 minutes)

Break (10 minutes)

Group Project (continued): Checkout Books (50 minutes)

Break (10 minutes)

Quotes on TDD (10 minutes)

Q & A (5 minutes)

Conclusion (5 minutes)