Ignore:
Timestamp:
Nov 2, 2007 9:55:56 AM (13 years ago)
Author:
jpfasano
Message:

Mofified NBcheckResult so that it is a bunch of small functions that check for one specific thing.
NBprojectConfig now defines a dictionary where the key is the project.
The value is a list of functions that need to be run to check the success of a particular test run.
The code still needs to be cleaned up, but it seems to be running and was time to do a check-in so I can move it to other platforms for testing.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/testScripts/NBbuildConfig.py

    r718 r730  
    299299
    300300  # Check if 'make test' worked
    301   didMakeTestFail=configuration['checkMakeTest'](result,configuration['project'],"make test")
    302   if didMakeTestFail :
    303     result['configure flags']=configOptions
    304     result['svn version']=configuration['svnVersion']
    305     result['make test']=didMakeTestFail
    306     NBemail.sendCmdMsgs(configuration['project'],result,"make test")
    307     return
     301  for testFunc in configuration['checkMakeTest'] :
     302    testResultFail=testFunc(result,configuration['project'])
     303    if testResultFail :
     304      result['configure flags']=configOptions
     305      result['svn version']=configuration['svnVersion']
     306      result['make test']=testResultFail
     307      NBemail.sendCmdMsgs(configuration['project'],result,"make test")
     308      return
     309
    308310
    309311  #---------------------------------------------------------------------
     
    334336    stderrfile.close()
    335337
    336     didUnitTestFail=configuration['unitTest']['checkUnitTest'](result,configuration['project'],unitTestCmdTemplate)
    337     if didUnitTestFail :
    338       result['configure flags']=configOptions
    339       result['svn version']=configuration['svnVersion']
    340       result['unitTest']=didUnitTestFail
    341       NBemail.sendCmdMsgs(p,result,unitTestCmd)
    342       return
     338    #didUnitTestFail=configuration['unitTest']['checkUnitTest'](result,configuration['project'],unitTestCmdTemplate)
     339    #if didUnitTestFail :
     340    #  result['configure flags']=configOptions
     341    #  result['svn version']=configuration['svnVersion']
     342    #  result['unitTest']=didUnitTestFail
     343    #  NBemail.sendCmdMsgs(p,result,unitTestCmd)
     344    #  return
     345   
     346    for testFunc in configuration['unitTest']['checkUnitTest'] :
     347      testResultFail=testFunc(result,configuration['project'])
     348      if testResultFail :
     349        result['configure flags']=configOptions
     350        result['svn version']=configuration['svnVersion']
     351        result['unitTest']=testResultFail
     352        NBemail.sendCmdMsgs(configuration['project'],result,unitTestCmd)
     353        return
    343354
    344355
Note: See TracChangeset for help on using the changeset viewer.