logo logo

Dealing with Dependencies in Your Testing and Automation Efforts

main post image

The purpose of this series of four articles is to introduce you to various ways in which you can use simulations to increase the efficiency and coverage of your test automation efforts. By reading the articles in this series, you’ll learn more about:

  • The first article will discuss the two types of challenges that dependencies pose when you’re trying to write targeted and efficient test automation, what problems they cause and how the use of simulations can help to mitigate them.
  • The next article will help you to get started with using mocking to isolate the method or class you want to test in your unit test from unwanted and unpredictable outside influences caused by dependent methods and classes. This article will contain runnable examples written using Mockito, a popular Java mocking framework.
  • Next, we’ll introduce the concept of service virtualization and how it can be used to simulate dependencies that are not available or pose other types of challenges by means of a number of examples written using WireMock, an open source service virtualization solution written in Java.
  • In the final article, we’ll explore some more advanced WireMock features to show you how a service virtualization solution can be used to simulate more realistic dependency behaviour required by your integration and end-to-end testing efforts.

Tutorial Chapters

  1. Increasing Test Efficiency with Simulations & Service Virtualization (Chapter 1)
  2. Isolating Components in Unit Tests with Mockito (Chapter 2)
  3. Getting Started with Service Virtualization using WireMock (Chapter 3)
  4. Simulating Rich Behaviour using Advanced WireMock Features (Chapter 4)

With the information presented in this article series, you’ll have everything you need to help you identify challenges caused by dependencies in your testing and test automation efforts, as well as pointers to solutions to solve them. You’ll also have a collection of runnable examples that you can use and build on to start using Mockito and WireMock in your own test automation efforts, or to expand and improve the way you’re already using these or similar tools.

Happy Testing! 🚀

Avatar

About the author

Bas Dijkstra

Bas is an independent professional who takes pride in helping teams and organizations improve their testing efforts through smart application of tools.

Bas is also a trainer on various subjects related to testing and automation. He lives in the Netherlands with his wife and two sons and when he is not working he likes to run or to read a good book (particularly British detective novels).

Join TestProject Community

Get full access to the world's first cloud-based, open source friendly testing community. Enjoy TestProject's end-to-end test automation Platform, Forum, Blog and Docs - All for FREE.

Join Us Now  

Leave a Reply

popup image

Best In Class Java and C# SDK

Join thousands of automation developers using TestProject to supercharge open source testing, with a Selenium and Appium SDK, supporting Java and .NET Core (C#)!
Sign Up Now right arrow
FacebookLinkedInTwitterEmail