For Programmers: Free Programming Magazines  


Home > Archive > Fortran > January 2008 > Re: FORTRAN Unit Test Framework (FRUIT) 2.1 released









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: FORTRAN Unit Test Framework (FRUIT) 2.1 released
Arjen Markus

2008-01-18, 7:15 pm

On 18 jan, 05:51, Andrew Chen <hang...@gmail.com> wrote:
>
>
> TDD is Test Driven Development. BDD and rSpec are just variation of
> TDD. TDD is a blue pill, never go back after taking that :-) See
> here: http://en.wikipedia.org/wiki/Test-driven_development
>
> It is actually surprising that FORTRAN community doesn't have much TDD
> practices. I hope FRUIT can help.
>


I am curious about that myself - not so much that the trendy acronym
is
relatively unknown within our community, but that unit testing and
other forms
of (regression) testing do not seem to evident, essential tools of the
trade.

I can think of a large number of reasons, based on my own experiences:
- It is tedious to keep small test programs around together with the
test input and reference output.
- Many Fortran programs are vast and would require loads of such test
programs.
- The language itself can hinder unit tests - as you can not hide the
test programs inside the source files, as you can with C, using
preprocessor
macros for instance.
- The Fortran IDEs do not support unit testing, as you see with Java
IDEs.
- Numerical results may vary independently of changes in the source
code due
to different compilers, compiler options and so on.
- Fortran routines tend to be larger in general (with more input and
output parameters)
than the (very) small routines you typically see with object-
oriented languages.
(The fact that you need many calls to these routines to get
something done,
could make it more attractive to spend time writing tests for each
of them.)

I do not know what the most prominent reasons are - maybe there are no
specific
reasons.

Anyhow, managing small test programs (seemingly) separately from the
main body
of the program was what made me write my unit testing framework (cf.
http://flibs.sf.net).

Regards,

Arjen
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com