Exploring Modern Service Virtualisation at TestWorksConf (and Guidelines for running your own Workshop)
The SpectoLabs team presented a microservices testing workshop at the recent TestWorksConf conference in Amsterdam, and we are keen to share both our experiences of the workshop and also our materials under Creative Commons so that others can re-use them.
TestWorksConf was a great event, and was very much focused towards introducing the concept of increasing automation throughout the QA lifecycle and also in promoting the ‘Dev in Test’ role. This is something we’re also passionate about at SpectoLabs!
We are also happy to run this or other automated testing workshops at other conferences, or publicly and privately, so please get in touch if you would like to know more.
Introduction: Setting the scene
We began the session by stressing the importance of testing and quality assurance (in addition to building quality in, of course), and discussed that this requirement is now continually getting more complex with the evolution of service-oriented and distributed architectures such as “microservices”.
Group discussion: Tricky third-party testing
Next we divided the attendees into groups for a discussion-based exercise that deals with a typical tricky testing problem involving the integration of a third-party API into a tech stack. After fifteen minutes of facilitated discussion we ask the groups to present their findings to the entire room - this always generates lots of interesting discussion, and the solutions presented have been different each time we have run this workshop!
Introduction to service virtualisation
After concluding the group exercises we next presented an introduction to modern service virtualisation, and adapted Andrew’s recent presentation at JAX London on “Simulating APIs for Effective Testing: (Micro)Service Virtualisation”.
You can find all of the content we presented in the workshop slide deck below:
Hands-on exercises
The hands-on exercise involves using the open source service virtualisation tool Hoverfly to explore quality issues with a small Java-based microservice architecture.
The instructions can be found in this PDF, and the code can be found within a fully configured VM running Ubuntu that was generated by the Xebia team within the twc-workshop-vm Vagrant file (if you want to know more about how to use Vagrant, then please visit the project’s website). Alternatively, the source code (without environment configuration or other setup included within the VM) can be found in Benji’s GitHub repository https://github.com/benjih/oreilly-docker-java-shopping.
Summary
We have run this workshop several times now, both as a standalone event, and also part of a large workshop on practical microservices testing (to get an insight into this, check out our blog post “A Proposed Recipe for Designing, Building and Testing Microservices”).
We hope you find this material useful for getting started in modern service virtualisation and microservice testing.
If you have any comments or questions, then please do get in touch!