%0 Conference Proceedings %T Reducing the Cost of Grammar-Based Testing Using Pattern Coverage %+ Universidade Federal do Rio de Janeiro [Brasil] = Federal University of Rio de Janeiro [Brazil] = Université fédérale de Rio de Janeiro [Brésil] (UFRJ) %+ Centrum Wiskunde & Informatica (CWI) %+ Eindhoven University of Technology [Eindhoven] (TU/e) %+ Analysis and Transformation based on rEliAble tool coMpositionS (ATEAMS) %A Hentz, Cleverton %A Vinju, Jurgen, J. %A Moreira, Anamaria, M. %Z This work is partly supported by CNPq grants 237049/2013-9 and 573964/2008-4 (National Institute of Science and Technology for Software Engineering—INES, www.ines.org.br). %Z Part 2: Test Derivation Methods %< avec comité de lecture %( Lecture Notes in Computer Science %B ICTSS 2015 - 27th IFIP International Conference on Testing Software and Systems %C Dubai, United Arab Emirates %Y Khaled El-Fakih %Y Gerassimos Barlas %Y Nina Yevtushenko %3 Testing Software and Systems %V LNCS-9447 %P 71-85 %8 2015-11-23 %D 2015 %R 10.1007/978-3-319-25945-1_5 %K Software test %K Meta program %K Pattern matching %K Grammar-based testing %Z Computer Science [cs] %Z Computer Science [cs]/Networking and Internet Architecture [cs.NI]Conference papers %X 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. %G English %Z TC 6 %Z WG 6.1 %2 https://inria.hal.science/hal-01470158/document %2 https://inria.hal.science/hal-01470158/file/385214_1_En_5_Chapter.pdf %L hal-01470158 %U https://inria.hal.science/hal-01470158 %~ INRIA %~ INRIA-LILLE %~ INRIA_TEST %~ TESTALAIN1 %~ IFIP-LNCS %~ IFIP %~ INRIA2 %~ IFIP-TC %~ IFIP-WG %~ IFIP-TC6 %~ IFIP-WG6-1 %~ IFIP-ICTSS %~ IFIP-LNCS-9447