Test Results¶
This section contains the results of the test scripts developed by Nautules Pi. The section below describes how the test results were obtained.
pytest | Runnable | Run | Result (x out of 5 times) |
---|---|---|---|
TestFixedDetect.py (from TestImageCropper) | yes | 5 | Passed (5/5) |
TestPreprocessor.py (from TestImageCropper) | yes | 5 | Passed (5/5) |
TestAutoDetect.py (from TestImageCropper) | yes | 5 | Failed (4/5) |
TestManualDetect.py (from TestImageCropper) | yes | 5 | Passed (5/5) |
TestPreProcessor.py | yes | 5 | Passed (5/5) |
TestReadDisplay.py | yes | 5 | Failed (5/5) |
test_AutoCrop.py | No: error | 5 | n.v.t. |
Run a singel test¶
$ pip install pytest
This will install the pytest libraries. Now you can run your test:
$ cd path/to/project
$ pytest 'filename.py'
Repeat a test¶
pip install pytest repeat
Use the –count command line option to specify how many times you want your test, or tests, to be run:
$ py.test --count = 'choose a number' test_file.py
Each test collected by py.test will be run count times.
Run all tests in once¶
$ pip install nose
This will install the nose libraries, as well as the nosetests script, which you can use to automatically discover and run tests. Now you can run all tests in a specified folder in once, using only one command:
$ cd path/to/project
$ nosetests -vv