ETNA: An Evaluation Platform for Property-Based Testing (Experience Report)

ETNA: An Evaluation Platform for Property-Based Testing (Experience Report)
复制标题

DOI:
10.1145/3607860
复制
发表时间:
2023-08-01
影响因子:
1.8
通讯作者:
Lampropoulos,Leonidas
Lampropoulos,Leonidas
中科院分区:
其他
文献类型:
--
作者:
Shi,Jessica;Keles,Alperen;Lampropoulos,Leonidas

文献摘要

相似文献

基于属性的测试是函数式编程的支柱,它拥有丰富的文献、热情的用户社区和丰富的工具——确实如此之多,以至于新用户可能难以选择。此外,任何给定的框架都可以支持生成测试输入的各种策略;即使是经验丰富的用户也可能想知道在特定情况下哪个更好。可悲的是,虽然关于PBT的文献有很多关于创造力的内容,但却缺乏严谨的比较来帮助回答这些问题。我们提出了Etna,一个经验评估和比较PBT技术的平台。Etna从文献中整合了许多流行的PBT框架和测试工作负载,其可扩展的体系结构使添加新框架变得容易,同时处理了性能测量的技术工作。为了说明它的好处,我们使用Etna在Coq和Haskell中使用流行的PBT方法进行了几个实验,让用户更清楚地了解最佳实践和权衡。
Property-based testing is a mainstay of functional programming, boasting a rich literature, an enthusiastic user community, and an abundance of tools — so many, indeed, that new users may have difficulty choosing. Moreover, any given framework may support a variety of strategies for generating test inputs; even experienced users may wonder which are better in a given situation. Sadly, the PBT literature, though long on creativity, is short on rigorous comparisons to help answer such questions.We present Etna, a platform for empirical evaluation and comparison of PBT techniques. Etna incorporates a number of popular PBT frameworks and testing workloads from the literature, and its extensible architecture makes adding new ones easy, while handling the technical drudgery of performance measurement. To illustrate its benefits, we use Etna to carry out several experiments with popular PBT approaches in both Coq and Haskell, allowing users to more clearly understand best practices and tradeoffs.