-
Notifications
You must be signed in to change notification settings - Fork 5
TestingSuite
e-lo edited this page Mar 17, 2015
·
1 revision
We are using the nose python software package, which extends the built in python unit test package.
To install nose from the command line (must have setup tools installed):
easy_install nose
Nose uses a regex that recognizes test_ and Test_ to find what it needs to run.
Basically:
- Put all tests in the
\testsub-folder - Name test python files with something that starts with
test_ - `import nose.tools' should be used to make sure nose is included.
- Write functions that start with
test_that you want to be run. - Each function should have an
assertline, where the answer the function gets should be compared with the 'known answer' - All data needed to run the tests should be included in the
testDatasub-folder