parameters: (self, testname)
docstring: Do things before running each test.
docstring_summary: Do things before running each test.
docstring_tokens: Do things before running each test .
function: def BeforeRunOneTest(self, testname):
      """Do things before running each test."""
      if not self.IsWindows():
        return
      # Stop old counters if needed
      cmdlist = [self.perf, '-shutdown']
      self.Run(cmdlist, ignore_error=True)
      # Instrument binaries
      for fulltest in self.tests:
        if os.path.exists(fulltest):
          # See http://support.microsoft.com/kb/939818 for details on args
          cmdlist = [self.instrument, '/d:ignorecverr', '/COVERAGE', fulltest]
          self.Run(cmdlist, ignore_retcode=4,
                   explanation='OK with a multiple-instrument')
      # Start new counters
      cmdlist = [self.perf, '-start:coverage', '-output:' + self.vsts_output]
      self.Run(cmdlist)
function_tokens: def BeforeRunOneTest ( self , testname ) : if not self . IsWindows ( ) : return # Stop old counters if needed cmdlist = [ self . perf , '-shutdown' ] self . Run ( cmdlist , ignore_error = True ) # Instrument binaries for fulltest in self . tests : if os . path . exists ( fulltest ) : # See http://support.microsoft.com/kb/939818 for details on args cmdlist = [ self . instrument , '/d:ignorecverr' , '/COVERAGE' , fulltest ] self . Run ( cmdlist , ignore_retcode = 4 , explanation = 'OK with a multiple-instrument' ) # Start new counters cmdlist = [ self . perf , '-start:coverage' , '-output:' + self . vsts_output ] self . Run ( cmdlist )