Security Development Lifecycle-Based Adaptive Reward Mechanism for Reinforcement Learning in Continuous Integration Testing Optimization

被引:0
|
作者
Yang, Yang [1 ]
Wang, Weiwei [2 ]
Li, Zheng [3 ]
Zhang, Lieshan [1 ]
Pan, Chaoyue [3 ]
机构
[1] Zhejiang Sci Tech Univ, Sch Informat Sci & Engn, Hangzhou 310018, Zhejiang, Peoples R China
[2] Beijing Inst Petrochem Technol, Sch Informat Engn, Beijing 100095, Peoples R China
[3] Beijing Univ Chem Technol, Coll Informat Sci & Technol, Beijing 100029, Peoples R China
关键词
Continuous integration testing; reinforcement learning; test case prioritization; reward mechanism; PRIORITIZATION;
D O I
10.1142/S0218194024500244
中图分类号
TP18 [人工智能理论];
学科分类号
081104 ; 0812 ; 0835 ; 1405 ;
摘要
Continuous automated testing throughout each cycle can ensure the security of the continuous integration (CI) development lifecycle. Test case prioritization (TCP) is a critical factor in optimizing automated testing, which prioritizes potentially failed test cases and improves the efficiency of automated testing. In CI automated testing, the TCP is a continuous decision-making process that can be solved with reinforcement learning (RL). RL-based CITCP can continuously generate a TCP strategy for each CI development lifecycle, with the reward mechanism as the core. The reward mechanism consists of the reward function and the reward strategy. However, there are new challenges to RL-based CITCP in real-industry CI testing. With high-frequency iteration, the reward function is often calculated with a fixed length of historical information, ignoring the spatial characteristics of the current cycle. Therefore, the dynamic time window (DTW)-based reward function is proposed to perform the reward calculation, which adaptively adjusts the recent historical information range based on the integration cycle. Moreover, with low-failure testing, the reward strategy usually only rewards failure test cases, which creates a sparse reward problem in RL. To address this issue, the similarity-based reward strategy is proposed, which increases the reward objects of some passed test cases, similar to the failure test cases. The DTW-based reward function and the similarity-based reward strategy together constitute the proposed adaptive reward mechanism in RL-based CITCP. To validate the effectiveness of the adaptive reward mechanism, experimental verification is carried out on 13 industrial data sets. The experimental results show that the adaptive reward mechanism can improve the TCP effect, where the average NAPFD is maximally improved by 7.29%, the average Recall is maximally improved by 6.04% and the average TTF is improved by 6.81 positions with a maximum of 63.77.
引用
收藏
页码:1457 / 1483
页数:27
相关论文
共 50 条
  • [1] Adaptive Reward Computation in Reinforcement Learning-Based Continuous Integration Testing
    Yang, Yang
    Pan, Chaoyue
    Li, Zheng
    Zhao, Ruilian
    IEEE ACCESS, 2021, 9 : 36674 - 36688
  • [2] A systematic study of reward for reinforcement learning based continuous integration testing
    Yang, Yang
    Li, Zheng
    He, Liuliu
    Zhao, Ruilian
    JOURNAL OF SYSTEMS AND SOFTWARE, 2020, 170
  • [3] Sparse reward for reinforcement learning-based continuous integration testing
    Yang, Yang
    Li, Zheng
    Shang, Ying
    Li, Qianyu
    JOURNAL OF SOFTWARE-EVOLUTION AND PROCESS, 2023, 35 (06)
  • [4] Reward of Reinforcement Learning of Test Optimization for Continuous Integration
    He L.-L.
    Yang Y.
    Li Z.
    Zhao R.-L.
    Ruan Jian Xue Bao/Journal of Software, 2019, 30 (05): : 1438 - 1449
  • [5] Historical Information Stability based Reward for Reinforcement Learning in Continuous Integration Testing
    Cao, Tiange
    Li, Zheng
    Zhao, Ruilian
    Yang, Yang
    2021 IEEE 21ST INTERNATIONAL CONFERENCE ON SOFTWARE QUALITY, RELIABILITY AND SECURITY (QRS 2021), 2021, : 231 - 242
  • [6] Dynamic Time Window based Reward for Reinforcement Learning in Continuous Integration Testing
    Pan, Chaoyue
    Yang, Yang
    Li, Zheng
    Guo, Junxia
    THE 12TH ASIA-PACIFIC SYMPOSIUM ON INTERNETWARE, INTERNETWARE 2020, 2021, : 189 - 198
  • [7] Weighted Reward for Reinforcement Learning based Test Case Prioritization in Continuous Integration Testing
    Li, Guowei
    Yang, Yang
    Wu, Zhaolin
    Cao, Tiange
    Liu, Yong
    Li, Zheng
    2021 IEEE 45TH ANNUAL COMPUTERS, SOFTWARE, AND APPLICATIONS CONFERENCE (COMPSAC 2021), 2021, : 980 - 985
  • [8] A Time Window based Reinforcement Learning Reward for Test Case Prioritization in Continuous Integration
    Wu, Zhaolin
    Yang, Yang
    Li, Zheng
    Zhao, Ruilian
    11TH ASIA-PACIFIC SYMPOSIUM ON INTERNETWARE (INTERNETWARE 2019), 2019,
  • [9] Focus on New Test Cases in Continuous Integration Testing based on Reinforcement Learning
    Chen, Fanliang
    Li, Zheng
    Shang, Ying
    Yang, Yang
    2022 IEEE 22ND INTERNATIONAL CONFERENCE ON SOFTWARE QUALITY, RELIABILITY AND SECURITY, QRS, 2022, : 830 - 841
  • [10] STAN: Stage-Adaptive Network for Multi-Task Recommendation by Learning User Lifecycle-Based Representation
    Li, Wanda
    Zheng, Wenhao
    Xiao, Xuanji
    Wang, Suhang
    PROCEEDINGS OF THE 17TH ACM CONFERENCE ON RECOMMENDER SYSTEMS, RECSYS 2023, 2023, : 602 - 612