TL;DR
TOGA is a neural transformer-based method that generates test oracles from code context, improving accuracy and bug detection in software testing, especially for units with missing or ambiguous documentation.
Contribution
The paper introduces TOGA, a novel neural approach that infers test oracles from code context, handling ambiguous or missing documentation and code, with significant accuracy improvements.
Findings
Achieves 96% oracle inference accuracy.
Improves accuracy by 33% over existing methods.
Finds 57 real bugs, including 30 unique ones.
Abstract
Testing is widely recognized as an important stage of the software development lifecycle. Effective software testing can provide benefits such as bug finding, preventing regressions, and documentation. In terms of documentation, unit tests express a unit's intended functionality, as conceived by the developer. A test oracle, typically expressed as an condition, documents the intended behavior of a unit under a given test prefix. Synthesizing a functional test oracle is a challenging problem, as it must capture the intended functionality rather than the implemented functionality. In this paper, we propose TOGA (a neural method for Test Oracle GenerAtion), a unified transformer-based neural approach to infer both exceptional and assertion test oracles based on the context of the focal method. Our approach can handle units with ambiguous or missing documentation, and even units with a…
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.
Code & Models
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
