Chapter 9. Testing microservices: Part 1

This chapter covers:

  • Effective testing strategies for microservices
  • Using mocks and stubs to test a software element in isolation
  • Using the test pyramid to determine where to focus testing efforts
  • Unit testing the classes inside a service

FTGO, like many organizations, had adopted a traditional approach to testing. Testing is primarily an activity that happens after development. The FTGO developers throw their code over a wall to the QA team, who verify that the software works as expected. What’s more, most of their testing is done manually. Sadly, this approach to testing is broken—for two reasons:

  • Manual testing is extremely inefficient—You should never ask a human to do what a machine can do better. ...

Get Microservices Patterns now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.