DScribe: Co-generating Unit Tests and Documentation
- 1 May 2022
- conference paper
- Published by Institute of Electrical and Electronics Engineers (IEEE)
- Vol. 23, 56-60
Abstract
Test suites and documentation capture similar information despite serving distinct purposes. Such redundancy introduces the risk that the artifacts inconsistently capture specifications. We present DScribe, an approach that leverages the redundant information in tests and documentation to reduce the cost of creating them and the threat of inconsistencies. DScribe allows developers to define simple templates that jointly capture the structure to test and document a specification. They can then use these templates to generate consistent and checkable tests and documentation. By linking documentation to unit tests, DScribe ensures documentation accuracy as outdated documentation is flagged by failing tests. DScribe’s template-based approach also enforces a uniform style throughout the artifacts. Hence, in addition to reducing developer effort, DScribe improves artifact quality by ensuring consistent content and style. Video: https://www.youtube.com/watch?v=CUKp3-MjMogKeywords
Funding Information
- Natural Sciences and Engineering Research Council of Canada
- Nature
This publication has 14 references indexed in Scilit:
- CodeSonar (R) Extension for Copy-Paste-(Mis) Adapt Error Detection2019
- Software Documentation Issues Unveiled2019
- Detecting Near Duplicates in Software DocumentationProgramming and Computer Software, 2018
- Using Traceability Links to Recommend Adaptive Changes for Documentation EvolutionIEEE Transactions on Software Engineering, 2014
- Whole Test Suite GenerationIEEE Transactions on Software Engineering, 2012
- Studying the co-evolution of production and test code in open source and industrial developer test processes through repository miningEmpirical Software Engineering, 2010
- CReN2007
- Feedback-Directed Random Test Generation29th International Conference on Software Engineering (ICSE'07), 2007
- A survey of unit testing practicesIEEE Software, 2006
- A Survey of Documentation Practice within Corrective MaintenanceEmpirical Software Engineering, 2005