论文标题
Kaya:基于区块链的分散应用程序的测试框架
Kaya: A Testing Framework for Blockchain-based Decentralized Applications
论文作者
论文摘要
近年来,已经开发了许多基于区块链(DAPP)的分散应用程序。但是,由于测试不足,DAPP很容易暴露于严重的脆弱性。我们发现DAPP测试的三个主要挑战,即DAPP的固有复杂性,不便的预状态设置以及不太可读的日志。在本文中,我们提出了一个名为Kaya的测试框架来弥合这些差距。 Kaya具有三个主要功能。首先,Kaya提出了DAPP行为描述语言(DBDL),以使写作测试用例更加容易。用DBDL编写的测试用例也可以由Kaya自动执行。其次,Kaya为测试工程师轻松设置区块链预状态的灵活而便捷的方式。第三,Kaya将难以理解的地址转换为可读的变量,以方便理解。借助这些功能,Kaya可以帮助测试工程师更轻松地测试DAPP。此外,为了适合各种应用程序环境,我们为测试工程师提供了两种方法,即使用Kaya,即UI和命令行。我们的实验案例证明了Kaya在帮助测试工程师更容易测试DAPP方面的潜力。
In recent years, many decentralized applications based on blockchain (DApp) have been developed. However, due to inadequate testing, DApps are easily exposed to serious vulnerabilities. We find three main challenges for DApp testing, i.e., the inherent complexity of DApp, inconvenient pre-state setting, and not-so-readable logs. In this paper, we propose a testing framework named Kaya to bridge these gaps. Kaya has three main functions. Firstly, Kaya proposes DApp behavior description language (DBDL) to make writing test cases easier. Test cases written in DBDL can also be automatically executed by Kaya. Secondly, Kaya supports a flexible and convenient way for test engineers to set the blockchain pre-states easily. Thirdly, Kaya transforms incomprehensible addresses into readable variables for easy comprehension. With these functions, Kaya can help test engineers test DApps more easily. Besides, to fit the various application environments, we provide two ways for test engineers to use Kaya, i.e., UI and command-line. Our experimental case demonstrates the potential of Kaya in helping test engineers to test DApps more easily.