Review: Specification by Example workshop with Gojko Adzic

For a consultant wanting to stay on top of their game (or at the very least hireable) it’s a good idea to take a step back from the daily work of consulting and writing every once in a while and get inspired by a conference or a course or workshop. When the WannaFlex team announced they invited Gojko Adzic to bring his Specification by Example workshop to Amsterdam, it didn’t take me long to decide to sign up. I have come across the approach in previous projects, but found myself lacking experience and background information, and this workshop looked to be an excellent opportunity to get some of both.

What is Specification by Example?
In the booklet we received as a handout, Specification by Example (SbE) is defined as:

A set of process patterns that facilitate change in software products to ensure the right product is delivered efficiently

In my own words, SbE is a set of techniques that help software development teams to reach a shared understanding of the software about to be built, in order to eliminate (or at least greatly reduce) the possibility of mismatched expectations leading to incorrect software or software that will not be accepted and used to satisfaction by the end user.

Organization and setup
The SbE workshop is a two-day workshop where theory and practice around the creation and validation of software specifications take turns. First some theory, then a practical exercise, mostly conducted in small groups of four or five people. This group size is large enough to not come to an agreement on specifications too soon, but small enough to avoid the risk of endless discussions.

Specification by Example workshop announcement

Day one: creating specifications
The first day of the workshop focused mainly on the importance of creating clear specifications and how to get to that point. For example, we were given a set of ‘traditional’ requirements for a piece of software and 20 minutes to select a subset of the requirements and a pen and paper implementation. In other words, we simulated what could be sprint 1 of a development process, based on requirements that turned out to be vague, ambiguous and often plain incorrect. This is a learning technique that I have quickly come to appreciate now that I’ve experienced it first-hand: tell people just enough to get them started, let them make mistakes and discuss these afterwards. This is far more effective than simply showing and telling how something needs to be done!

We were also introduced to the process of how to get to good (or at least significantly better) specifications. In short (for the full story I highly recommend you take the workshop yourself if given the opportunity):

  1. Come up with examples of what the system should do. Any example will do as long as its valid, since every example tells you something about the desired behavior of the system you’re writing specifications for.
  2. Try and detect the pattern that’s behind the examples. What are the input parameters? What is the output? And so on.. This will help you see the bigger picture and get it clear what the system is supposed to do.
  3. Work on the boundary cases. This is where the interesting stuff happens, where questions mostly arise and where defects occur most often. Therefore, it’s a good idea to give them enough attention in the specification process.

Day two: application
Day two started with ways to apply the specifications in practice. Patterns such as Given / When / Then were introduced and the link to test automation was made. As a test automation consultant, this was especially valuable to me. I’ve seen and worked with most of the tools that were discussed (such as Cucumber, SpecFlow and FitNesse), but the link to SbE theory was very useful information. We also spent some time analysing a number of specifications from real-world projects and seeing where they could be improved (if they weren’t beyond saving..). Very useful as well.

Unfortunately, due to other commitments, I couldn’t stay until the end of the workshop so I don’t know exactly what has been discussed in the afternoon of the second day. Still, the first day and a half provided me with lots of useful information and tips on how to apply SbE in practice and how to combine this with test automation in my projects.

Lessons learned and recommendation
Too many to mention here! I’ve learned a lot in this workshop, both with regards to SbE as a technique as well as on how to facilitate a workshop. If you’re faced with SbE in your project or organization, or if you just want to know more about the technique and how it can help you to create better specifications and therefore better software, I highly recommend attending the SbE workshop. And if you like to learn from the best, you simply can’t go wrong with Gojko.

Thanks too to the people at Wannaflex for making this a very smooth and pleasant workshop.

An update on crafting my career

Now that it’s almost time for me to go on what I think is a well deserved holiday, I thought it would be a good idea to take some time and see where I stand with regards to reshaping my career the way I want it to look like. In the last couple of months, some interesting developments have taken place that I think are small steps in the right direction. I also discussed my ideas on how my ideal working life would look like (freedom and variety basically sums it up) with some other people, resulting in either encouragement or blank stares. I don’t know what to make of the latter, but the encouragement is nice.

So, what have I been up to? First of all, I started a new project, since the one I was previously working on was not a good fit for me. I didn’t feel I could make a valuable enough contribution there to warrant both my hourly rate and the commute (an hour one way), so I decided to end it and go look for a new one. My current project is in an enterprise environment with a very heterogeneous application landscape and lots of room for improvement in the testing and test automation area. I’ve come to realize that this kind of organization and project fits me much more than the web development organization I was at before. Also, my commute has been cut in half, which gives me much more time to spend at home with the wife and kids, and to work on other projects, which to me is huge as well. That’s one thing I love about being self employed: the ability to choose what you’ll be working on and when to stop a project that is not a good fit.

Freelance freedom

Also, I’ve been asked by O’Reilly (the media and publishing company) to write a 20-30 page report on the state of and current trends in service virtualization. At the time of publishing of this blog post, it’s up for a final review, with a planned publishing date of September of this year. I’ll probably write a separate blog post with a link to the report once it’s published, so keep an eye out for that one to see if it is interesting to you too. The report will be accompanied by a blog post on another web site as well (of which I currently do not know the URL), which is part of the package deal agreed upon. The report will be freely downloadable and sponsored by HP Enterprise. I am very excited to have been asked to do this in the first place, much more because these writing assignments are exactly the type of projects I would like to fill my ideal workday with. Also, it’s another valuable exercise in honing my technical writing and English skills.

Furthermore, a couple of weeks ago, I had the privilege to receive an invitation to deliver a test automation-related workshop at the first edition of the Iasi spin-off of Romania Testing, to be held on November 4th (thanks again, Richard, for referring the organization to me!). Needless to say I happily accepted the invitation, so I’m currently in the early stages of workshop preparation. Also, I’ve never been to Romania before, so that’s a nice bonus too for someone that wants to see as much of the world as his schedule and finances allow.

Romania Testing - Iasi edition

Next to that, I’ll be giving a presentation at Centric (an IT services provider) in November as well on a yet to be determined topic related to test automation. I was invited to do this thanks to a referral from Sara, who attended my REST Assured workshop in May. So, again, thanks for that! It’ll be a nice opportunity to meet new people, do some networking and to further practice my public speaking skills.

Another thing that has kept me busy for some time now is the idea of transitioning from billed-by-the-hour work to offering project- and value-based services. Or even a product.. I’m still not sure as to what such a service or product should look like, but I AM sure that I don’t want to be depending purely on hourly work for long anymore. It doesn’t scale and it is a restriction to the freedom of working when and where I want to that I would like to have. As you can read above, I’ve been given the opportunity to take some small steps in the right direction, but I’m not nearly there yet.

The last I’ve been thinking about, and this is the first time I’m talking about this to anyone but myself, is writing a book on test automation. I know, there are lots of those already, but a lot of them focus on specific tools and how-to’s. What I think is missing is a thoughtful and balanced overview of the current state of test automation, and a debunking of a lot of still common test automation myths. If I decide to go through with this plan (currently I’m veering towards a ‘yes’) that’s another thing I would like to start on this year. Any comments or ideas are highly welcomed!

To round things up, I’m still not sure as to how to move forward, but writing this up makes me see for myself that I am moving in the right direction. The end goal is pretty clear now, but the road towards that goal is still pretty misty. Maybe some time off work will generate new ideas that can be pursued once I get back.

Finally, I’d like to share two blog posts from Louise Stigell that pretty much describe how I’m thinking about my career at the moment: ‘Being rich versus being free‘ and ‘Unemployable and proud‘.

Oh, and if you’ve already returned from your holiday: I hope you had a good one. If you’re still going: enjoy it! If you’re currently on holiday: what the &*%^ are you doing here?

Open sourcing my workshop: an experiment

This is an experiment I’ve been thinking about for some time now. I have absolutely no idea how it will turn out, but hey, there’s only one way to find out!

What is an open source workshop?
I have recently created a workshop and delivered this with reasonable success to an audience of Dutch testers. I have received and processed the feedback I got that day, and now it’s time for the next step: I’m making it open source. This means that I’m giving everybody full access to the slides, the exercises and their solutions and the notes I have used in the workshop. I’m hoping this leads to:

  • Feedback on how to further improve the contents and the presentation of the workshop
  • More people delivering this workshop and spreading the knowledge it contains

What is the workshop about and who is it for?
The original version of this workshop is an introduction to RESTful web services and how to write tests for these web services using REST Assured. It is intended for testers with some basic Java programming skills and an interest in web service and API testing. However, as you start to modify the workshop to your personal preferences, both the contents and the target audience may of course change.

A simplified outline of the workshop looks like this:

  1. An introduction to RESTful web services and their use in modern IT applications
  2. An introduction to REST Assured as a tool to write tests for these services
  3. Setup of REST Assured and where to find documentation
  4. Introduction of the application under test
  5. Basic REST Assured features, Hamcrest and GPath
  6. Parameterization of tests
  7. Writing tests for secure web services
  8. Reuse: sharing variables between tests

The workshop comes with a couple of small (this workshop was originally designed to be delivered in 3 hours) sets of exercises and their solutions.

Prerequisites and installation instructions
As stated before, the workshop participants should have an interest in test automation, some basic Java (or any other object oriented programming language) knowledge as well as a grasp of the contents of web services.

The exercises are contained within a Maven project. As REST Assured is a Java library, in order to get things working you need a recent JDK and an IDE with support for Maven. Since TestNG is used as a test runner in the examples, your IDE should support this as well (see the TestNG web site for instructions), but feel free to rewrite the exercises to use your test framework of choice. I just happen to like TestNG.

So where can I find all these goodies?
That’s an easy one: on my GitHub repo.

How can I contribute?
I hope that by now you’re at least curious and maybe even enthusiastic about trying out this workshop and maybe even thinking of contributing to it. You can do so in various ways:

  • By giving me constructive feedback on either the concept of an open source workshop, the contents of this particular workshop, or both.
  • By spreading the word. I’d love for you to let your friends, colleagues or anyone else in your network know that this workshop exists. The more feedback I get, the better this workshop becomes.
  • By actually delivering the workshop yourself and letting me know how it turned out. That’s a great form of feedback!

Interesting, but I have some questions…
Sure! Just submit a comment to this post or send me an email at Especially if you’re planning to deliver the workshop, but feel you are stuck in some way. Also, please don’t forget to share the raving reviews you got (or stories on why and where you got booed off the stage..)! Remember that this is an experiment for me too, and if it turns out to be a successful one I definitely will create and publish more of these workshops in the future.

And on a final note, if you’re interested in having this workshop delivered at your organization, but you don’t feel comfortable doing it yourself, please let me know as well. I am happy to discuss the options available and work something out.