Tampere University of Technology

TUTCRIS Research Portal

Reducing the number of unit tests with design by contract

Research output: Chapter in Book/Report/Conference proceedingConference contributionScientificpeer-review

Details

Original languageEnglish
Title of host publicationComputer Systems and Technologies - 12th International Conference, CompSysTech'11 - Proceedings
Pages161-166
Number of pages6
Volume578
DOIs
Publication statusPublished - 2011
Publication typeA4 Article in a conference publication
Event12th International Conference on Computer Systems and Technologies, CompSysTech'11 - Vienna, Austria
Duration: 16 Jun 201117 Jun 2011

Conference

Conference12th International Conference on Computer Systems and Technologies, CompSysTech'11
CountryAustria
CityVienna
Period16/06/1117/06/11

Abstract

Design by Contract (DbC) and unit testing (UT) are complementary approaches to improve the belief of correctness and the quality of the software. The interplay between the two techniques has been studied previously, e.g., in the use of test oracles and test automation. However, we propose that DbC should drive the UT to become more cost-effective. The paper demonstrates some means for this approach by showing how to test a mapping data structure entirely with just one unit test script.

Keywords

  • contract cohesion graph, design by contract, unit testing