In recent years, software engineers have explored ways to assist quantum software programmers. Our goal in this paper is to continue this exploration and see if quantum software programmers deal with some problems plaguing classical programs. Specifically, we examine whether intermittently failing tests, i.e., flaky tests, affect quantum software development. To explore flakiness, we conduct a preliminary analysis of 14 quantum software repositories. Then, we identify flaky tests and categorize their causes and methods of fixing them. We found flaky tests in 12 out of 14 quantum software repositories. In these 12 repositories, the lower boundary of the percentage of flaky tests ranges between 0.26% and 1.85% per repository. We identified 38 distinct flaky tests with 10 groups of causes and 7 common solutions. Further, we notice that quantum programmers are not using some of the recent flaky test countermeasures developed by software engineers. This work may interest practitioners, as it provides useful insight into the resolution of flaky tests in quantum programs. Researchers may also find the paper helpful as it offers quantitative data on flaky tests in quantum software and points to new research opportunities.
翻译:近年来,软件工程师已开始探索辅助量子软件程序员的方法。本文旨在延续这一探索,考察量子软件程序员是否面临困扰经典程序的某些问题,具体研究间歇性失败的测试(即不稳定测试)是否影响量子软件开发。为探究不稳定性,我们对14个量子软件仓库进行了初步分析,识别出不稳定测试并对其成因与修复方法进行分类。研究发现,12个量子软件仓库中存在不稳定测试,各仓库中不稳定测试占比的下界介于0.26%至1.85%之间。我们识别出38个不同的不稳定测试,涵盖10类成因与7种常见解决方案。此外,我们注意到量子程序员未采用部分软件工程师近期开发的不稳定测试应对措施。本研究为实践者提供了解决量子程序中不稳定测试的有益见解,同时向研究者提供了量子软件中不稳定测试的定量数据及新的研究机遇。