Blog

When GenAI Steps In: Generating Test Cases and Automated Tests

Previously: every release meant dozens of tasks, hundreds of scenarios, and a large volume of test documentation that the team had to manually create, review, and keep up to date.
Now: you upload requirements and UI designs, and AI generates test cases, suggests automated tests, and captures interface details with high accuracy.

Context

As the product evolved and release frequency increased, the team faced a common scalability challenge in QA: the volume of tasks, scenarios, and test documentation was growing faster than the team’s capacity.
Each release included dozens of tasks, requirements, mockups, comments, and corresponding test cases and automated tests - all of which required manual coordination and maintenance. This significantly extended release preparation time and slowed down the team’s ability to respond to changes.
Routine work became the primary bottleneck: preparing test documentation and continuously synchronizing scenarios. At the same time, regression testing expanded, and validating both new and existing scenarios required increasing effort.
Eventually, it became clear that scaling this process manually was no longer viable. The choice was either to expand the team or to optimize the process itself. This led to a focus on automating test case and test automation generation while reducing manual effort.

Objectives

At the start of the project, we aligned with the client on the desired outcomes:
  • Automate routine tasks so that test cases could be generated from requirements and documentation almost instantly, with minimal manual input
  • Make automated testing more accessible, ensuring tests are generated alongside test cases rather than weeks later, and can be quickly integrated into workflows
  • Achieve “expert-level” quality, ensuring that generated test cases match the quality of manual work, with a target of at least 80% alignment with outputs from experienced QA engineers
  • Ensure transparency, allowing any team member to understand how a test case was generated and easily trace all related artifacts

Solution

We developed a service that automatically generates test cases and automated tests based on requirements and project documentation. At its core is a generative AI model that analyzes input materials, identifies user scenarios, and structures them into test cases.
The system processes not only textual data but also visual inputs. UI mockups and screenshots are analyzed via a Vision API, enabling more accurate representation of real user behavior and interface interactions.
The entire architecture is centered around scenarios as the primary entity. Each scenario stores its full context: requirements, test cases, automated tests, and change history. PostgreSQL is used for storage, ensuring data integrity and scalability across large volumes of scenarios.
The output is a standardized set of test cases in AAA format (Arrange–Act–Assert), including steps, preconditions, and expected results. The system also supports prioritization and traceability to source artifacts, making the results production-ready and easy to maintain as the product evolves.
On top of this, automated test generation is implemented based on the test cases. The system converts scenarios into executable code, taking into account the programming languages and frameworks used by the team, allowing immediate integration into existing QA pipelines.
The result is a unified tool that connects requirements, test cases, and automated tests into a single workflow - reducing manual effort, accelerating release cycles, and making the QA process more structured and transparent.

Results

Initially, the goal was to validate a simple hypothesis: can AI generate test cases of sufficient quality to be used with minimal adjustments?
To test this, real project documentation and requirements were fed into the system, and the output was compared against test cases previously created by experienced QA engineers.
Key outcomes:
  • Most generated test cases were used without modification, significantly reducing the time required to prepare test documentation
  • Automated tests were generated alongside test cases, accelerating the transition from requirements to test execution
  • Manual effort in the QA process decreased substantially, making testing faster and more predictable
  • The system consistently handled diverse input formats and large volumes of documentation, maintaining stable generation quality and adapting well to feedback-driven improvements
Continuous collaboration with the team enabled rapid iteration: duplicate scenarios were eliminated, test case structuring logic was refined, and readability of outputs improved.
As a result, the solution evolved from an experimental tool into a production-ready workflow. Test cases are now generated automatically, automated tests appear almost instantly, and the team can focus more on product development rather than routine QA documentation.

Related articles

Case studies