Making the Most of Exploratory Testing
This chapter introduces exploratory testing: manually trying out a new feature to get rapid feedback on its behavior. We’ll describe exploratory testing in detail, consider its strengths and weaknesses, and when you should perform it in a project.
We’ll look at the prerequisites you need to begin exploratory testing and the approaches you should take. This testing can be a miniature version of the complete test plan, taking a customer’s point of view, and using your naivety about how the feature works to identify confusing areas.
Exploratory testing should be used as part of a larger test strategy but can be run in isolation when time is short. We’ll finish by looking at what you should check when performing this testing, and the importance of curiosity, both here and throughout the testing process.
In this chapter, we will cover the following topics:
- What is exploratory testing?
- Advantages, disadvantages, and alternatives
- Understanding when testing should begin
- Understanding the test activities
- The spiral model of test improvement
- Performing the first test
- Mapping out new features
- Using your naivety while testing
- Running complete exploratory testing
- Using exploratory testing by necessity
- Checking exploratory test results
- Using curiosity in testing
What is exploratory testing?
Exploratory testing is a vital tool in your armory. It involves you using a new feature in an ad hoc, unstructured way to quickly find issues and understand its workings. It is typically used early in the test cycle to achieve three main goals: to let you understand the feature you are testing, to discover any tools or knowledge you need, and to find blocking bugs that may delay the testing later on.
In exploratory testing, the test design, implementation, and interpretation are conducted simultaneously. This is also known as ad hoc testing, which has been frowned upon due to its unstructured format. However, it is a valuable stage in a project if deployed alongside other testing techniques. In a large project, it can be used early on to help plan more comprehensive tests, or if deadlines are tight, exploratory testing might be the only testing there’s time for.
In an ideal cycle, the team will plan both the feature and its testing at the start of development. In that case, exploratory testing enhances the test plans that already exist. In other development teams, testers are involved later in the project and may only plan the testing in earnest once the first version is already running. In both cases, exploratory testing is a necessary step for you to see a new feature working in practice so that you can write detailed test plans with the exact behavior in mind.
Exploratory testing must be performed manually so that you can get your hands on the new feature and see what inputs and outputs are available. Other parts of testing can be run manually or with automation, but exploratory testing must be manual because the main aim isn’t to find bugs but to understand the feature. Based on that understanding, you can plan further testing.
Not everyone can perform exploratory testing. In particular, it needs input from someone other than the developer who worked on the code. The developer should ensure the feature is working for them, but exploratory testing shows whether it can work in another environment for another engineer. That is the second goal of exploratory testing: to find issues significant enough to block further tests.
If the new feature doesn’t run in the test environment, if a page throws an error, or parts of the functionality aren’t available, that will block testing of those whole areas. Exploratory testing can quickly find those issues so that they can be fixed early in the development cycle and not cause delays later on.
First, we’ll consider the advantages and disadvantages of exploratory testing, along with alternative approaches that perform similar roles.
Advantages, disadvantages, and alternatives
Exploratory testing has distinct strengths and weaknesses. It is an important part of the testing cycle, but only if combined with other forms of testing to mitigate its shortcomings. Throughout this book, we’ll see how the advantages of different forms of testing complement each other and why you need a mixture of different approaches to get great coverage of a feature. Here are a few of the advantages and disadvantages of exploratory testing:

Table 1.1 – Advantages and disadvantages of exploratory testing
Exploratory testing is quick and easy. So long as you have the running code, you don’t need any other prerequisites, such as documentation or testing tools. That said, there should be user stories or other guidance material that you can work from to enable the feature and improve the effectiveness of your testing. Finding bugs is simple because you are watching the product as you use it; you don’t need to check a monitoring console or automated test output for errors. You can see what the system was doing at the time because you were using it yourself.
On the downside, it can be difficult to reproduce issues. Unlike an automated test that precisely performs a documented set of actions, if you were just clicking around when something strange happened, it may not be obvious what you did to trigger the problem. I once found a bug because I rearranged the windows on my screen partway through testing – changing the size of the browser window caused the issue. It took me some time to realize that had caused the problem, instead of all the actions I had taken in the application itself.
To make it easier to find the cause of bugs, you can record your session, either simply on video, within the application, or in the web browser that you are using for your tests. That takes a little time to set up and review but can be very helpful when trying to reproduce issues.
While exploratory testing doesn’t need many prerequisites, it helps to have a description of the feature so that you know any areas of functionality that aren’t obvious from its interface.
Another requirement is that it should be carried out by an experienced tester. Because exploratory testing is not reviewed or planned, its success depends on the skill of the individual carrying it out. A tester with experience will know the areas that are likely to cause bugs and can try tests that have failed in the past. They will also know what to check to find issues. A junior tester will not reach the same level of coverage.
The skills involved in exploratory testing – the curiosity and alertness it requires – are required throughout the test process, even when running more formalized test plans. Whether or not you are officially performing exploratory testing, you should always approach manual tests with this same mindset.
The coverage provided by exploratory tests is also difficult to measure. How much of a feature have you tested with exploratory testing? In practice, you will need to perform all these tests again as part of a more rigorous test plan, so you will repeat anything you do during exploratory testing. For this reason, you should limit how long you spend on these tests. They provide valuable feedback, but only so long as you are learning from it. Comprehensive testing starts later in the process.
To measure what coverage you have achieved, you can have a debrief to talk through the testing you’ve done with the product owner and developer. They can also suggest other cases to try. See Chapter 3, How to Run Successful Specification Reviews, to learn more about reviewing the specification and the scenarios that should be tested.
The final weakness of exploratory testing is that it does not cover non-functional tests. Here, you are just checking whether the feature works at all, not that it can achieve high loads, work in many environments, or recover from failure conditions. All those tests will come later but are not a priority at this stage.
The alternatives to exploratory testing include detailed specifications and preparing user stories and UI mockups, although, in practice, exploratory testing complements all those tasks. A sufficiently detailed specification should give enough detail that you can write the test plan from it directly. However, in practice, it is much easier to finish the details of the specification when you can use the code for exploratory testing. The same is true of user stories. They are very useful for defining and refining the core functionality but don’t usually cover error cases. Those can also be easier to find in real usage. User interface mockups are also massively helpful to define how a feature will look and its options, but it is still valuable to try those for real when they are available.
It may seem strange to begin the discussion of testing with exploratory testing, which can only begin once an initial version of the feature is complete. The following section describes the place of exploratory testing in the development life cycle and shows that while it might not be the first testing task that you start, it is the first you can finish.