Changeset 642 for branches


Ignore:
Timestamp:
Oct 21, 2007 2:36:50 AM (12 years ago)
Author:
jpfasano
Message:

Osi's unitTest is now considered a success if Sym completes 89 out of 90 netlib testcases

Location:
branches/testScripts
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/testScripts/NBcheckResult.py

    r639 r642  
    1313#------------------------------------------------------------------------
    1414def didTestFail( result, project, buildStep ) :
    15   retVal = 0
     15  retVal = None
    1616
    1717  # If the return code is not 0, then failure
    1818  if result['returnCode'] != 0 :
    19     retVal = 1
     19    retVal = "Non-zero return code of "+result['returnCode']
    2020
    2121  # Many tests write a "Success" message.
     
    2727         result['stdout'].rfind("All tests completed successfully") == -1 :
    2828        # Success message not found, assume test failed
    29         retVal = 1
     29        retVal = "The output does not contain the messages: 'All tests completed successfully'"
    3030
    3131  #---------------------------------------------------------------------
     
    4141    if not re.compile(reexp).match(msgTail,1) :
    4242      # message not found, assume test failed
    43       retVal = 1
     43      retVal = "Did not complete the woodw testcase"
    4444     
    4545  # Cbc's "make test"
     
    5151    if not re.compile(reexp).match(msgTail,1) :
    5252      # message not found, assume test failed
    53       retVal = 1
     53      retVal = "Did not dispaly message 'cbc_clp solved 2 out of 2 and took XX.XX seconds.'"
    5454
    5555  # Cbc's "./cbc -unitTest dirNetlib=_MIPLIB3DIR_ -miplib"
     
    6060      # ended because maxnodes limit reached.  John Forrest says if this
    6161      # is less than 3, the OK.
    62       retVal=0
     62      retVal=None
    6363    else :
    64       retVal=1
     64      retVal = "Return code of "+result['returnCode']+" which is > 2."
    6565
    6666  # DyLP's "make test"
     
    7777    if re.compile(reexp).match(result['stderr'],1) :
    7878      # message found, assume test failed
    79       retVal = 1
     79      retVal = "Issued message: 'SolverInterface tessting issue:'"
    8080    if re.compile(reexp).match(result['stdout'],1) :
    8181      # message found, assume test failed
    82       retVal = 1
     82      retVal = "Issued message: 'SolverInterface tessting issue:'"
    8383
    8484    if project=='DyLP' and buildStep==NBprojectConfig.UNITTEST_CMD['Osi'] or \
     
    8888      r=r'((.+) solved (\d+) out of 90 and took (\d*\.\d*) seconds)'
    8989      osisSummaryResult=re.findall(r,result['stdout'][-800:])
     90      expectedOsis=['clp','sym','dylp','cbcclp']
    9091      for osi in osisSummaryResult :
    91         if int(osi[2])<90 :
    92           #print osi[1]+" ran "+osi[2]+" out of 90 in "+osi[3]+" seconds"
    93           retVal=1
     92        if osi[1] in expectedOsis: expectedOsis.remove(osi[1])
     93        numSolved = int(osi[2])
     94        # Sym only solves 89 of the 90
     95        if osi[1]=='sym':
     96          if numSolved<89 :
     97            retVal=osi[1]+\
     98                 " only solved "\
     99                 +osi[2]\
     100                 +" out of 90 in "\
     101                 +osi[3]+" seconds"
     102        elif numSolved<90 :
     103          retVal=osi[1]+\
     104                 " only solved "\
     105                 +osi[2]+\
     106                 " out of 90 in "\
     107                 +osi[3]+" seconds"
     108      if len(expectedOsis)!=0 :
     109        retVal="Osi "+expectedOsis[0]+" did not report number solved"
    94110
    95111  return retVal
  • branches/testScripts/NBemail.py

    r635 r642  
    5151    emailMsg += "PATH: "+os.environ["PATH"]+"\n"
    5252
     53  if cmdMsgs.has_key('make test') :
     54    emailMsg += "\n\n'make test' problem:\n"
     55    emailMsg += cmdMsgs['make test']
     56    emailMsg += "\n"
     57  if cmdMsgs.has_key('unitTest') :
     58    emailMsg += "\n\nDetected problem:\n"
     59    emailMsg += cmdMsgs['unitTest']
     60    emailMsg += "\n"
     61
    5362  emailMsg +="\n"
    5463
     
    6069    emailMsg += "\n\nconfig.log messages are:\n"
    6170    emailMsg += cmdMsgs['config.log']
     71
    6272  send(toAddrs,subject,emailMsg)
    6373  NBlogMessages.writeMessage( "  email sent regarding "+project+" running '"+cmd+"'" )
  • branches/testScripts/nightlyBuild.py

    r640 r642  
    136136 
    137137  # Check if 'make test' worked
    138   if NBcheckResult.didTestFail(result,p,"make test") :
     138  didMakeTestFail=NBcheckResult.didTestFail(result,p,"make test")
     139  if didMakeTestFail :
     140    result['make test']=didMakeTestFail
    139141    NBemail.sendCmdMsgs(p,result,"make test")
    140142    continue
     
    154156    result=NBosCommand.run(unitTestCmd)
    155157 
    156     if NBcheckResult.didTestFail(result,p,unitTestCmdTemplate) :
     158    didUnitTestFail=NBcheckResult.didTestFail(result,p,unitTestCmdTemplate)
     159    if didUnitTestFail :
     160      result['unitTest']=didUnitTestFail
    157161      NBemail.sendCmdMsgs(p,result,unitTestCmd)
    158162      continue
Note: See TracChangeset for help on using the changeset viewer.