3. MATLAB Developer Environment

Developers will typically work in the local clone setup as suggested for users in the Getting Started section of the User Guide. Setting up and running general testing on the full MATLAB contents should also be done as detailed in the Getting Started section, which includes ensuring that BenDFO is up-to-date.

3.1. Full Code Coverage

The testing procedure provided in the Getting Started section runs the full test suite with coverage enabled. The test output indicates where the HTML-format code coverage report can be found.

3.2. Low-level Testing

To run tests of a single MATLAB-based method at a lower level, add

/path/to/BenDFO/data
/path/to/BenDFO/m

to the MATLAB path.

To test the method without measuring coverage,

  1. change to the <method>/m/tests directory,

  2. open MATLAB, and

  3. execute runtests from the prompt.

To test with coverage enabled,

  1. change to the <method>/m directory,

  2. open MATLAB, and

  3. execute runtests("IncludeSubfolders", true, "ReportCoverageFor", pwd)

The test output indicates where the HTML-format code coverage report can be found.

Users can also run each test function individually with runtests as usual if so desired. Please refer to the inline documentation of each test or test case for more information on how to run the test.