Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

Unit testing in fortran

Le_Callet__Morgan_M
861 Views

Dear does INTEL provide a unit testing framework for fortran code.

0 Kudos
2 Replies
Arjen_Markus
Honored Contributor I
861 Views

Whether Intel provides that in particular, I do not know, but if you consult the Fortran Wiki at fortranwiki.org and search for "unit testing", you will find a number of solutions. My own, called ftnunit, consists of a Fortran library and some additional tools. The basic idea is that you write a bunch of small subroutines that exercise the code you want to test and check that the outcome is as expected. The framework then exercises these subroutines and keeps track of the results. Much in fact like any such framework ;).

0 Kudos
Steve_Lionel
Honored Contributor III
861 Views

Intel doesn't offer a testing framework, but it does offer a coverage analysis tool that you can use with your own framework to determine if all of your code is being exercised. There's also a "test prioritization" tool to help you optimize your testing. See https://software.intel.com/en-us/fortran-compiler-developer-guide-and-reference-pgo-tools 

0 Kudos
Reply