Exemplo n.º 1
0
Arquivo: test.py Projeto: dornja/goa2
 def getParallelFitness( self, *args ):
     results = ParallelTest.getParallelFitness( self, *args )
     if self.options.error:
         if results == [ [ 0 ] ]:
             return [ [ 0 ], [ 0 ] ]
         results.append( self.error )
     return results
Exemplo n.º 2
0
Arquivo: test.py Projeto: dornja/goa2
 def getParallelFitness( self, *args ):
     with mktemp( prefix = "vips" ) as tmpexe:
         oldexe = self.exe
         shutil.copyfile( self.exe, tmpexe )
         shutil.copymode( self.exe, tmpexe )
         try:
             self.exe = tmpexe
             results = ParallelTest.getParallelFitness( self, *args )
             if self.options.error:
                 if results == [ [ 0 ] ]:
                     return [ [ 0 ], [ 0 ] ]
                 results.append( self.error )
                 return results
             else:
                 return results
         finally:
             self.exe = oldexe