paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Test-Driven Code Review: An Empirical Study

测试驱动的代码评审:一项实证研究
ICSE 2019 IEEE/ACM 41st International Conference on Software Engineering (ICSE)2019匹配度 2/10 · 该论文是测试驱动代码评审的实证研究,关注代码评审效果与开发者偏好,属于软件工程/开发者工具领域;但与用户核心方向(静态分析、LLM/Agent、浮点程序分析、贝叶斯程序分析及其交叉)几乎没有直接关联。引用 35 inbox
Davide Spadini, Fabio Palomba, Tobias Baum, Stefan Hanenberg, Magiel Bruntink, Alberto Bacchelli
crossref: 2026-09-12dblp: 2026-09-12

AI 速览

一句话:通过对照实验与访谈调查,揭示测试驱动代码评审对缺陷发现与开发者偏好的影响。

论文研究 Test-Driven Code Review (TDR):评审者先检查变更的测试代码,再检查生产代码。作者结合 93 名开发者完成的 150 余次评审对照实验,以及 9 次半结构化访谈和 103 份问卷,系统考察 TDR 的效果、普及、问题与优势。实验发现,采用 TDR 的开发者发现生产代码缺陷比例相同,但发现更多测试代码缺陷,代价是生产代码可维护性问题发现更少;多数开发者仍偏好先评审生产代码,认为其更关键且测试应随之而来;测试代码质量普遍不佳和缺乏工具支持阻碍 TDR 采用。

问题
缺乏对 TDR 效果、普遍性、问题与优势的系统认识,论文欲实证理解其对代码评审有效性和开发者认知的影响。
方法
开展 93 名开发者、150 余次评审的对照实验,并进行 9 次半结构化访谈和 103 人问卷,收集开发者对 TDR 的感知。
评估
通过实验测量生产代码/测试代码缺陷发现与可维护性问题发现,结合访谈和问卷分析开发者偏好、障碍与采用情况。
原文摘要(Abstract)

Test-Driven Code Review (TDR) is a code review practice in which a reviewer inspects a patch by examining the changed test code before the changed production code. Although this practice has been mentioned positively by practitioners in informal literature and interviews, there is no systematic knowledge of its effects, prevalence, problems, and advantages. In this paper, we aim at empirically understanding whether this practice has an effect on code review effectiveness and how developers' perceive TDR. We conduct (i) a controlled experiment with 93 developers that perform more than 150 reviews, and (ii) 9 semi-structured interviews and a survey with 103 respondents to gather information on how TDR is perceived. Key results from the experiment show that developers adopting TDR find the same proportion of defects in production code, but more in test code, at the expenses of fewer maintainability issues in production code. Furthermore, we found that most developers prefer to review production code as they deem it more critical and tests should follow from it. Moreover, general poor test code quality and no tool support hinder the adoption of TDR. Public preprint: https://doi.org/10.5281/zenodo.2551217, data and materials: https://doi.org/10.5281/zenodo.2553139

链接与引用

DOI 原文 · PDF(开放获取) · DBLP

BibTeX
@inproceedings{SpadiniPBHBB19,
  title = {Test-Driven Code Review: An Empirical Study},
  author = {Davide Spadini and Fabio Palomba and Tobias Baum and Stefan Hanenberg and Magiel Bruntink and Alberto Bacchelli},
  booktitle = {ICSE},
  year = {2019},
  doi = {10.1109/icse.2019.00110}
}