{"title":"Generating unit tests using static analysis and contracts","authors":"A. Andrianova, V. Itsykson","doi":"10.1109/TMPA.2013.22","DOIUrl":null,"url":null,"abstract":"Software Quality Assurance is one of the main challenges of software engineering. One of the ways to improve software quality is automated synthesis of unit tests. This paper describes a technology of automated unit tests creation combining the “white” and “black” box approaches. This allows using information extracted from the source code of the program and using partial specifications in the form of contracts to create test oracles and distribute the test parameters across the domain of definition to ensure the test coverage of program paths. The developed approach was implemented as a tool that analyzes Java-based programs and generates test cases for class methods in JUnit format, using CoFoJa to specify the contracts. Testing of the designed tool performed on a number of test objects has proven that the approach is efficient.","PeriodicalId":147297,"journal":{"name":"2013 Tools & Methods of Program Analysis","volume":"10 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2013-10-10","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"2013 Tools & Methods of Program Analysis","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1109/TMPA.2013.22","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 0
Abstract
Software Quality Assurance is one of the main challenges of software engineering. One of the ways to improve software quality is automated synthesis of unit tests. This paper describes a technology of automated unit tests creation combining the “white” and “black” box approaches. This allows using information extracted from the source code of the program and using partial specifications in the form of contracts to create test oracles and distribute the test parameters across the domain of definition to ensure the test coverage of program paths. The developed approach was implemented as a tool that analyzes Java-based programs and generates test cases for class methods in JUnit format, using CoFoJa to specify the contracts. Testing of the designed tool performed on a number of test objects has proven that the approach is efficient.