FAQ and Tips


Zero Tests Run

Symptom: The system under test compiles and runs fine, but reports zero tests run.


Some Tests Are Not Running

Symptom: The system under test compiles and runs fine, but reports that some tests don't run.


Intel Fortran Version 13: -DINTEL_13

Using version 13 is deprecated. We have encountered problems using version 13, which we believe may be due to subtle compiler bugs. We strongly recommend upgrading to the latest version possible.

To make pFUnit work with Intel Fortran Version 13, please ensure that -DINTEL_13 is passed to the compiler when building or using pFUnit. In the build process for pFUnit, this is added to the make variables CPPFLAGS and FPPFLAGS.

Segmentation Faults and Odd Link Errors

Q. pFUnit fails to build or now leads to segmentation faults. Did something change?

A. One cause for failure to build or odd runtime segmentation faults is when we change compiler configurations and some object or library files are left over from a previous environment. This might be hard to spot, for example, during compiler upgrades. Switching from one compiler to another, e.g. from Intel to GNU, is more likely to generate link-time errors if old code is still around. A few items to check follow.

Finally, it is quite possible that a bug has been uncovered. Please contact the development team or open a bug ticket.


Environment Modules

Though not strictly required, the Environment Modules package can be a convenient way to package, maintain, and switch between environments. This can be particularly important for pFUnit, which must be built using the same tool suite being used for development, e.g. compilers, linkers, etc. [To do: A sample pFUnit modulefile is provided in the OTHER directory.]

Compile Time Errors

Compile time errors like '"include [...]include/.mk" not found' likely signify that you are not executing make in the top level directory during a build. Alternatively, during regular usage after installation, PFUNIT has not been set.

During building, if you wish to compile in a subdirectory within the pFUnit heriarchy, please try setting the COMPILER environment variable on the make command line. For example:

$ make all COMPILER=Intel

Intermediate files used by pFUnit

If you wish to see the intermediate files, use the target .PRECIOUS in the makefile to keep them from being deleted. For example:

# In GNUmakefile
.PRECIOUS: %_cpp.F90

Ignoring whitespace differences in assertions on strings.

Several options exist for how to compare strings with assertEqual.

call assertEqual(expectedString, foundString, &


Example usages can be seen in tests/Test_AssertBasic.F90 or Examples/Simple/tests/