An Agent-Based Approach for Automating Behavior-Driven Development
Luciano Belo de Alcântara Júnior, Diego Elias Costa, João Eduardo Montandon
Abstract
Behavior-Driven Development (BDD) enables stakeholders to express the expected system behavior as a collection of test scenarios in a natural language fashion. These scenarios can be automatically executed just like unit tests, ensuring system correctness at the acceptance level. However, making these specifications executable requires developers to implement additional code to connect each scenario to the system code they should execute. In this paper, we present BrinAI, a multi-agent approach that automates the execution of BDD scenarios by generating the step definitions that links both scenarios and the code of the system under test. We leveraged two new datasets of fully executable BDD scenarios mined from open-source projects---GWT-Verified and GWT-Light---to evaluate BrinAI against Large Language Models (LLMs) baselines. BrinAI executed 77 out of 171 BDD scenarios (45.0%), while the strongest baseline did it for 22 (12.9%); the difference remained above 27.3 p.p. regardless the programming language used. By contrast, BrinAI presented a significantly higher cost; US0.0053 for the baseline. Our work discusses the implications of agent-based approaches outperforming single-shot LLM generation, the need for metrics that assess both functional and behavioral success in BDD scenario generation, and the importance of considering execution costs when adopting agent-based solutions.
Create a lesson
Related papers
AutoSpec: Towards Verifiable Software Development via Automated Theorem Proving
Shared title terminologycs.SEGuchan Li, Hongning Wang
When Developers Build Security Tools for Themselves: Requirement Misalignment in Automation Ecosystems
Shared title terminologycs.SEOluwafolajinmi Adewole, Elmira Onagh, Maleknaz Nayebi
Interactive Prompting Assistant: Just-in-Time Requirement Clarification for Agentic Software Development
Shared title terminologycs.SECuong Chi Le, Minh Le-Anh, Long Vu et al.
SatMend: LLM Agents for Automated Software Repair in Satellite Constellations with Intermittent Ground Contact
Shared title terminologycs.SEPengcheng Luo, Zenghui Zhang, Genke Yang et al.
Automated Safety Analysis for Agentic Workflows
Shared title terminologycs.SEYanju Chen, Ying Li, Bosi Zhang et al.
How developers split roles among them and a coding agent and what "collaboration" means
Shared title terminologycs.SELinus Ververs, Helya Dadkhah, Lutz Prechelt