Open Access Article

Title: Mining constant information for readable test data generation

Authors: Mingzhe Zhang; Yunzhan Gong; Yawen Wang; Dahai Jin

Addresses: State Key Laboratory of Networking and Switching Technology, Beijing University of Posts and Telecommunications, Beijing 100876, China ' State Key Laboratory of Networking and Switching Technology, Beijing University of Posts and Telecommunications, Beijing 100876, China ' State Key Laboratory of Networking and Switching Technology, Beijing University of Posts and Telecommunications, Beijing 100876, China ' State Key Laboratory of Networking and Switching Technology, Beijing University of Posts and Telecommunications, Beijing 100876, China

Abstract: Automated test data generation tools produce test data that can achieve high coverage faster than test data generated manually by a tester. However, the test data generated by automated tools has been shown to not help developers find more bugs. The main reason is that it is difficult for human testers to understand and evaluate the test data. In this paper, an approach is introduced to automatically generate readable test data, which has been implemented in a tool called CTS. CTS can mine constant information from projects under testing and obtain heuristic information by aggregating and rating related constants. CTS adds heuristic information to the automatic test data generation process to generate test data that is quick and easy for a human to comprehend and check. Empirical experiments show that the proposed approach can improve the efficiency of test data generation and generate test data that is more convenient for a human oracle.

Keywords: test data generation; readable test data; constraint-based testing; CBT; symbolic execution.

DOI: 10.1504/IJES.2021.112002

International Journal of Embedded Systems, 2021 Vol.14 No.1, pp.9 - 18

Received: 24 Jan 2020
Accepted: 23 May 2020

Published online: 22 Dec 2020 *