TEST - Unit testing scientific software

20.10.2021 10:45 - 12:15

Tommsch Mejstrik (University of Vienna)

Unit testing is a programming paradigm that can greatly increase the quality of code. However, it is rarely used for software development in a scientific context. In particular, there is no unit test framework specifically targeting scientific programming, where conciseness, low-threshold access, and the provision of the necessary tools are particularly important.

We cast these observations into the new unit test framework TTEST, written for Matlab. Apart from the basic requirements on unit test frameworks, TTEST allows testing Matlab scripts, adding pre- and postconditions in functions, manipulating workspaces programmatically, testing exceptions in a reliable way, and it has first class support of gold standard tests and property based testing as well as tools specifically targeted at refactoring.

We introduce the novel idea of using code injection for unit testing and refactoring, and present minimum implementations of our developed tools. Finally, we show that TTEST is faster, more efficient, and less verbose than existing unit test frameworks in Matlab.

Zoom link

We kindly ask you to use your full name.

K. Gröchenig, J. L. Romero, M. Ehler
SR 12