Golden Scenarios

Today's tip comes from Brett Leonard.

In the Beginning... Mass Hysteria and Confusion...
When faced with a new testing challenge, finding a place to start designing your tests can be difficult. It is natural to suffer from stimulus overload and feel overwhelmed. Using a minimalist approach to data setup can accelerate the development and execution of complex scenarios and quickly provide a means to report on the status of the application. In this article I will describe a testing challenge I recently faced and how I used a simple end-to-end test scenario, or “Golden Scenario”, to rapidly test and track the development of the feature under test.

A Challenge with No Easy Answer
Recently, I needed to design tests for a complex feature that had been in development for a few months but had not been tested from an end users point of view. I needed to quickly understand the feature and design a method to test it. The first thing I did was schedule a meeting with our developers, architect, and product manager. Our meeting was productive but did not give me enough information to begin drafting my test scenarios - much of our conversation revolved around the data architecture challenges that were still ongoing.

I wanted to find a way to cut through the complexity and define initial scenarios. Once the initial scenarios were defined and communicated, I would have a mechanism to report on the application status by tracking the progress of our test execution.

Studying Economics Finally Pays Off
The next day, while contemplating screenshots of the feature, my schooling in economics came to mind. Economists use simple models to understand complex systems. For example, in my international economics class, we constructed a model using a country that produced one good - a ”one good country” and examined the supply and demand curve in this simple economy. Once we understood the “one good country” economy we added complexity by introducing another “one good country”. Later, we increased the number of goods and created much more complicated models. This led me to the idea of using a similar approach to develop my first end to end scenario that I deemed, the “Scenario of One”.

The Golden Scenario Technique is Born
The Golden Scenario Technique (ours was named “The Scenario of One”) uses a minimalist approach to setting up test data. To implement it you simply define a scenario that requires the absolute minimum amount of setup necessary to interact with your targeted feature. In my case, I’m testing a project management application, which starts with “projects” as a container. A “project” can have multiple “packages” and “packages” can have multiple “participants”.

Our First Scenario Defined and Communicated
My first scenario was to create a project with one package and one participant. The act of setting up the data for this scenario exercises a great deal of code that would provide us with valuable information about the state of the application. By defining and adding this scenario to our testing dashboard we finally had a clear direction and method to communicate test results.

Excited with our path forward, I quickly wrote up a mission in One Note© (my favorite test documentation tool), and presented it to my team. That morning in the daily development status meeting (or daily Scrum meeting), I described my idea and declared that our mission for the day would be to complete the setup of the “Scenario of One” or document the roadblocks that prevented it.

Mass Hysteria and Confusion Evaporates
With the mutual understanding of this limited scope I broke down the complexity to a manageable, understandable, and reportable form which I can now use to guide the development and execution of additional test scenarios. I had blazed a path forward and felt as though I had finally taken control of our testing effort.

To document our results in real-time, I drew a chart on our dashboard with the various steps of the process in a straight line. As we executed our tests, I would use color-coding to indicate how far our testing had progressed. At first, there was a lot of red but eventually (after two painful weeks) we were able to report that we made it through all variations of the scenario.

Jump Start Your Testing with Golden Scenarios
The next time you feel overwhelmed with a testing situation, try asking yourself “what is the minimum amount of set up that I can do to start testing this application?”, make it your first scenario, and begin testing. It will jump start your test execution and give you valuable information about the state of your application. You will be well on your way towards providing the valuable information testing is supposed to provide the stakeholders of your application.