00Official Book Site

The Art of Unit Testing, 3rd Edition

with Examples in JavaScript. Roy Osherove · Manning

This expanded edition teaches mocks, stubs and dependency injection in functional, modular and object oriented style.

Markdown version

Print + ebook from Manning · Buy links go to Manning and include Roy’s affiliate code.

01The book

The 3rd edition

The Art of Unit Testing, Third Edition (opens in a new tab) updates an international bestseller to reflect modern development tools and practices.

You’ll explore test patterns and organization, working with legacy code, and even “untestable” code. The many tool-agnostic examples are presented in JavaScript, and are carefully designed so that they apply to code written in any language.

More about the 3rd edition

02Workshops

Choose Your Language

Hands-on unit testing and TDD training with Roy, in the language your team writes.

  • 3-day hands-on workshop

    TDD & Unit Testing in C#

    Learn how to write your first test with NUnit or XUnit, learn about mocks, stubs and fakes with isolation frameworks such as FakeItEasy & NSubstitute, and refactor legacy code so you can test it easily.

  • 3-day hands-on workshop

    TDD & Unit Testing in Modern JS

    Learn to write unit tests for async and observable code, as well as methods of faking functions, modules and other types of dependencies. You’ll explore test patterns and organization, working with legacy code, and even “untestable” code.

  • 3-day hands-on workshop

    TDD in Java with JUnit 5

    Learn about the practices of TDD, and use JUnit 5 to test-drive new functionality. On the way you’ll learn about readability, maintainability & trustworthy tests.

  • 3-day hands-on workshop

    TDD in Kotlin

    Start learning the skills of unit testing and TDD in Kotlin with Kotlin-Test, JUnit 5 & mockk.

03Free resources

Start here

04Work with Roy

Services by Roy Osherove

Roy Osherove

I’m the founder of Legato Labs, author of The Art of Unit Testing and also created the String Calculator Kata. I consult & train teams on various engineering practices & related topics such as:

Book a service

05Testimonials

From workshop attendees

Rarely are subject experts also great teachers, Roy is the whole package.

Blake RhodesSoftware Engineer

Very exciting course with precise balance between theory and practice. Roy is an extremely good listener making me not hesitate to get all the answers I need in a very clear way. Even if you have experience with TDD, I highly recommend his TDD Mastery Training.

Diego FariaSoftware Engineer

Roy is an excellent speaker with a good pace on his course. I will definitely implement what I learn.

Marcio Carneiroreis

Perfect course, liked the content and educational guidance! Recommend it highly!

Marco Pasopas

Great course for junior/mid level specialists wanting to start changing their thinking to TDD way of thinking.

Aleksandras Gavinciuk

06Contact

Bring a workshop to your team

Training, coaching or remote test reviews: send Roy a message.

Contact RoySee services