A Multi-Language Tool for Generating Unit Tests from Execution Traces - EVREF
Communication Dans Un Congrès Année : 2025

A Multi-Language Tool for Generating Unit Tests from Execution Traces

Résumé

Legacy software systems often lack extensive testing, but are assumed to behave correctly after years of bug fixes and stable operation. Migrating or modernizing these systems is challenging because there is little support for preventing regressions. Test carving addresses this problem by generating unit tests based on the current behavior of the system, treating it as an implicit oracle. In this paper, we present Modest, a multi-language tool that generates unit tests by carving them from execution traces. Modest processes method calls, including their receivers, arguments, and results, to recreate these invocations as unit tests. Its model-based approach allows it to support multiple languages. We detail how it can be extended to handle additional languages. Modest aims to generate tests that are human-readable and maintainable over time. To achieve this, it reconstructs values as source code rather than relying on deserialization. We evaluate Modest by generating tests for both Java and Pharo applications.
Fichier principal
Vignette du fichier
Darb24b.pdf (277.12 Ko) Télécharger le fichier
Origine Fichiers produits par l'(les) auteur(s)
licence

Dates et versions

hal-04841805 , version 1 (17-12-2024)

Licence

Identifiants

  • HAL Id : hal-04841805 , version 1

Citer

Gabriel Darbord, Nicolas Anquetil, Benoit Verhaeghe, Anne Etien. A Multi-Language Tool for Generating Unit Tests from Execution Traces. SANER 2025, Mar 2025, Montréal, Canada. ⟨hal-04841805⟩
0 Consultations
0 Téléchargements

Partager

More