Jartege: a Tool for Random Generation of Unit Tests for Java Classes
Catherine Oriat (LSR - IMAG)

TL;DR
Jartege is a tool that automatically generates randomized unit tests for Java classes using JML specifications, aiding in testing and verification with customizable parameters.
Contribution
It introduces a novel tool that combines random test generation with formal specifications for Java, enhancing test coverage and reliability.
Findings
Effective in generating relevant test cases based on specifications
Allows parameterized control over test generation process
Demonstrated usefulness through a practical case study
Abstract
This report presents Jartege, a tool which allows random generation of unit tests for Java classes specified in JML. JML (Java Modeling Language) is a specification language for Java which allows one to write invariants for classes, and pre- and postconditions for operations. As in the JML-JUnit tool, we use JML specifications on the one hand to eliminate irrelevant test cases, and on the other hand as a test oracle. Jartege randomly generates test cases, which consist of a sequence of constructor and method calls for the classes under test. The random aspect of the tool can be parameterized by associating weights to classes and operations, and by controlling the number of instances which are created for each class under test. The practical use of Jartege is illustrated by a small case study.
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsSoftware Testing and Debugging Techniques · Software Engineering and Design Patterns · Logic, programming, and type systems
