Testing - OpenTrading/OpenTrader GitHub Wiki
UseCases proceed to getting fleshed out as Features. Features are implemented as Gherkin feature files, and tested using behave. If you have installed behave>=1.2.5 before installing OpenTrader, then you should be able to run the test suite from the top-level directory with:
python setup.py behave_test
YMMV :-)
The features can be found in the tests/features/ directory of the distribution.
For the details of our BDD testing, and the currently documented features, see TestsFeatures.
Features that are implemented as commands in OTCmd2 also have tests as examples.Because OTCmd2 is a cmd2 application, not only can it interpret commands in an interactive loop, but it can read a list of commands from the stdin. This can be used to give examples of typical UseCases.
This makes it easy to write scripts as complete UseCase tests, giving good coverage. At the same time, it gives end-users a catalogue of complete working examples.
For the currently scripted examples, see TestsExamples.
Parent: Home