当前位置: 首页>>代码示例>>Python>>正文


Python MochitestOptions.verifyOptions方法代码示例

本文整理汇总了Python中mochitest_options.MochitestOptions.verifyOptions方法的典型用法代码示例。如果您正苦于以下问题:Python MochitestOptions.verifyOptions方法的具体用法?Python MochitestOptions.verifyOptions怎么用?Python MochitestOptions.verifyOptions使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在mochitest_options.MochitestOptions的用法示例。


在下文中一共展示了MochitestOptions.verifyOptions方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: run_desktop_mochitests

# 需要导入模块: from mochitest_options import MochitestOptions [as 别名]
# 或者: from mochitest_options.MochitestOptions import verifyOptions [as 别名]
def run_desktop_mochitests(parser, options):
    # create our Marionette instance
    marionette_args = {}
    if options.marionette:
        host, port = options.marionette.split(':')
        marionette_args['host'] = host
        marionette_args['port'] = int(port)
    mochitest = B2GDesktopMochitest(marionette_args, options.profile_data_dir)

    # add a -bin suffix if b2g-bin exists, but just b2g was specified
    if options.app[-4:] != '-bin':
        if os.path.isfile("%s-bin" % options.app):
            options.app = "%s-bin" % options.app

    options = MochitestOptions.verifyOptions(parser, options, mochitest)
    if options == None:
        sys.exit(1)

    if options.desktop and not options.profile:
        raise Exception("must specify --profile when specifying --desktop")

    options.browserArgs += ['-marionette']

    retVal = mochitest.runTests(options, onLaunch=mochitest.startTests)
    mochitest.message_logger.finish()

    sys.exit(retVal)
开发者ID:chenhequn,项目名称:gecko,代码行数:29,代码来源:runtestsb2g.py

示例2: verifyOptions

# 需要导入模块: from mochitest_options import MochitestOptions [as 别名]
# 或者: from mochitest_options.MochitestOptions import verifyOptions [as 别名]
    def verifyOptions(self, options, mochitest):
        # since we are reusing verifyOptions, it will exit if App is not found
        temp = options.app
        options.app = __file__
        tempPort = options.httpPort
        tempSSL = options.sslPort
        tempIP = options.webServer
        options = MochitestOptions.verifyOptions(self, options, mochitest)
        options.webServer = tempIP
        options.app = temp
        options.sslPort = tempSSL
        options.httpPort = tempPort

        return options 
开发者ID:,项目名称:,代码行数:16,代码来源:

示例3: verifyOptions

# 需要导入模块: from mochitest_options import MochitestOptions [as 别名]
# 或者: from mochitest_options.MochitestOptions import verifyOptions [as 别名]
    def verifyOptions(self, options, mochitest):
        # since we are reusing verifyOptions, it will exit if App is not found
        temp = options.app
        options.app = __file__
        tempPort = options.httpPort
        tempSSL = options.sslPort
        tempIP = options.webServer
        # We are going to override this option later anyway, just pretend
        # like it's not set for verification purposes.
        options.dumpOutputDirectory = None
        options = MochitestOptions.verifyOptions(self, options, mochitest)
        options.webServer = tempIP
        options.app = temp
        options.sslPort = tempSSL
        options.httpPort = tempPort

        return options
开发者ID:qiuyang001,项目名称:Spidermonkey,代码行数:19,代码来源:runtestsremote.py

示例4: main

# 需要导入模块: from mochitest_options import MochitestOptions [as 别名]
# 或者: from mochitest_options.MochitestOptions import verifyOptions [as 别名]
def main():
  automation = Automation()
  mochitest = Mochitest(automation)
  parser = MochitestOptions(automation)
  options, args = parser.parse_args()

  options = parser.verifyOptions(options, mochitest)
  if options == None:
    sys.exit(1)

  options.utilityPath = mochitest.getFullPath(options.utilityPath)
  options.certPath = mochitest.getFullPath(options.certPath)
  if options.symbolsPath and not isURL(options.symbolsPath):
    options.symbolsPath = mochitest.getFullPath(options.symbolsPath)

  automation.setServerInfo(options.webServer,
                           options.httpPort,
                           options.sslPort,
                           options.webSocketPort)
  sys.exit(mochitest.runTests(options))
开发者ID:,项目名称:,代码行数:22,代码来源:


注:本文中的mochitest_options.MochitestOptions.verifyOptions方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。