Files in this item



application/pdfTan_ShinHwei.pdf (170kB)
(no description provided)PDF


Title:@tComment: testing Javadoc comments to detect comment-code inconsistencies
Author(s):Tan, Shin Hwei
Advisor(s):Marinov, Darko; Tan, Lin
Department / Program:Computer Science
Discipline:Computer Science
Degree Granting Institution:University of Illinois at Urbana-Champaign
Subject(s):comment analysis
random testing
test generation
Abstract:Code comments are important artifacts in software. Javadoc comments are widely used in Java for API specifications. API developers write Javadoc comments, and API users often read these comments to understand the API they use, e.g., an API user can read a Javadoc comment for a method instead of reading the method body of the method. An inconsistency between the Javadoc comment and body for a method indicates either a fault in the body or, effectively, a fault in the comment that can mislead the method callers of the method to introduce faults in their code. This thesis presents a novel approach, called @tComment, for testing Javadoc comments, specifically for testing method properties about null values and related exceptions. Our approach consists of two components. The first component takes as input source files for a Java project and automatically analyzes the English text in Javadoc comments to infer a set of likely properties for a method in the files. The second component generates random tests for these methods, checks the inferred properties, and reports inconsistencies. We evaluated @tComment on seven open-source projects and found 28 inconsistencies between Javadoc comments and method bodies. We reported all inconsistencies, and 12 have already been confirmed and fixed by the developers.
Issue Date:2012-05-22
Rights Information:Copyright 2012 Shin Hwei Tan
Date Available in IDEALS:2012-05-22
Date Deposited:2012-05

This item appears in the following Collection(s)

Item Statistics