Treffer: A Program Transformation for Converting Java Assertions into Control-flow Statements

Title:
A Program Transformation for Converting Java Assertions into Control-flow Statements
Contributors:
Universitäts- und Landesbibliothek Münster
Publication Year:
2024
Collection:
Münster University (WWU): miami
Document Type:
Report report
File Description:
application/pdf
Language:
English
Relation:
https://nbn-resolving.org/urn:nbn:de:hbz:6-54539528383; info:eu-repo/semantics/reference/urn/urn:nbn:de:hbz:6-54539528383
DOI:
10.17879/25928672713
Rights:
CC BY 4.0 ; info:eu-repo/semantics/openAccess
Accession Number:
edsbas.F3A84CD4
Database:
BASE

Weitere Informationen

We present a technique for checking the validity of Java assertions using an arbitrary automated test-case generator. Our framework transforms the program by introducing code that detects whether the assertion conditions are met by every direct and indirect method call within a certain depth level. Then, any automated test-case generator can be used to look for input examples that falsify the conditions. The program transformation ensures that the value obtained for these inputs represents a path of method calls that ends with a violation of some assertion. We show experiments with two different automatic test-case generators that demonstrate not just the applicability of our proposal but also that we can get a better coverage than the same test-case generators without our transformation.