Skip to main content
Log in

Traxtor: An Automatic Software Test Suit Generation Method Inspired by Imperialist Competitive Optimization Algorithms

  • Published:
Journal of Electronic Testing Aims and scope Submit manuscript

Abstract

Software testing refers to a process which improves the quality of software systems and also is one of time and cost consuming stages in software development. Hence, software test automation is regarded as a solution which can facilitate heavy and laborious tasks of testing. Automatic generation of test data with maximum coverage of program branches is regarded as an NP-complete optimization problem. Several heuristic and evolutionary algorithms have been proposed for generating test suits with maximum coverage. Failure to maximally branch coverage, poor success rate in test data generation with maximum coverage and lack of stable results are considered as the major drawbacks of previous methods. Enhancing the coverage rate of the generated test data, enhancing the success rate in generating the tests data with maximum coverage and enhancing the stability and speed criteria are the major purposes of the present study. In this study, an effective method (Traxtor) is proposed to automatically generate tests data by using imperialist competitive algorithms (ICA) optimization algorithms. The proposed method is aimed at generating test data with maximum branch coverage in a limited amount of time. The results obtained from executing a wide range of experiments indicated that the proposed algorithm, with 99.99% average coverage, 99.94% success rate, 2.77 average generation and 0.12 s average time outperformed the other algorithms.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4

Similar content being viewed by others

Data Availability

The datasets generated during and the implemented code during the current study is available in the google.drive can be freely accessed by [17].

Notes

  1. Traxtor is the name of a popular Turk football team in the historical city of Tabriz.

References

  1. Ammann P, Offutt J (2017) Introduction to Software Testing. Cambridge University Press, ISBN 978–1–107–17201–2

  2. Lin JC, Yeh PL (2001) Automatic Test Data Generation for Path Testing using GAs. J Inform Sci 131(1):47–64

    Article  Google Scholar 

  3. Khatun S, Rabbi KF, Yaakub CY, Klaib MFJ (2011) A Random search based effective algorithm for pairwise test data generation. Int Conf Electrical Control Comput Eng 2011 (InECCE), 293–297. https://doi.org/10.1109/INECCE.2011.5953894.

  4. Eler MM, Endo AT, Durelli VH (2016) An empirical study to quantify the characteristics of Java programs that may influence symbolic execution from a unit testing perspective. J Syst Softw 121:281–297, ISSN. 0164–1212

  5. Cristian C, Koushik SS (2013) Symbolic Execution For Software Testing: Three Decades Later. Commun ACM 56(2):82–90

    Article  Google Scholar 

  6. Cohen MB, Colbourn CJ, Ling AC (2003) Augmenting Simulated Annealing to Build Interaction Test Suites. Proc Fourteenth Int Symp Softw Reliab Eng (ISSRE'03), 394–405

  7. Sharma C, Sabharwal S, Sibal R (2014) A Survey on Software Testing Techniques using Genetic Algorithm. Int J Comput Sci 10(1):381–393

    Google Scholar 

  8. Esnaashari M, Damia AH (2021) Automation of software test data generation using genetic algorithm and reinforcement learning. Expert Syst Appl 183:115446

  9. Mao C (2014) Generating Test Data for Software Structural Testing Based on Particle Swarm Optimization. Arab J Sci Eng 39(6):4593–4607

    Article  Google Scholar 

  10. Kaur A, Bhatt D (2011) Hybrid particle swarm optimization for regression testing. Int J Comput Sci Eng 3(5):1815–1824

    Google Scholar 

  11. Atashpaz-Gargari E, Lucas C (2007) Imperialist competitive algorithm: An algorithm for optimization inspired by imperialistic competition. Proc IEEE Congress Evol Comput (CEC 2007), Singapore, 4661–4667

  12. Ahmed BS, Zamli KZ (2011) A variable strength interaction test suites generation strategy using particle swarm optimization. J Syst Softw 84:2171–2185

    Article  Google Scholar 

  13. Sahoo RR, Ray M (2020) PSO based test case generation for critical path using improved combined fitness function. J King Saud Univ Comput Inf Sci 32(4):479–490

    Article  Google Scholar 

  14. Mao C, Xiao L, Yu X, Chen J (2015) Adapting Ant Colony Optimization to Generate Test Data for Software Structural Testing. J Swarm Evol Comput 20:23–36

    Article  Google Scholar 

  15. Aghdam ZK, Arasteh B (2017) An Efficient Method to Generate Test Data for Software Structural Testing Using Artificial Bee Colony Optimization Algorithm. Int J Softw Eng Knowl Eng 27(6):951–966

    Article  Google Scholar 

  16. Ghaemi A, Arasteh B (2020) SFLA-based heuristic method to generate software structural test data. J Softw Evol 32(1)

  17. https://drive.google.com/drive/folders/1-i2k86j-PIio3CqwTsH-PSMLh1zGU3a4?usp=sharing

  18. Hosseini MJ, Arasteh B, Isazadeh A, Mohsenzadeh M, Mirzarezaee M (2020) An error-propagation aware method to reduce the software mutation cost using genetic algorithm. Data Technol Appl 55(1):118–148. https://doi.org/10.1108/DTA-03-2020-0073

    Article  Google Scholar 

  19. Shomali N, Arasteh B (2020) Mutation reduction in software mutation testing using firefly optimization algorithm. Data Technol Appl 54(4):461480. https://doi.org/10.1108/DTA-08-2019-0140

    Article  Google Scholar 

  20. https://cs.gmu.edu/~offutt/mujava

Download references

Funding

The authors declare that no funds, grants, or other support were received during the preparation of this manuscript.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Bahman Arasteh.

Ethics declarations

Disclosure

The authors have no relevant financial or non-financial interests to disclose. All authors contributed to the study conception and design.

Additional information

Responsible Editor: V. D. Agrawal

Publisher's Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Arasteh, B., Hosseini, S.M.J. Traxtor: An Automatic Software Test Suit Generation Method Inspired by Imperialist Competitive Optimization Algorithms. J Electron Test 38, 205–215 (2022). https://doi.org/10.1007/s10836-022-05999-9

Download citation

  • Received:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s10836-022-05999-9

Keywords

Navigation