There are many widely used tools for measuring test-coverage and code-coverage. Test coverage is the ratio of requirements or other non-code artifacts covered by a test suite, while code-coverage is the ratio of source code covered by tests. Almost all coverage tools show a few certain subset of coverage values, and almost always either test-coverage or code-coverage measures. In a large-scale industrial web-application-testing setting, we were faced with the need to "integrate" several types of coverage data (including front-end and back-end code coverage with requirements coverage), and to see all of them "live" as large model-based test suites were running. By being unable to find any off-the-shelf toolset to address the above need, we have developed an open-source test coverage tool, specific for MBT, named MBTCover. In addition to code coverage, the tool measures and reports requirements and model coverage, "live" as a given MBT test suite is executing. In this paper, we present the features of the MBTCover tool and our experience from using it in multiple large test-automation projects in practice. Other software test engineers, who conduct web application testing and MBT, may find the tool useful in their projects.
翻译:目前存在许多广泛使用的测试覆盖率和代码覆盖率度量工具。测试覆盖率指测试套件覆盖需求或其他非代码制品的比例,而代码覆盖率则指测试覆盖源代码的比例。几乎所有覆盖率工具都仅展示特定子集的覆盖率数值,且通常只度量测试覆盖率或代码覆盖率中的一种。在大型工业级Web应用测试场景中,我们面临着需要"整合"多种类型覆盖率数据(包括前后端代码覆盖率与需求覆盖率)的需求,并期望在大型基于模型的测试套件运行时能"实时"查看所有数据。由于未能找到满足上述需求的现成工具集,我们开发了一款专用于MBT的开源测试覆盖率工具——MBTCover。该工具除了代码覆盖率外,还能在给定MBT测试套件执行过程中"实时"度量并报告需求覆盖率和模型覆盖率。本文介绍了MBTCover工具的功能特性,以及我们在多个大型测试自动化实践项目中应用该工具的经验。其他从事Web应用测试和MBT的软件测试工程师可能会发现该工具在其项目中具有实用价值。