Learning How to Test - Generating Context-Infused Test Cases
One method of automating test creation that has shown great promise is search-based test generation, where powerful optimization algorithms identify test input that meets the higher-level goals of a tester, guided by feedback from one or more fitness functions that judge the optimality of the chosen input. Despite great advances in this type of test generation, the resulting test suites still often fail to match the results from human testers.
One potential limitation is a narrow focus on optimizing code coverage. Code coverage ensures that code is covered, but places few limitations on how it is covered. Developers are driven by context - informed by product domain, software requirements, and past experience. For a human, coverage is only a tiny part of a multifaceted combination of strategies. We propose that the key to effective test generation lies in employing context-infused generation strategies - joining notions of code coverage with project-specific context to control “how’” code is executed and employing adaptive mechanisms to mold unique generation strategies for the code-under-test.
By incorporating project-specific context into the generation equation, we can generate tests in a more human-like manner. This talk will outline our vision for the next generation of search-based test generation tools and results from experiments using reinforcement learning to adapt unit test generation to better meet certain testing goals.
Gregory Gay is an Assistant Professor in the Software Engineering division at Chalmers and the University of Gothenburg. His research interests include automated testing and analysis and search-based software engineering. Greg received his Ph.D. from the University of Minnesota, working with the Critical Systems research group, and an M.S. from West Virginia University.
Mon 12 AprDisplayed time zone: Brasilia, Distrito Federal, Brazil change
09:40 - 10:40
|Learning How to Test - Generating Context-Infused Test Cases|
K: Gregory Gay Chalmers and the University of Gothenburg