Asee peer logo

A Force-Directed Program Graph Visualizer for Teaching White-Box Testing Techniques

Download Paper |

Conference

2015 ASEE Annual Conference & Exposition

Location

Seattle, Washington

Publication Date

June 14, 2015

Start Date

June 14, 2015

End Date

June 17, 2015

ISBN

978-0-692-50180-1

ISSN

2153-5965

Conference Session

Software Engineering Constituent Committee Technical Session 2

Tagged Division

Software Engineering Constituent Committee

Tagged Topic

Diversity

Page Count

13

Page Numbers

26.42.1 - 26.42.13

DOI

10.18260/p.23383

Permanent URL

https://peer.asee.org/23383

Download Count

638

Paper Authors

biography

Weifeng Xu Gannon University

visit author page

Dr. Weifeng Xu is an associate professor in the department of computer science at Bowie State University. He received his B.S. and M.S. degrees in Computer Science from Southeast Missouri State University and Towson University at Maryland, respectively. He also received his Ph.D. in Software Engineering from North Dakota State University. His current research efforts focus on search-based software engineering, mining software engineering data, and software testing. He is a senior member of the IEEE.

visit author page

biography

Aqeel Raza Syed Gannon University

visit author page

Aqeel Raza Syed obtained his master’s degree from the department of Computer and Information Sciences, Gannon University in 2013. He is currently working as a software engineer at AT&T labs.

visit author page

biography

QING ZHENG Gannon University

visit author page

Qing Zheng received the M. Eng. degree from the National University of Singapore in 2003 and the D. Eng. degree from the Cleveland State University in 2009, both in electrical engineering. She is currently an assistant professor in the Electrical and Computer Engineering Department at Gannon University. Her research interests include active disturbance rejection control, multivariable control and optimization with emphasis on their applications in biomedical systems, power systems, MEMS, fuel cell, cargo ship steering, chemical processes, and other real industrial problems.

visit author page

Download Paper |

Abstract

A Force-Directed Program Graph Visualizer for Teaching White-Box Testing TechniquesAbstractSoftware engineering, as an emerging discipline, has been distinguished from computer science.There are 22 ABET and 105 Department of Education's recognized institutes in U.S offering abachelor degree program in software engineering. In addition to the traditional needs of prepar-ing graduates to analyze, design and implement systems, both organizations indicate that soft-ware engineering curriculum must prepare graduates to validate software systems.White-box testing is a critical validation technique that software engineers can use to examine iftheir code works as expected. White-box testing requires students generating test paths for a giv-en test criterion. However, students taking software testing related courses often find that study-ing and exercising white-box testing techniques is tedious and error prone due to the nature ofthe testing process. The testing process for white-box testing usually consists of three key activi-ties: (1) convert source code to a program graph, (2) generate paths for a given test criterion, e.g.,decision coverage, and (3) verify the correctness of generated paths and the total number of pathsgenerated. It is hard for students to derive and verify correct paths from unit under testing manu-ally based on a variety of test coverages.In this paper, we demonstrate an automated testing visualization tool to help software engineer-ing students to study and exercise white-box testing techniques. The teaching tool has three keycomponents: (1) a program graph generator: it automatically generates program graphs from Javasource code, (2) a path finder: it finds all paths based on test coverages, and (3) a program graphvisualizer: it automatically displays program graphs and test paths.Developing such an automated testing tool is a challenging task. Two critical issues need to betaken into consideration: (1) how to handle compound conditions. Compound condition consistsof multiple simple conditions, e.g., (a>b) && (b>c) contains two simple predicates a>b and b>c.Compound conditions need to be recognized automatically so that different paths can be derivedfrom program graph based on decision, condition and multi-condition coverages and (2) how tovisualize program graphs. It is essentially a graph auto-layout problem, which computes the posi-tion of each node and edge of a program graph. However, current graph auto-layout algorithmsdo not distinguish source and sink nodes of program graph from rest of nodes.To address these issues, we use Java byte code to represent the Java source code so that a com-pound condition can be decomposed to several simple predicates. In addition, we extend a force-directed graph auto-layout algorithm to compute the positions of source and sink nodes. We suc-cessfully implement a teaching tool based on our approach. We demonstrate our tool using sev-eral legacy programs, including Triangle program, Commission program, etc. The demo video isavailable https://www.youtube.com/watch?v=Ey4JfVhhHQg

Xu, W., & Syed, A. R., & ZHENG, Q. (2015, June), A Force-Directed Program Graph Visualizer for Teaching White-Box Testing Techniques Paper presented at 2015 ASEE Annual Conference & Exposition, Seattle, Washington. 10.18260/p.23383

ASEE holds the copyright on this document. It may be read by the public free of charge. Authors may archive their work on personal websites or in institutional repositories with the following citation: © 2015 American Society for Engineering Education. Other scholars may excerpt or quote from these materials with the same citation. When excerpting or quoting from Conference Proceedings, authors should, in addition to noting the ASEE copyright, list all the original authors and their institutions and name the host city of the conference. - Last updated April 1, 2015