本文整理汇总了Python中webkitpy.port.Port.setup_environ_for_server方法的典型用法代码示例。如果您正苦于以下问题:Python Port.setup_environ_for_server方法的具体用法?Python Port.setup_environ_for_server怎么用?Python Port.setup_environ_for_server使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类webkitpy.port.Port
的用法示例。
在下文中一共展示了Port.setup_environ_for_server方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: make_driver
# 需要导入模块: from webkitpy.port import Port [as 别名]
# 或者: from webkitpy.port.Port import setup_environ_for_server [as 别名]
def make_driver(self, filesystem=None):
port = Port(MockSystemHost(log_executive=True, filesystem=filesystem), 'westondrivertestport', options=MockOptions(configuration='Release'))
port._config.build_directory = lambda configuration: "/mock_build"
port._server_process_constructor = MockServerProcess
driver = WestonDriver(port, worker_number=0, pixel_tests=True)
driver._startup_delay_secs = 0
driver._expected_xvfbdisplay = 23
driver._xvfbdriver = WestonXvfbDriverDisplayTest(driver._expected_xvfbdisplay)
driver._environment = port.setup_environ_for_server(port.driver_name())
return driver
示例2: make_driver
# 需要导入模块: from webkitpy.port import Port [as 别名]
# 或者: from webkitpy.port.Port import setup_environ_for_server [as 别名]
def make_driver(self, worker_number=0, xorg_running=False, executive=None):
port = Port(MockSystemHost(log_executive=True, executive=executive), 'xvfbdrivertestport', options=MockOptions(configuration='Release'))
port._config.build_directory = lambda configuration: "/mock-build"
port._server_process_constructor = MockServerProcess
if xorg_running:
port._executive._running_pids['Xorg'] = 108
driver = XvfbDriver(port, worker_number=worker_number, pixel_tests=True)
driver._startup_delay_secs = 0
driver._xvfb_screen_depth = lambda: '24'
driver._environment = port.setup_environ_for_server(port.driver_name())
return driver