ABSTRACT
Continuous Integration (CI) testing is an expensive, time-consuming, and resource-intensive process. Test case prioritization (TCP) can effectively reduce the workload of regression testing in the CI environment, where Reinforcement Learning (RL) is adopted to prioritize test cases, since the TCP in CI testing can be formulated as a sequential decision-making problem, which can be solved by RL effectively. A useful reward function is a crucial component in the construction of the CI system and a critical factor in determining RL’s learning performance in CI testing. This paper focused on the validity of the execution history information of the test cases on the TCP performance in the existing CI testing optimization methods based on RL, and a Dynamic Time Window based reward function are proposed by using partial information dynamically for fast feedback and cost reduction. Experimental studies are carried out on six industrial datasets. The experimental results showed that using dynamic time window based reward function can significantly improve the learning efficiency of RL and the fault detection ability when comparing with the reward function based on fixed time window.
- Moritz Beller, Georgios Gousios, and Andy Zaidman. 2017. Travistorrent: Synthesizing travis ci and github for full-stack research on continuous integration. In 2017 IEEE/ACM 14th International Conference on Mining Software Repositories (MSR). IEEE, 447–450.Google ScholarDigital Library
- Yi Bian, Zheng Li, Ruilian Zhao, and Dunwei Gong. 2017. Epistasis based aco for regression test case prioritization. IEEE Transactions on Emerging Topics in Computational Intelligence 1, 3(2017), 213–223.Google ScholarCross Ref
- Benjamin Busjaeger and Tao Xie. 2016. Learning for Test Prioritization: An Industrial Case Study. In Proceedings of the 2016 24th ACM SIGSOFT International Symposium on Foundations of Software Engineering(Seattle, WA, USA) (FSE 2016). Association for Computing Machinery, New York, NY, USA, 975–980. https://doi.org/10.1145/2950290.2983954Google ScholarDigital Library
- Benjamin Busjaeger and Tao Xie. 2016. Learning for test prioritization: an industrial case study. In Proceedings of the 2016 24th ACM SIGSOFT International Symposium on Foundations of Software Engineering. 975–980.Google ScholarDigital Library
- Songyu Chen, Zhenyu Chen, Zhihong Zhao, Baowen Xu, and Yang Feng. 2011. Using semi-supervised clustering to improve regression test selection techniques. In 2011 Fourth IEEE International Conference on Software Testing, Verification and Validation. 1–10.Google ScholarDigital Library
- Jianlei Chi, Yu Qu, Qinghua Zheng, Zijiang Yang, Wuxia Jin, Di Cui, and Ting Liu. 2020. Relation-based test case prioritization for regression testing. Journal of Systems and Software 163 (2020), 110539.Google ScholarCross Ref
- Younghwan Cho, Jeongho Kim, and Eunseok Lee. 2016. History-based test case prioritization for failure information. In 2016 23rd Asia-Pacific Software Engineering Conference (APSEC). IEEE, 385–388.Google ScholarCross Ref
- Fujin Deng, Ming Jin, Chengkai Liu, Marco Liserre, and Wu Chen. 2020. Switch Open-Circuit Fault Localization Strategy for MMCs Using Sliding-Time Window Based Features Extraction Algorithm. IEEE Transactions on Industrial Electronics(2020).Google ScholarCross Ref
- Hyunsook Do, Siavash Mirarab, Ladan Tahvildari, and Gregg Rothermel. 2010. The effects of time constraints on test case prioritization: A series of controlled experiments. IEEE Transactions on Software Engineering 36, 5 (2010), 593–617.Google ScholarDigital Library
- Paul M Duvall, Steve Matyas, and Andrew Glover. 2007. Continuous integration: improving software quality and reducing risk. Pearson Education.Google Scholar
- Sebastian Elbaum, Gregg Rothermel, and John Penix. 2014. Techniques for improving regression testing in continuous integration development environments. In Proceedings of the 22nd ACM SIGSOFT International Symposium on Foundations of Software Engineering. 235–245.Google ScholarDigital Library
- Alireza Haghighatkhah, Mika Mäntylä, Markku Oivo, and Pasi Kuvaja. 2018. Test prioritization in continuous integration environments. Journal of Systems and Software 146 (2018), 80–98.Google ScholarCross Ref
- Dan Hao, Lingming Zhang, Lu Zhang, Gregg Rothermel, and Hong Mei. 2014. A unified test case prioritization approach. ACM Transactions on Software Engineering and Methodology (TOSEM) 24, 2(2014), 1–31.Google ScholarDigital Library
- Hosney Jahan, Ziliang Feng, SM Mahmud, and Penglin Dong. 2019. Version specific test case prioritization approach based on artificial neural network. Journal of Intelligent & Fuzzy Systems 36, 6 (2019), 6181–6194.Google ScholarDigital Library
- Jeongho Kim, Hohyeon Jeong, and Eunseok Lee. 2017. Failure history data-based test case prioritization for effective regression test. In Proceedings of the Symposium on Applied Computing. 1409–1415.Google ScholarDigital Library
- Jingjing Liang, Sebastian Elbaum, and Gregg Rothermel. 2018. Redefining prioritization: continuous prioritization for continuous integration. In Proceedings of the 40th International Conference on Software Engineering. 688–698.Google ScholarDigital Library
- Zheng. Li LiuLiu He, Yang Yang and Ruilian Zhao. 2019. The Reward of Reinforcement learning for Test Optimization for Continuous Integration. Journal of Software, 2019, 30(5): 1438-1449(in Chinese) (2019). http://www.jos.org.cn/1000-9825/5714.htmGoogle Scholar
- Congcong Ma, Wenfeng Li, Jingjing Cao, Juan Du, Qimeng Li, and Raffaele Gravina. 2020. Adaptive sliding window based activity recognition for assisted livings. Information Fusion 53(2020), 55–65.Google ScholarDigital Library
- Mostafa Mahdieh, Seyed-Hassan Mirian-Hosseinabadi, Khashayar Etemadi, Ali Nosrati, and Sajad Jalali. 2020. Incorporating fault-proneness estimations into coverage-based test case prioritization methods. Information and Software Technology 121 (2020), 106269.Google ScholarDigital Library
- Dusica Marijan, Arnaud Gotlieb, and Sagar Sen. 2013. Test case prioritization for continuous regression testing: An industrial case study. In 2013 IEEE International Conference on Software Maintenance. IEEE, 540–543.Google ScholarDigital Library
- Dusica Marijan and Marius Liaaen. 2016. Effect of time window on the performance of continuous regression testing. In 2016 IEEE International Conference on Software Maintenance and Evolution (ICSME). IEEE, 568–571.Google ScholarCross Ref
- Tim Miller 2012. Using dependency structures for prioritization of functional test suites. IEEE transactions on software engineering 39, 2 (2012), 258–275.Google Scholar
- Ali Parsai, Quinten David Soetens, Alessandro Murgia, and Serge Demeyer. 2014. Considering polymorphism in change-based test suite reduction. In International Conference on Agile Software Development. Springer, 166–181.Google ScholarCross Ref
- Pilar Rodríguez, Alireza Haghighatkhah, Lucy Ellen Lwakatare, Susanna Teppola, Tanja Suomalainen, Juho Eskeli, Teemu Karvonen, Pasi Kuvaja, June M Verner, and Markku Oivo. 2017. Continuous deployment of software intensive products and services: A systematic mapping study. Journal of Systems and Software 123 (2017), 263–291.Google ScholarCross Ref
- Gregg Rothermel and Mary Jean Harrold. 1997. A safe, efficient regression test selection technique. ACM Transactions on Software Engineering and Methodology (TOSEM) 6, 2(1997), 173–210.Google ScholarDigital Library
- Gregg Rothermel, Roland H. Untch, Chengyun Chu, and Mary Jean Harrold. 2001. Prioritizing test cases for regression testing. IEEE Transactions on software engineering 27, 10 (2001), 929–948.Google ScholarDigital Library
- Saijun Shao, Gangyan Xu, Ming Li, and George Q Huang. 2019. Synchronizing e-commerce city logistics with sliding time windows. Transportation Research Part E: Logistics and Transportation Review 123 (2019), 17–28.Google ScholarCross Ref
- August Shi, Suresh Thummalapenta, Shuvendu K Lahiri, Nikolaj Bjorner, and Jacek Czerwonka. 2017. Optimizing test placement for module-level regression testing. In 2017 IEEE/ACM 39th International Conference on Software Engineering (ICSE). IEEE, 689–699.Google ScholarDigital Library
- Quinten David Soetens, Serge Demeyer, and Andy Zaidman. 2013. Change-based test selection in the presence of developer tests. In 2013 17th European Conference on Software Maintenance and Reengineering. IEEE, 101–110.Google ScholarDigital Library
- Helge Spieker, Arnaud Gotlieb, Dusica Marijan, and Morten Mossige. 2018. Reinforcement learning for automatic test case prioritization and selection in continuous integration. arXiv preprint arXiv:1811.04122(2018).Google Scholar
- Hema Srikanth, Charitha Hettiarachchi, and Hyunsook Do. 2016. Requirements based test prioritization using risk factors: An industrial study. Information and Software Technology 69 (2016), 71–83.Google ScholarDigital Library
- Bogdan Vasilescu, Yue Yu, Huaimin Wang, Premkumar Devanbu, and Vladimir Filkov. 2015. Quality and productivity outcomes relating to continuous integration in GitHub. In Proceedings of the 2015 10th Joint Meeting on Foundations of Software Engineering. 805–816.Google ScholarDigital Library
- W Eric Wong, Joseph R Horgan, Saul London, and Hiralal Agrawal. 1997. A study of effective regression testing in practice. In PROCEEDINGS The Eighth International Symposium On Software Reliability Engineering. IEEE, 264–274.Google ScholarCross Ref
- Zhaolin Wu, Yang Yang, Zheng Li, and Ruilian Zhao. 2019. A Time Window based Reinforcement Learning Reward for Test Case Prioritization in Continuous Integration. In Proceedings of the 11th Asia-Pacific Symposium on Internetware. 1–6.Google ScholarDigital Library
- Yang Yang, Zheng Li, Liuliu He, and Ruilian Zhao. 2020. A systematic study of reward for reinforcement learning based continuous integration testing. Journal of Systems and Software 170 (2020), 110787.Google ScholarCross Ref
- Lian Yu, Lei Xu, and Wei-Tek Tsai. 2010. Time-constrained test selection for regression testing. In International Conference on Advanced Data Mining and Applications. Springer, 221–232.Google ScholarCross Ref
Index Terms
- Dynamic Time Window based Reward for Reinforcement Learning in Continuous Integration Testing
Recommendations
Reinforcement learning for automatic test case prioritization and selection in continuous integration
ISSTA 2017: Proceedings of the 26th ACM SIGSOFT International Symposium on Software Testing and AnalysisTesting in Continuous Integration (CI) involves test case prioritization, selection, and execution at each cycle. Selecting the most promising test cases to detect bugs is hard if there are uncertainties on the impact of committed code changes or, if ...
A Time Window based Reinforcement Learning Reward for Test Case Prioritization in Continuous Integration
Internetware '19: Proceedings of the 11th Asia-Pacific Symposium on InternetwareContinuous integration refers to the practice of merging the working copies of all developers into the mainline frequently. Regression testing for each mergence is characterized by continually changing test suite, limited execution time, and fast ...
Sparse reward for reinforcement learning‐based continuous integration testing
AbstractReinforcement learning (RL) has been used to optimize the continuous integration (CI) testing, where the reward plays a key role in directing the adjustment of the test case prioritization (TCP) strategy. In CI testing, the frequency of ...
This paper first tackles the sparse rewards of reinforcement learning based on continuous integration testing. To reduce reward sparsity, historical failure density is defined to describe sparse rewards objectively. According to the historical failure ...
Comments