IABC-TCG: Improved artificial bee colony algorithm-based test case generation for smart contracts

IF 1.7 4区 计算机科学 Q3 COMPUTER SCIENCE, SOFTWARE ENGINEERING Journal of Software-Evolution and Process Pub Date : 2024-08-08 DOI:10.1002/smr.2719
Shunhui Ji, Jiahao Gong, Hai Dong, Pengcheng Zhang, Shaoqing Zhu
{"title":"IABC-TCG: Improved artificial bee colony algorithm-based test case generation for smart contracts","authors":"Shunhui Ji,&nbsp;Jiahao Gong,&nbsp;Hai Dong,&nbsp;Pengcheng Zhang,&nbsp;Shaoqing Zhu","doi":"10.1002/smr.2719","DOIUrl":null,"url":null,"abstract":"<p>With the widespread application of smart contracts, there is a growing concern over the quality assurance of smart contracts. The data flow testing is an important technology to ensure the correctness of smart contracts. We propose an approach named IABC-TCG (Improved Artificial Bee Colony-Test Case Generation) to generate test cases for the data flow testing of smart contracts. With a dominance relations-based fitness function, an improved artificial bee colony algorithm is used to generate test cases, in which the bee colony search coefficient is adaptively adjusted to improve the effectiveness and efficiency of the search. In addition, an improved test case selection and updation strategy is used to avoid unnecessary test cases. The experimental results show that IABC-TCG achieves 100% coverage for all the test requirements on a dataset of 30 smart contracts and outperforms the baseline approaches in terms of the number of test cases and the execution time. Performing tests with the generated test cases, IABC-TCG can find more errors with less test cost.</p>","PeriodicalId":48898,"journal":{"name":"Journal of Software-Evolution and Process","volume":"36 12","pages":""},"PeriodicalIF":1.7000,"publicationDate":"2024-08-08","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Journal of Software-Evolution and Process","FirstCategoryId":"94","ListUrlMain":"https://onlinelibrary.wiley.com/doi/10.1002/smr.2719","RegionNum":4,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"Q3","JCRName":"COMPUTER SCIENCE, SOFTWARE ENGINEERING","Score":null,"Total":0}
引用次数: 0

Abstract

With the widespread application of smart contracts, there is a growing concern over the quality assurance of smart contracts. The data flow testing is an important technology to ensure the correctness of smart contracts. We propose an approach named IABC-TCG (Improved Artificial Bee Colony-Test Case Generation) to generate test cases for the data flow testing of smart contracts. With a dominance relations-based fitness function, an improved artificial bee colony algorithm is used to generate test cases, in which the bee colony search coefficient is adaptively adjusted to improve the effectiveness and efficiency of the search. In addition, an improved test case selection and updation strategy is used to avoid unnecessary test cases. The experimental results show that IABC-TCG achieves 100% coverage for all the test requirements on a dataset of 30 smart contracts and outperforms the baseline approaches in terms of the number of test cases and the execution time. Performing tests with the generated test cases, IABC-TCG can find more errors with less test cost.

查看原文
分享 分享
微信好友 朋友圈 QQ好友 复制链接
本刊更多论文
IABC-TCG:基于人工蜂群算法的智能合约测试用例生成改进版
随着智能合约的广泛应用,人们越来越关注智能合约的质量保证。数据流测试是确保智能合约正确性的一项重要技术。我们提出了一种名为IABC-TCG(改进人工蜂群-测试用例生成)的方法来生成智能合约数据流测试用例。通过基于支配关系的适配函数,使用改进的人工蜂群算法生成测试用例,其中蜂群搜索系数可进行自适应调整,以提高搜索的有效性和效率。此外,还采用了改进的测试用例选择和更新策略,以避免不必要的测试用例。实验结果表明,IABC-TCG 在 30 个智能合约的数据集上实现了所有测试要求的 100% 覆盖率,并在测试用例数量和执行时间方面优于基线方法。在使用生成的测试用例进行测试时,IABC-TCG 能以更低的测试成本发现更多错误。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 去求助
来源期刊
Journal of Software-Evolution and Process
Journal of Software-Evolution and Process COMPUTER SCIENCE, SOFTWARE ENGINEERING-
自引率
10.00%
发文量
109
期刊最新文献
Issue Information Issue Information Issue Information A hybrid‐ensemble model for software defect prediction for balanced and imbalanced datasets using AI‐based techniques with feature preservation: SMERKP‐XGB Issue Information
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
现在去查看 取消
×
提示
确定
0
微信
客服QQ
Book学术公众号 扫码关注我们
反馈
×
意见反馈
请填写您的意见或建议
请填写您的手机或邮箱
已复制链接
已复制链接
快去分享给好友吧!
我知道了
×
扫码分享
扫码分享
Book学术官方微信
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术
文献互助 智能选刊 最新文献 互助须知 联系我们:info@booksci.cn
Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。
Copyright © 2023 Book学术 All rights reserved.
ghs 京公网安备 11010802042870号 京ICP备2023020795号-1