MATLAB Programming Fundamentals - MathWorks

(やまだぃちぅ) #1
Done sampleTest
__________

ans =

1×3 TestResult array with properties:

Name
Passed
Failed
Incomplete
Duration
Details

Totals:
3 Passed, 0 Failed, 0 Incomplete.
0.0071673 seconds testing time.

In the Editor, place your cursor in the testB function and click the Run Current Test
icon. MATLAB runs testB only.

runtests('sampleTest','ProcedureName','testB')

Running sampleTest
.
Done sampleTest
__________

ans =

TestResult with properties:

Name: 'sampleTest/testB'
Passed: 1
Failed: 0
Incomplete: 0
Duration: 9.9411e-04
Details: [1×1 struct]

Totals:
1 Passed, 0 Failed, 0 Incomplete.
0.00099411 seconds testing time.

33 Unit Testing

Free download pdf