當前位置: 首頁>>代碼示例>>Python>>正文


Python RuntestBase.preProcessTests方法代碼示例

本文整理匯總了Python中util.runtestBase.RuntestBase.preProcessTests方法的典型用法代碼示例。如果您正苦於以下問題:Python RuntestBase.preProcessTests方法的具體用法?Python RuntestBase.preProcessTests怎麽用?Python RuntestBase.preProcessTests使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在util.runtestBase.RuntestBase的用法示例。


在下文中一共展示了RuntestBase.preProcessTests方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。

示例1: preProcessTests

# 需要導入模塊: from util.runtestBase import RuntestBase [as 別名]
# 或者: from util.runtestBase.RuntestBase import preProcessTests [as 別名]
 def preProcessTests(self):
     RuntestBase.preProcessTests(self)
     # Are we running esc - depends on a valid avm
     if self.runESC:
         self.runSource = True
         # generate the executable cmd for esc
         #escAbcs = [f for f in os.listdir(self.escbin) if f.endswith('.abc')] #not all abcs are used for esc
         escAbcs = ['debug','util','bytes-tamarin','util-tamarin','lex-char','lex-token',
                    'lex-scan','ast','ast-decode','parse','asm','abc','emit','cogen',
                    'cogen-stmt','cogen-expr','esc-core','eval-support','esc-env','main']
         if not self.escbin.endswith('/'):
             self.escbin += '/'
         for f in escAbcs:
             self.avm += ' %s%s.es.abc' % (self.escbin, f)
         self.avm += ' -- '
         self.avm += ' %s../test/spidermonkey-prefix.es' % self.escbin  #needed to run shell harness
     if self.androidthreads:
         p=subprocess.Popen('adb devices',shell=True,stdout=subprocess.PIPE,stderr=subprocess.PIPE)
         (out,err)=p.communicate()
         out = out.decode('latin_1','replace')
         out = out.split('\n')
         for line in out:
             items=line.split()
             if len(items)==2 and items[1]=='device':
                 for i in range(self.threads):
                     self.androiddevices.append(items[0])
         if len(self.androiddevices)==0:
             print("error: adb did not detect any attached devices")
             print("adb devices stdout: %s stderr: %s" % (out,err))
             sys.exit(1)
         print("detected %d android devices" % (len(self.androiddevices)/self.threads))
         self.threads=len(self.androiddevices)
開發者ID:bsdf,項目名稱:trx,代碼行數:34,代碼來源:runtests.py

示例2: preProcessTests

# 需要導入模塊: from util.runtestBase import RuntestBase [as 別名]
# 或者: from util.runtestBase.RuntestBase import preProcessTests [as 別名]
 def preProcessTests(self):
     RuntestBase.preProcessTests(self)
     # Are we running esc - depends on a valid avm
     if self.runESC:
         self.runSource = True
         # generate the executable cmd for esc
         #escAbcs = [f for f in os.listdir(self.escbin) if f.endswith('.abc')] #not all abcs are used for esc
         escAbcs = ['debug','util','bytes-tamarin','util-tamarin','lex-char','lex-token',
                    'lex-scan','ast','ast-decode','parse','asm','abc','emit','cogen',
                    'cogen-stmt','cogen-expr','esc-core','eval-support','esc-env','main']
         if not self.escbin.endswith('/'):
             self.escbin += '/'
         for f in escAbcs:
             self.avm += ' %s%s.es.abc' % (self.escbin, f)
         self.avm += ' -- '
         self.avm += ' %s../test/spidermonkey-prefix.es' % self.escbin  #needed to run shell harness
開發者ID:zwetan,項目名稱:tessa,代碼行數:18,代碼來源:runtests.py


注:本文中的util.runtestBase.RuntestBase.preProcessTests方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。