Hansei: property-based development of concurrent systems

Joseph Blomstedt
{"title":"Hansei: property-based development of concurrent systems","authors":"Joseph Blomstedt","doi":"10.1145/2364489.2364505","DOIUrl":null,"url":null,"abstract":"Avoiding concurrency errors remains one of the main challenges in day-to-day Erlang development. Errors can arise both from unexpected process and message interleaving, as well as concurrent clients or users interacting with the system in an unanticipated manner. To address this issue, many testing tools have been developed over the years. One approach is to pair a property-based testing tool with a tool that overrides the Erlang scheduler. This allows developers to focus on defining the properties of their system, and let the testing tools worry about testing these properties across different interleavings.\n This paper builds upon this approach and presents the Hansei testing framework. Hansei provides an approach to writing property-based tests that build on standard OTP abstractions, as well as a testing infrastructure designed to support test-driven development of concurrent systems. The Hansei infrastructure builds on the existing QuickCheck property-based testing tool, and supports both built-in message interleaving as well as a testing mode that works with existing process interleaving tools. Existing tools are more mature and feature-complete, while the built-in Hansei support has the unique property of being able to operate on code that spans multiple Erlang VMs.","PeriodicalId":140676,"journal":{"name":"Erlang Workshop","volume":"185 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2012-09-14","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Erlang Workshop","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/2364489.2364505","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 0

Abstract

Avoiding concurrency errors remains one of the main challenges in day-to-day Erlang development. Errors can arise both from unexpected process and message interleaving, as well as concurrent clients or users interacting with the system in an unanticipated manner. To address this issue, many testing tools have been developed over the years. One approach is to pair a property-based testing tool with a tool that overrides the Erlang scheduler. This allows developers to focus on defining the properties of their system, and let the testing tools worry about testing these properties across different interleavings. This paper builds upon this approach and presents the Hansei testing framework. Hansei provides an approach to writing property-based tests that build on standard OTP abstractions, as well as a testing infrastructure designed to support test-driven development of concurrent systems. The Hansei infrastructure builds on the existing QuickCheck property-based testing tool, and supports both built-in message interleaving as well as a testing mode that works with existing process interleaving tools. Existing tools are more mature and feature-complete, while the built-in Hansei support has the unique property of being able to operate on code that spans multiple Erlang VMs.
Hansei:基于属性的并发系统开发
避免并发错误仍然是日常Erlang开发中的主要挑战之一。错误可能来自意外的流程和消息交错,以及并发客户端或用户以意外的方式与系统交互。为了解决这个问题,多年来开发了许多测试工具。一种方法是将基于属性的测试工具与覆盖Erlang调度器的工具配对。这允许开发人员专注于定义他们系统的属性,而让测试工具担心跨不同的交叉测试这些属性。本文以这种方法为基础,提出了Hansei测试框架。Hansei提供了一种方法来编写基于标准OTP抽象的基于属性的测试,以及设计用于支持并发系统的测试驱动开发的测试基础设施。Hansei的基础架构建立在现有的QuickCheck基于属性的测试工具之上,支持内置的消息交错以及与现有流程交错工具一起工作的测试模式。现有的工具更加成熟和功能齐全,而内置的Hansei支持具有能够在跨多个Erlang vm的代码上操作的独特属性。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 求助全文
来源期刊
自引率
0.00%
发文量
0
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
确定
请完成安全验证×
copy
已复制链接
快去分享给好友吧!
我知道了
右上角分享
点击右上角分享
0
联系我们:info@booksci.cn Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。 Copyright © 2023 布克学术 All rights reserved.
京ICP备2023020795号-1
ghs 京公网安备 11010802042870号
Book学术文献互助
Book学术文献互助群
群 号:604180095
Book学术官方微信