A Semantic Web Enabled Approach to Automate Test Script Generation for Web Applications

Document Type : Software Engineering-Bagheri


1 P.hD student Ferdowsi University of Mashhad

2 Ferdowsi University of Mashhad, Iran.

3 FFerdowsi University of Mashhad, Iran.


Software testing is one of the most important activities for ensuring quality of software products. It is a complex and knowledge-intensive activity which can be improved by reusing tester knowledge. Generally, testing web applications involve writing manual test scripts, which is a tedious and labor-intensive process. Manually written test scripts are valuable assets encapsulating the knowledge of the testers. Reusing these scripts to automatically generate new test scripts can improve the effectiveness of software testing and reduce the cost of required manual interventions. In this paper, a semantic web enabled approach is proposed for automatically adapting and generating test scripts; it reduces the cost of human intervention across multiple scripts by accumulating the human knowledge as semantic annotations on test scripts. This is supported by designing an ontology which defines the concepts and relationships required for test script annotation. The proposed approach is based on novel algorithms for adapting and generating new test scripts. The initial experiments show that the proposed approach is promising as it successfully increases the level of test automation.


Main Subjects

[1] X. Yuan and A. M. Memon, “Iterative execution-feedback model-directed GUI testing,” Information and Software Technology, Vol. 52, No. 5, pp. 559–575, (2010).
[2] M. Biagiola, A. Stocco, F. Ricca, and P. Tonella, “Dependency-aware web test generation,” in 2020 IEEE 13th International Conference on Software Testing, Validation and Verification, pp. 175–185 (2020).
[3] J.-W. Lin, F. Wang, and P. Chu, “Using Semantic Similarity in Crawling-Based Web Application Testing,” in Proceedings - 10th IEEE International Conference on Software Testing, Verification and Validation, pp. 138–148 (2017).
[4] C. Pacheco, S. K. Lahiri, M. D. Ernst, and T. Ball, “Feedback-directed random test generation,” in 29th International Conference on Software Engineering (ICSE’07), pp. 75–84 (2007).
[5] S. Artzi, J. Dolby, S. H. Jensen, A. Møller, and F. Tip, “A framework for automated testing of JavaScript web applications,” in Proceedings of the 33rd International Conference on Software Engineering, pp. 571–580 (2011).
[6] S. Elbaum, G. Rothermel, S. Karre, and M. Fisher II, “Leveraging user-session data to support web application testing,” IEEE Tranaction on Software Engineering, vol. 31, no. 3, pp. 187–202 (2005).
[7] S. E. Sprenkle, L. L. Pollock, and L. M. Simko, “Configuring effective navigation models and abstract test cases for web applications by analysing user behaviour,” Software Testing, Verification, and Reliability, vol. 23, no. 6, pp. 439–464 (2013).
[8] S. Yoo and M. Harman, “Test data regeneration: generating new test data from existing test data,” Software Testing, Verification, and Reliability, vol. 22, no. 3, pp. 171–201 (2012).
[9] M. Mirzaaghaei, F. Pastore, and M. Pezzè, “Supporting test suite evolution through test case adaptation,”  IEEE International Conference on Software Testing, Veriication and. Validation, ICST 2012, vol. 2, pp. 231–240 (2012).
[10]         Z. Gao, Z. Chen, Y. Zou, and A. M. Memon, “SITAR: GUI Test Script Repair,” IEEE Transaction on Software Engineering, vol. 42, no. 2, pp. 170–186 (2016).
[11] A. Milani Fard, M. Mirzaaghaei, and A. Mesbah, “Leveraging existing tests in automated test generation for web applications,” in Proceedings of the 29th ACM/IEEE international conference on Automated software engineering - ASE ’14, pp. 67–78 (2014).
[12]         M. Dadkhah, S. Araban, and S. Paydar, “A systematic literature review on semantic web enabled software testing,” Journal of  Systems and  Software, vol. 162, p. 110485 (2020).
[13]         T. R. Silva, M. Winckler, and H. Trætteberg, “Ensuring the Consistency Between User Requirements and Graphical User Interfaces: A Behavior-Based Automated Approach,” in International Conference on Computational Science and Its Applications, pp. 616–632 (2019).
[14] H. Hajiabadi and M. Kahani, “An automated model based approach to test web application using ontology,” in IEEE Conference on Open Systems, pp. 354–359 (2011).
[15]         A. Rauf, S. Anwar, M. Ramzan, S. ur Rehman, and A. A. Shahid, “Ontology driven semantic annotation based GUI testing,” in International Conference on Emerging Technologies (ICET), pp. 261–264 (2010).
[16]         R. Tönjes, E. S. Reetz, M. Fischer, and D. Kuemper, “Automated testing of context-aware applications,” (2015).
[17]         L. Mariani and M. Pezze, “Link : Exploiting the Web of Data to Generate Test Inputs,” (2014).
[18]                         R. Li and S. Ma, “The Use of Ontology in Case Based Reasoning for Reusable Test Case Generation,” in International Conference on Artificial Intelligence and Industrial Engineering, pp. 369–374 (2015).
[19]         S. Dalal, S. Kumar, and N. Baliyan, “An Ontology-Based Approach for Test Case Reuse,” in Intelligent Computing, Communication and Devices, pp. 361–366 (2015).
[20] C. Menzel, “Reference Ontologies — Application Ontologies : Either / Or or Both / And ?,” (2003).
[21]         É. F. de Souza, R. de A. Falbo, and N. L. Vijaykumar, “ROoST: Reference Ontology on Software Testing,” Appl. Ontol., vol. 12, no. 1, pp. 59–90 (2017).
[22]         Z. Szatmári, J. Oláh, and I. Majzik, “Ontology-based test data generation using metaheuristics,” in Proceedings of the 8th International Conference on Informatics in Control, Automation and Robotics, vol. 2, pp. 217–222 (2011).
[23] C. D. Nguyen, A. Perini, and P. Tonella, “Ontology-based Test Generation for Multiagent Systems,” in Proceedings of the 7th International Joint Conference on Autonomous Agents and Multiagent Systems - Volume 3,  pp. 1315–1320 (2008).
[24]         L. Mariani, M. Pezzè, O. Riganelli, and M. Santoro, “Automatic Testing of GUI-based Applications,” Software Testing, Verification, and Reliability, vol. 24, no. 5, pp. 341–366 (2014).