The importance of testing

Table of Contents

Integration tests

(Learnings from Trinet project)

  1. They help catch all the “runtime” errors before the PR is merged.
  2. They use Liquibase and Wiremock.
  3. They are kind of difficult to set-up but once they are in place, they are golden.
  4. They are baked into automated CICD.
  5. A lot of errors are caught even before the code is merged.
  6. Learn to do the following steps.
    1. Using Liquibase to load a database and tables and using them for integration tests in a springboot application.

Testing

Never underestimate the power of testing. That is where all the bugs related to the code we worked on will be discovered. We are not talking about junit tests here. We are talking about end-to-end testing - with a combination of positive and negative and repetitive scenarios thrown into the test suite. If you write a piece of code and do not test it, or all combinations of it, you can be sure that someone will discover something wrong with it. It will come to bite us in the ass. So, take it seriously and add as many possibilities into the mix as possible. Automate it so that running them doesn’t have to be painful.


Links to this note