Advertisement

PSO-Based Test Case Generation: A Fitness Function Based on Value Combined Branch Distance

  • Rashmi Rekha SahooEmail author
  • Mitrabinda Ray
Conference paper
  • 22 Downloads
Part of the Advances in Intelligent Systems and Computing book series (AISC, volume 1089)

Abstract

All-path coverage of software under test is a NP-complete problem. At the time of automatic test case generation, there is some path whose probability of coverage is low. To overcome this problem, we propose a fitness function, value combined branch distance function (VCBDF) on path coverage criteria and is applied with particle swarm optimization (PSO) algorithm to automate test case generation. The objective is to achieve maximum path coverage with the challenge of covering a target path. We have conducted experiment on a bench mark case study, triangle classification problem. Two more existing fitness functions, branch distance (BD) based fitness function and combined fitness function (CFF) are also applied for comparison. Experimental result shows VCBD function gives better result in terms of number of test cases generated for target path and number of iterations as compared to the said functions.

Keywords

Search-based testing Path coverage PSO Fitness function Value combined branch distance 

References

  1. 1.
    Maragathavalli, P.: Search-based software test data generation using evolutionary computation. Int. J. Comput. Sci. Inf. Technol. 3(1), 213–223 (2011)Google Scholar
  2. 2.
    Roshan, R., Porwal, R., Sharma, C.M.: Review of search based techniques in software testing. Int. J. Comput. Appl. 51(6), 42–45 (2012)Google Scholar
  3. 3.
    Shahid, M., Ibrahim, S., Mahrin, M.N.: A study on test coverage in software testing. In: International Conference on Telecommunication Technology and Applications. Proceedings of CSIT, vol. 5, pp. 207–215 (2011)Google Scholar
  4. 4.
    Sahoo, R.R., Ray, M.: Metaheuristic techniques for test case generation: a review. J. Inf. Technol. Res. 11(1), 158–171 (2018)Google Scholar
  5. 5.
    Baresel, A., Sthamer, H., Schmidt, M.: Fitness function design to improve evolutionary structural testing. In: Proceeding of the Genetic and Evolutionary Computation Conference, pp. 1329–1336 (2002)Google Scholar
  6. 6.
    Chen, Y., Zhong, Y., Shi, T., Liu, J.: Comparison of two fitness functions for GA-based path-oriented test data generation. In: Fifth International Conference on Natural Computation, pp. 177–181. IEEE Computer Society, Washington, DC (2009)Google Scholar
  7. 7.
    Thi, D.N., Hieu, V.D., Ha, N.V.: A technique for generating test data using genetic algorithm. In: International Conference on Advanced Computing and Applications, IEEE Conference, pp. 67–73 (2016)Google Scholar
  8. 8.
    Gursaran, A.: Program test data generation for branch coverage with genetic algorithm: comparative evaluation of a maximization and minimization approach. JSE CS & IT 4, 443–454 (2012)Google Scholar
  9. 9.
    Chen, Y., Zhong, Y., Shi, T., Liu, J.: Comparison of two fitness functions for GA-/based path-oriented test data generation. In: Fifth International Conference on Natural Computation, pp. 177–181 (2009)Google Scholar
  10. 10.
    Harman, M., Jia, Y., Zhang, Y.: Achievements, open problems and challenges for search based software testing. In: Proceedings of IEEE 8th International Conference on Software Testing, Verification and Validation, pp. 1–12 (2015)Google Scholar

Copyright information

© Springer Nature Singapore Pte Ltd. 2020

Authors and Affiliations

  1. 1.ITER CollegeSiksha O Anusandhan Deemed to be UniversityBhubaneswarIndia

Personalised recommendations