Every business is unique, which is why each one will need to follow the testing approaches that make the most sense for its needs. Luckily, there are a wide variety of agile testing methodologies that quality assurance teams can leverage. One such path is acceptance test-driven development. This particular practice fits in seamlessly with agile values and can be a significant asset to projects when executed effectively. However, there are a number of uncertainties when pursuing a new testing method, and it can be very risky to jump in without a plan of action. For example, will automated acceptance testing be involved and if so, to what extent?
Answering these types of questions in your strategy will not only help successfully adopt acceptance test-driven development but also bring teams one step closer to supporting agile test management operations.
What is ATDD?
The first thing to do is to understand what exactly acceptance test driven development is. ATDD begins with the end in mind - it involves the whole team collaboratively discussing acceptance criteria and creating a set of concrete acceptance tests prior to development. Test Obsessed's Elisabeth Hendrickson noted that this process ensures that everyone has the same shared understanding of what they're building as well as a single definition of a finished project. This knowledge will help teams stay on track and establish goals to reach before the project can be pushed into production. Once the test passes, the feature is deemed functionally acceptable and is relied on to reflect stakeholder expectations.
Successfully using ATDD as a tool can be complex, as it requires teams to collaborate over user stories during each sprint to make sure that everything works as it should. If a test is no longer functional, it must be taken out or rewritten to adjust to new standards. Despite these challenges, there are a number of benefits to be seen, including improved quality, better communication and increased productivity. For developers and QA alike, these advantages cannot be ignored and make the hard work of ATDD worthwhile for agile practices.
"As a developer, I find specifying the requirement and then having that as my goal an extremely efficient way to work," Ministry of Testing contributor Peter Karas wrote. "I remain focused during the features implementation and can clearly state what is within the boundaries of the specification and what aspects will require the most effort."
Adding in automation
In an agile environment, automated acceptance testing has become a necessary asset to meet the fast pace of change and push products to market quicker than ever before. However, automation integration isn't right for every situation - nor should it be - making it difficult for many teams to determine if it would be beneficial to pair with ATDD. Fortunately, ATDD is a perfect candidate for automation initiatives and can save teams significant time and effort to execute. TechTarget contributor Lisa Crispin noted that user maps can be set out as executable tests in an automated framework. Once the automated test passes, teams can then leverage exploratory testing to identify more behaviors represented by the test results. Rather than having to code and run these scripts every time, the tests that pass can be reused to deliver results and give QA a chance to finish other tasks.
"When the tests are passing, they may form part of our automated regression test suites," Crispin wrote. "Once 'green,' they must stay that way. If a regression failure occurs, or a test needs updating to reflect a change to production code, we stop what we're doing and get it passing again."
Benefits of ATDD Testing automation
Ultimately, it's going to be in a QA team's best interest to automate ATDD testing scripts. Although groups will still have to meet to discuss criteria and behavior requirements, the test itself does not need to be run by hand. Not only will there be advantages from the regression suite's short feedback loop, but the tests become living documentation that can be referred to at any time. Behavior can be demonstrated through automated acceptance testing to show how a feature works and can help give stakeholders peace of mind that the app will perform as expected.
"By writing the right code, supported by automated regression tests that provide quick feedback, you'll keep your technical debt low," Crispin wrote. "You'll build a library of living documentation. Like my team, yours will deliver business value frequently, while working at a sustainable pace, and realize a huge return on your investment in ATDD."
The complexity of software development does not mean that some processes have to be difficult. By implementing automated acceptance testing in ATDD, organizations will not only see significant benefits, but they will also be able to build in better quality for each project. ATDD paired with automation will help support agile efforts and give teams back time to complete other tasks to create apps that meet user needs.