The unit testing of Deep Learning (DL) libraries is challenging due to complex numerical semantics and implicit tensor constraints. Traditional Search-Based Software Testing (SBST) often suffers from semantic blindness, failing to satisfy the constraints of high-dimensional tensors, whereas Large Language Models (LLMs) struggle with cross-file context and unstable code modifications. This paper proposes ATTest, an agent-driven tensor testing framework for module-level unit test generation. ATTest orchestrates a seven-stage pipeline, which encompasses constraint extraction and an iterative "generation-validation-repair" loop, to maintain testing stability and mitigate context-window saturation. An evaluation on PyTorch and TensorFlow demonstrates that ATTest significantly outperforms state-of-the-art baselines such as PynguinML, achieving an average branch coverage of 55.60% and 54.77%, respectively. The results illustrate how agent-driven workflows bridge the semantic gap in numerical libraries while ensuring auditable test synthesis. Source code: https://github.com/iSEngLab/ATTest.git
Deep Learning Library Testing: Definition, Methods and Challenges
School of Cyber Science and Engineering, Xi’an Jiaotong University(西安交通大学网络空间安全学院);Institute for Network Sciences and Cyberspace, Tsinghua University(清华大学网络科学与网络空间研究院);School of Cyber Science and Engineering, Wuhan University(武汉大学网络空间安全学院)
QSPE: Enumerating Skeletal Quantum Programs for Quantum Library Testing
Manufacturing Industry Chain Collaboration Industrial Software Key Laboratory of Sichuan Province(四川省制造业产业链协同工业软件重点实验室);Southwest Jiaotong University(西南交通大学);State Key Laboratory of Blockchain and Data Security(区块链与数据安全国家重点实验室);Zhejiang University(浙江大学);Kyushu University(九州大学);University of Luxembourg(卢森堡大学);Institute of AI for Industries(产业人工智能研究院)
COMET: Coverage-guided Model Generation For Deep Learning Library Testing
The Hong Kong University of Science and Technology(香港科技大学);Guangzhou HKUST Fok Ying Tung Research Institute(广州香港科技大学霍英东研究院);University of Waterloo(滑铁卢大学);Huazhong University of Science and Technology(华中科技大学)
针对现有 DL 模型生成技术层 API 覆盖不足的问题,本文提出 COMET,利用变异算子、覆盖引导搜索与模型综合提升测试多样性,并在八个 DL 库中发现 32 个新缺陷。