arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2103.07010cs.SE
收藏

结合动态分析和可视化探索单元测试集的分布

Combining Dynamic Analysis and Visualization to Explore the Distribution of Unit Test Suites

Amjed Tahir, Stephen G. MacDonell

摘要:

随着软件系统的规模和复杂性的增长,与这些系统一起构建的测试套件也变得越来越复杂。在维护或重新设计系统时,理解测试套件的关键方面(例如它们对生产代码的覆盖率)是很重要的。本文通过对动态和静态分析得到的数据进行可视化,研究了开源软件系统中单元测试的分布情况。我们的长期目标是支持开发人员理解测试分布以及测试与生产代码的关系。我们首先从五个选定的OSS系统获得动态耦合信息,然后映射测试和生产代码的结果。映射以图表的形式显示,这些图表描述了类之间的依赖关系和静态测试信息。我们分析这些图使用来自图论和SNA的中心性度量。我们的研究结果表明,至少对于这五个系统,单元测试和动态耦合信息“不匹配”,因为单元测试似乎不符合系统的动态耦合分布。我们主张,通过映射到单元测试信息的动态耦合数据,并通过使用软件度量和可视化,我们可以找到中央系统类,并确定类单元测试的努力(或没有)专用。

英文摘要:

As software systems have grown in scale and complexity the test suites built alongside those systems have also become increasingly complex. Understanding key aspects of test suites, such as their coverage of production code, is important when maintaining or reengineering systems. This work investigates the distribution of unit tests in Open Source Software (OSS) systems through the visualization of data obtained from both dynamic and static analysis. Our long-term aim is to support developers in their understanding of test distribution and the relationship of tests to production code. We first obtain dynamic coupling information from five selected OSS systems and we then map the test and production code results. The mapping is shown in graphs that depict both the dependencies between classes and static test information. We analyze these graphs using Centrality metrics derived from graph theory and SNA. Our findings suggest that, for these five systems at least, unit test and dynamic coupling information 'do not match', in that unit tests do not appear to be distributed in line with the systems' dynamic coupling. We contend that, by mapping dynamic coupling data onto unit test information, and through the use of software metrics and visualization, we can locate central system classes and identify to which classes unit testing effort has (or has not) been dedicated.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑