CElegansNeuroML icon indicating copy to clipboard operation
CElegansNeuroML copied to clipboard

Test python scripts

Open travs opened this issue 10 years ago • 4 comments

Some scripts in this directory can be tested using a framework like pytest.

A rudimentary example would be to run RegenerateConnectome and look for a 0 exit code (i.e. the script exited successfully).

Higher value tests can compare the outputs of these modules to an expected output, or run specific functions defined in them. This will vary depending on the actual script in question.

For now, let's enumerate some modules, and possible tests that could provide a benefit:

travs avatar Aug 23 '15 16:08 travs

Have added more Python scripts that can be tested. See also note here: https://github.com/openworm/CElegansNeuroML/blob/master/CElegans/pythonScripts/README.md

pgleeson avatar Aug 23 '15 16:08 pgleeson

@brijeshmodi12 have a look at this as well.

slarson avatar Apr 11 '16 22:04 slarson

These are all currently tested in the .travis.yml.

pgleeson avatar Apr 12 '16 08:04 pgleeson

Pytest added: All 3 files: RegenerateConnectome.py, SpreadsheetDataReader.py, OpenWormReader.py are now being tested via py.test.

Test passed successfully on Travis https://travis-ci.org/brijeshmodi12/CElegansNeuroML/jobs/135151497#L1717

brijeshmodi12 avatar Jun 04 '16 05:06 brijeshmodi12