Reducing the Cost of Grammar-Based Testing Using Pattern Coverage

Abstract : In grammar-based testing, context-free grammars may be used to generate relevant test inputs for language processors, or meta programs, such as programming language compilers, refactoring tools, and implementations of software quality metrics. This technique can be used to test these meta programs, but the amount of sentences, and syntax trees thereof, which needs to be generated to obtain reasonable coverage of the input language is exponential.Pattern matching is a programming language feature used often when writing meta programs. Pattern matching helps because it automates the frequently occurring task of detecting shapes in, and extracting information from syntax trees. However, meta programs which contain many patterns are difficult to test using only randomly generated sentences from grammar rules. The reason is that statistically it is uncommon to directly generate sentences which accidentally match the patterns in the code.To solve this problem, in this paper we extract information from the patterns in the code of meta programs to guide the sentence generation process. We introduce a new coverage criterion, called Pattern Coverage, which focuses on providing a test strategy to reduce the amount of test necessary cases, while covering the relevant parts of the meta program. An initial experimental evaluation is presented and the result is compared with traditional grammar-based testing.
Type de document :
Communication dans un congrès
Khaled El-Fakih; Gerassimos Barlas; Nina Yevtushenko. 27th IFIP International Conference on Testing Software and Systems (ICTSS), Nov 2015, Sharjah and Dubai, United Arab Emirates. Lecture Notes in Computer Science, LNCS-9447, pp.71-85, 2015, Testing Software and Systems. 〈10.1007/978-3-319-25945-1_5〉
Liste complète des métadonnées

Littérature citée [30 références]  Voir  Masquer  Télécharger

https://hal.inria.fr/hal-01470158
Contributeur : Hal Ifip <>
Soumis le : vendredi 17 février 2017 - 10:25:57
Dernière modification le : mercredi 25 octobre 2017 - 13:54:01
Document(s) archivé(s) le : jeudi 18 mai 2017 - 13:50:17

Fichier

385214_1_En_5_Chapter.pdf
Fichiers produits par l'(les) auteur(s)

Licence


Distributed under a Creative Commons Paternité 4.0 International License

Identifiants

Citation

Cleverton Hentz, Jurgen Vinju, Anamaria Moreira. Reducing the Cost of Grammar-Based Testing Using Pattern Coverage. Khaled El-Fakih; Gerassimos Barlas; Nina Yevtushenko. 27th IFIP International Conference on Testing Software and Systems (ICTSS), Nov 2015, Sharjah and Dubai, United Arab Emirates. Lecture Notes in Computer Science, LNCS-9447, pp.71-85, 2015, Testing Software and Systems. 〈10.1007/978-3-319-25945-1_5〉. 〈hal-01470158〉

Partager

Métriques

Consultations de la notice

111

Téléchargements de fichiers

2