diff options
author | Travis Oliphant <oliphant@enthought.com> | 2006-01-04 17:26:31 +0000 |
---|---|---|
committer | Travis Oliphant <oliphant@enthought.com> | 2006-01-04 17:26:31 +0000 |
commit | 8e2654541c6eae0f308908f501cccbc86b2f9101 (patch) | |
tree | bfcfe3b282c8fb659832bf86a841ce76852094ad /numpy/f2py/docs/TESTING.txt | |
parent | ddaed649c23bbd0ad36cdafdfe9cd92397ce69e3 (diff) | |
download | numpy-8e2654541c6eae0f308908f501cccbc86b2f9101.tar.gz |
Moved scipy directory to numpy
Diffstat (limited to 'numpy/f2py/docs/TESTING.txt')
-rw-r--r-- | numpy/f2py/docs/TESTING.txt | 108 |
1 files changed, 108 insertions, 0 deletions
diff --git a/numpy/f2py/docs/TESTING.txt b/numpy/f2py/docs/TESTING.txt new file mode 100644 index 000000000..feae18dc6 --- /dev/null +++ b/numpy/f2py/docs/TESTING.txt @@ -0,0 +1,108 @@ + +======================================================= + F2PY unit testing site +======================================================= + +.. Contents:: + +Tests +----- + +* To run all F2PY unit tests in one command:: + + cd tests + python run_all.py [<options>] + + For example:: + + localhost:~/src_cvs/f2py2e/tests$ python2.2 run_all.py 100 --quiet + ********************************************** + Running '/usr/bin/python2.2 f77/return_integer.py 100 --quiet' + run 1000 tests in 1.87 seconds + initial virtual memory size: 3952640 bytes + current virtual memory size: 3952640 bytes + ok + ********************************************** + Running '/usr/bin/python2.2 f77/return_logical.py 100 --quiet' + run 1000 tests in 1.47 seconds + initial virtual memory size: 3952640 bytes + current virtual memory size: 3952640 bytes + ok + ... + + If some tests fail, try to run the failing tests separately (without + the ``--quiet`` option) as described below to get more information + about the failure. + +* Test intent(in), intent(out) scalar arguments, + scalars returned by F77 functions + and F90 module functions:: + + tests/f77/return_integer.py + tests/f77/return_real.py + tests/f77/return_logical.py + tests/f77/return_complex.py + tests/f77/return_character.py + tests/f90/return_integer.py + tests/f90/return_real.py + tests/f90/return_logical.py + tests/f90/return_complex.py + tests/f90/return_character.py + + Change to tests/ directory and run:: + + python f77/return_<type>.py [<options>] + python f90/return_<type>.py [<options>] + + where ``<type>`` is integer, real, logical, complex, or character. + Test scripts options are described below. + + A test is considered succesful if the last printed line is "ok". + + If you get import errors like:: + + ImportError: No module named f77_ext_return_integer + + but ``f77_ext_return_integer.so`` exists in the current directory then + it means that the current directory is not included in to `sys.path` + in your Python installation. As a fix, prepend ``.`` to ``PYTHONPATH`` + environment variable and rerun the tests. For example:: + + PYTHONPATH=. python f77/return_integer.py + +* Test mixing Fortran 77, Fortran 90 fixed and free format codes:: + + tests/mixed/run.py + +* Test basic callback hooks:: + + tests/f77/callback.py + +Options +------- + +You may want to use the following options when running the test +scripts: + +``<integer>`` + Run tests ``<integer>`` times. Useful for detecting memory leaks. Under + Linux tests scripts output virtual memory size state of the process + before and after calling the wrapped functions. + +``--quiet`` + Suppress all messages. On success only "ok" should be displayed. + +``--fcompiler=<Gnu|Intel|...>`` + Use:: + + f2py -c --help-fcompiler + + to find out what compilers are available (or more precisely, which + ones are recognized by ``scipy_distutils``). + +Reporting failures +------------------ + +XXX: (1) make sure that failures are due to f2py and (2) send full +stdout/stderr messages to me. Also add compiler,python,platform +information. |