With the increased developments in quantum computing, the availability of systematic and automatic testing approaches for quantum programs is becoming increasingly essential. To this end, we present the quantum software testing tool QuCAT for combinatorial testing of quantum programs. QuCAT provides two functionalities of use. With the first functionality, the tool generates a test suite of a given strength (e.g., pair-wise). With the second functionality, it generates test suites with increasing strength until a failure is triggered or a maximum strength is reached. QuCAT uses two test oracles to check the correctness of test outputs. We assess the cost and effectiveness of QuCAT with 3 faulty versions of 5 quantum programs. Results show that combinatorial test suites with a low strength can find faults with limited cost, while a higher strength performs better to trigger some difficult faults with relatively higher cost. Repository: https://github.com/Simula-COMPLEX/qucat-tool Video: https://youtu.be/UsqgOudKLio
翻译:随着量子计算领域的快速发展,针对量子程序的系统性自动化测试方法变得日益重要。为此,我们提出量子软件测试工具QuCAT,用于对量子程序进行组合测试。QuCAT提供两种实用功能:第一种功能可生成指定覆盖强度(如成对覆盖)的测试套件;第二种功能则逐步生成覆盖强度递增的测试套件,直至触发程序失效或达到最大覆盖强度。该工具采用两种测试预言机验证测试输出的正确性。我们通过5个量子程序的3个错误版本对QuCAT的成本与有效性进行评估。结果表明,低覆盖强度的组合测试套件能以较低成本发现缺陷,而高覆盖强度虽成本相对较高,但能更有效地触发某些难以检测的缺陷。代码仓库:https://github.com/Simula-COMPLEX/qucat-tool 演示视频:https://youtu.be/UsqgOudKLio