Changeset 22

Show
Ignore:
Timestamp:
11/11/08 12:18:06 (2 months ago)
Author:
mgalloy
Message:

Added output keywords NPASS and NTESTS to allow scripts running MGUNIT to retrieve the number of passing and total tests.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/mgunit/src/mgunit.pro

    r17 r22  
    1414;    html : in, optional, type=boolean 
    1515;       set to indicate HTML output instead of plain text 
     16;    npass : out, optional, type=long 
     17;       number of tests that passed 
     18;    ntests : out, optional, type=long 
     19;       number of tests       
    1620;- 
    17 pro mgunit, tests, filename=filename, html=html 
     21pro mgunit, tests, filename=filename, html=html, npass=npass, ntests=ntests 
    1822  compile_opt strictarr 
    1923 
    2024  runnerName = keyword_set(html) ? 'MGutHTMLRunner' : 'MGutCliRunner' 
    2125  testRunner = obj_new(runnerName, filename=filename) 
     26   
     27  npass = 0L 
     28  nfail = 0L 
    2229   
    2330  if (n_elements(tests) gt 0) then begin 
     
    2734    testsuite->add, tests 
    2835    testsuite->run 
     36    testsuite->getProperty, npass=npass, ntests=ntests 
    2937    obj_destroy, testsuite 
    3038  endif