Closed edwardhartnett closed 1 year ago
More bort() testing will come, but let's get these working tests into the repo.
The test_bort.F90 program can be used to test any bort situation, but so far I have been adding tests for the low-hainging fruit, borts that can be easily achieved by passing bad input to a subroutine, without any setup required.
In other cases, setup may be required to test a bort.
In some cases, like a bort in closbf() for example, it may be practically impossible to test without causing a memory leak. If our test program opens a file, and then causes a bort on the close call, the file never gets closed and the resources never released, leading to a memory leak, which will cause the test to fail. ;-)
Anyway, I will harvest the low-hanging fruit and we'll see where we are. It may not be possible to test all borts.
Part of #381.
In this PR I add testing for borts of more functions.