Test data generation for web application using a UML class diagram with OCL constraints
- 360 Downloads
In this paper, we report on our current work toward efficient and effective verification of web application’s basic design. We use a UML class diagram with Object Constraint Language (OCL) to describe the application behaviors and data constraints. Then we generate test data from the formally represented specifications. We make the observation that key web application behaviors can be captured through table size constraints as well as data constraints like foreign key constraints. Based on the observation, we translate the OCL specification into the equivalent constraints using table size expressions. We present a scheme to generate test data from the translated constraints using a Satisfiability Modulo Theories solver. We employ two techniques to reduce constraints. The first is string handling and the other is decomposition of table structures. We also report on an experimental result of test data generation. The result indicates a potential that our scheme works well for real applications in reasonable times.
KeywordsWeb application Basic design OCL Testing Data generation
Unable to display preview. Download preview PDF.
- 1.Alloy community. http://alloy.mit.edu/community/
- 2.Binnig C, Kossmann D, Lo E (2007) Reverse query processing. In: Proceedings of the IEEE international conference on data engineering, pp 506–515Google Scholar
- 3.Cabot J, Clarisó R, Riera D (2008) Verification of UML/OCL class diagrams using constraint programming. In: Proceedings of the 2008 IEEE international conference on software testing verification and validation workshop. IEEE Computer Society, Washington, DC, USA, pp 73–80Google Scholar
- 5.Khalek SA, Elkarablieh B, Laleye YO, Khurshid S (2008) Query-aware test generation using a relational constraint solver. In: Proceedings of the 2008 23rd IEEE/ACM international conference on automated software engineering, pp 238–247Google Scholar
- 7.Kiezn A, Ganesh V, Guo PJ, Hooimeijer P, Ernst MD (2009) HAMPI: a solver for string constraints. In: Proceedings of the 18th international symposium on software testing and analysis, pp 105–116Google Scholar
- 8.Koch N, Kraus A (2002) The expressive power of UML-based web engineering. In: Proceedings of the second international workshop on web oriented software technology, pp 105–119Google Scholar
- 9.Pex, automated white box testing for .NET. http://research.microsoft.com/en-us/projects/pex/
- 10.WebML. http://www.webml.org/
- 11.Yices: An SMT solver. http://yices.csl.sri.com/