Title
Towards automated testing of blockchain-based decentralized applications
Abstract
Blockchain-based decentralized applications (DApp) have been widely adopted in different areas and trusted by more and more users due to the fact that the back end code of a DApp is publicly run on the blockchain and cannot be modified implicitly. However, there are few effective methods and tools for testing DApps and bugs can be easily introduced by inexperienced developers. The existing testing techniques either focus on testing front-end programs or back-end code but ignore the interaction between them, which makes it difficult to apply the techniques directly on DApp. In this paper, we present an automated testing technique for DApps which works in a two-phase manner. First, we employ random events to infer an abstract relation between browser-side events and blockchain-side contracts. Second, our technique generates a set of test cases under the guidance of inferred relations and orders the test cases based on a read-write graph. We also use taint analysis to track data flow of the smart contract and feed it to the generation procedure for following test cases. We have developed a tool called Sungari to implement our approach, and evaluated it on representative real-world DApps. The preliminary evaluation results demonstrated the potential of Sungari in achieving a significant optimization compared to random testing approaches.
Year
DOI
Venue
2019
10.1109/ICPC.2019.00048
Proceedings of the 27th International Conference on Program Comprehension
Keywords
Field
DocType
blockchain, decentralized application, dynamic testing, smart contract
Data mining,Graph,Random testing,Computer science,Dynamic testing,Taint checking,Blockchain,Test case,Data flow diagram,Smart contract
Conference
ISSN
ISBN
Citations 
2643-7147
978-1-7281-1520-7
0
PageRank 
References 
Authors
0.34
13
8
Name
Order
Citations
PageRank
Jianbo Gao128734.63
Han Liu2698.01
Yue Li313342.96
Chao Liu400.34
Zhiqiang Yang5134.35
Qingshan Li653.89
Zhi Guan77610.75
Zhong Chen850358.35