Software testing in research#

Research softwares are softwares developed by researchers to process or generate data to test their scientific hypothesis [Suresoft]. Within academia, the developers of a software are often self-taught programmers and lack formal software engineering knowledge. As a result, the quality of the software in the long term is questioned and one problem causing this is lack of sufficient software tests. Software testing is an important practice to check the proper functioning and to ensure high software quality. Hence, it is important to integrate software testing to a researcher’s software development lifecycle.

Note

Scientists spend 57% of the time finding and fixing bugs.
[P. Prabhu et al., A Survey of the Practice of Computational Science, 2011]

Integrating software testing methodologies helps a researcher and the research institution in many ways. For instance:

  • Enable easy identification of defects/bugs, thereby significantly reducing the time spent for debugging and fixing bugs

  • Ensure high software code quality

  • Ensure functioning of various code routines

  • Testing scripts serves as readable documentation of correct behavior of various software components and features, thereby helping new generation of software developers to better understand the codes

  • Enable easy merging of codes and features

  • Preserves the value of various research codes thereby preventing a future researcher from reinventing the wheel

How to choose the right type of testing for research codes?#

There are more than 150 types of software testing techniques and are still increasing. But which of them are relevant for research softwares? Each technique is unique and serves different purposes. For a start, we recommend the popular and most commonly used testing techniques of (1) unit testing, (2) acceptance testing and (3) code-quality tests. However, the best type of techniques and level of testing that suits a software depends on their individual testing requirements. For example, we list the following scenarios:

  • If you are developing a desktop or web application, you may require: Functionality testing, interface testing, usability testing, performance testing, security testing, and many more.

  • If you are developing a computitional tool, you may require: Unit testing, integration testing, acceptance testing, performance testing, and the list continues.

Hence, a software can be successfully tested by choosing the right testing technique depending on the specific characteristics and application.

Conclusion#

Software testing practices are less common in the field of academic research. So as to achieve code sustainability, it is necessary to adapt and integrate necessary testing techniques to a software’s development workflow. Therefore within Suresoft, we focus on educating the researchers with software testing concepts and strategies to help them support their software development process.