A Fine-Grained Approach for Automated Conversion of JUnit Assertions to English

11/12/2018
by   Danielle Gonzalez, et al.
0

Converting source or unit test code to English has been shown to improve the maintainability, understandability, and analysis of software and tests. Code summarizers identify important statements in the source/tests and convert them to easily understood English sentences using static analysis and NLP techniques. However, current test summarization approaches handle only a subset of the variation and customization allowed in the JUnit assert API (a critical component of test cases) which may affect the accuracy of conversions. In this paper, we present our work towards improving JUnit test summarization with a detailed process for converting a total of 45 unique JUnit assertions to English, including 37 previously-unhandled variations of the assertThat method. This process has also been implemented and released as the AssertConvert tool. Initial evaluations have shown that this tool generates English conversions that accurately represent a wide variety of assertion statements which could be used for code summarization or other NLP analyses.

READ FULL TEXT

page 1

page 2

page 3

page 4

research
09/11/2020

Generating Accurate Assert Statements for Unit Test Cases using Pretrained Transformers

Unit testing represents the foundational basis of the software testing p...
research
07/20/2021

A Hybrid Approach to Fine-grained Automated Fault Localization

Fault localization is to identify faulty source code. It could be done o...
research
05/24/2023

SAGA: Summarization-Guided Assert Statement Generation

Generating meaningful assert statements is one of the key challenges in ...
research
02/12/2021

SumeCzech: Large Czech News-Based Summarization Dataset

Document summarization is a well-studied NLP task. With the emergence of...
research
06/15/2022

An Extractive-and-Abstractive Framework for Source Code Summarization

(Source) Code summarization aims to automatically generate summaries/com...
research
07/16/2012

MARFCAT: Transitioning to Binary and Larger Data Sets of SATE IV

We present a second iteration of a machine learning approach to static c...
research
05/14/2022

Auto-Select Reading Passages in English Assessment Tests?

We show a method to auto-select reading passages in English assessment t...

Please sign up or login with your details

Forgot password? Click here to reset