paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Data-Oriented Differential Testing of Object-Relational Mapping Systems

面向数据的对象关系映射系统差分测试
ICSE 2021 IEEE/ACM 43rd International Conference on Software Engineering (ICSE)2021匹配度 2/10 · 该论文属于软件测试/差分测试与约束求解方向,针对ORM系统缺陷检测,与用户关注的静态分析、LLM/Agentic程序分析、浮点程序分析及贝叶斯程序分析均无直接关联。虽然使用了求解器生成测试数据,但整体研究方向不匹配。引用 21 inbox
Thodoris Sotiropoulos, Stefanos Chaliasos, Vaggelis Atlidakis, Dimitris Mitropoulos, Diomidis Spinellis
crossref: 2026-09-12dblp: 2026-09-12

AI 速览

一句话:首个系统化测试ORM系统的方法,结合差分测试与求解器生成数据,发现28个真实缺陷。

对象关系映射(ORM)系统负责在对象程序与关系数据库之间转换,但其实现常含有特定缺陷,此前缺乏系统化测试方法。本文提出首个针对ORM的系统化测试方法,利用差分测试建立测试预言:随机生成关系数据库模式并建立数据库,再通过被测ORM的API查询这些数据库。为解决ORM缺乏统一输入语言的问题,作者生成抽象查询语言查询,再将其翻译为具体可执行的ORM查询进行差分比较。由于测试效果依赖底层数据库中的数据,作者采用基于求解器的方法,按生成查询的约束产生有针对性的数据库记录。该工作实现为工具CYNTHIA,在五个流行ORM系统中发现28个缺陷;其中25个被确认,20个已修复,3个被开发者标记为发布阻塞缺陷。

问题
ORM系统缺乏系统化的测试方法,难以发现其对象-关系映射与查询实现中的特定缺陷。
方法
随机生成关系数据库模式并建立数据库,以抽象查询语言生成查询后翻译为具体ORM查询,通过差分测试比较被测系统行为;并用求解器按查询约束生成目标数据库记录。
评估
实现工具CYNTHIA,在五个流行ORM系统上评估。共发现28个缺陷,其中25个被确认,20个已修复,3个被标记为发布阻塞缺陷。
原文摘要(Abstract)

We introduce, what is to the best of our knowledge, the first approach for systematically testing Object-Relational Mapping (ORM) systems. Our approach leverages differential testing to establish a test oracle for ORM-specific bugs. Specifically, we first generate random relational database schemas, set up the respective databases, and then, we query these databases using the APIs of the ORM systems under test. To tackle the challenge that ORMs lack a common input language, we generate queries written in an abstract query language. These abstract queries are translated into concrete, executable ORM queries, which are ultimately used to differentially test the correctness of target implementations. The effectiveness of our method heavily relies on the data inserted to the underlying databases. Therefore, we employ a solver-based approach for producing targeted database records with respect to the constraints of the generated queries. We implement our approach as a tool, called CYNTHIA, which found 28 bugs in five popular ORM systems. The vast majority of these bugs are confirmed (25 / 28), more than half were fixed (20 / 28), and three were marked as release blockers by the corresponding developers.

链接与引用

DOI 原文 · DBLP

BibTeX
@inproceedings{SotiropoulosCAM21,
  title = {Data-Oriented Differential Testing of Object-Relational Mapping Systems},
  author = {Thodoris Sotiropoulos and Stefanos Chaliasos and Vaggelis Atlidakis and Dimitris Mitropoulos and Diomidis Spinellis},
  booktitle = {ICSE},
  year = {2021},
  doi = {10.1109/icse43902.2021.00137}
}