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


Python Server.executionStarts方法代码示例

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


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

示例1: test_isRunning_withExecution

# 需要导入模块: from server import Server [as 别名]
# 或者: from server.Server import executionStarts [as 别名]
	def test_isRunning_withExecution(self) :
		s = Server("fixture")
		s.createServer()
		s.createProject("myproject")
		s.createClient("myproject", "myclient")

		s.executionStarts(
			"myproject", "myclient", "20130301-132313",
			timestamp="2013-03-01 13:23:13",
			changelog=[])

		self.assertEqual(
			s.isRunning("myproject","myclient","20130301-132313"), True)
开发者ID:clam-project,项目名称:testfarm-server2,代码行数:15,代码来源:server_test.py

示例2: test_clientStatus_whenRunning

# 需要导入模块: from server import Server [as 别名]
# 或者: from server.Server import executionStarts [as 别名]
	def test_clientStatus_whenRunning(self) :
		s = Server("fixture")
		s.createServer()
		s.createProject("myproject")
		s.createClient("myproject", "myclient")

		s.executionStarts(
			"myproject", "myclient", "20130301-132313",
			timestamp="2013-03-01 13:23:13",
			changelog=[])

		self.assertEqual(
			s.clientStatus("myproject","myclient"), "Running")
开发者ID:clam-project,项目名称:testfarm-server2,代码行数:15,代码来源:server_test.py

示例3: emulateExecution

# 需要导入模块: from server import Server [as 别名]
# 或者: from server.Server import executionStarts [as 别名]
	def emulateExecution(self, name,
			ok = True, running = False,
			project='myproject', client='myclient', **keyw) :
		s = Server("fixture")
		s = ArgPrepender(s, project, client, name)
		timestamp = "{:%Y-%m-%d %H:%M:%S}".format(
			datetime.datetime.strptime(name, "%Y%m%d-%H%M%S"))
		s.executionStarts(
			timestamp=timestamp,
			changelog=[])
		s.taskStarts(1,"First task")
		if running: return
		s.taskEnds(1,ok)
		s.executionEnds(ok)
开发者ID:clam-project,项目名称:testfarm-server2,代码行数:16,代码来源:server_test.py

示例4: test_executions

# 需要导入模块: from server import Server [as 别名]
# 或者: from server.Server import executionStarts [as 别名]
	def test_executions(self) :
		s = Server('fixture')
		s.createServer()
		s.createProject("myproject")
		s.createClient("myproject","myclient")
		s.executionStarts("myproject", "myclient", "20130301-225341",
			timestamp="2013-03-01 22:53:41",
			changelog=[],
			)
		s.executionStarts("myproject", "myclient", "20130302-101313",
			timestamp="2013-03-02 10:13:13",
			changelog=[],
			)

		self.assertEqual(s.executions("myproject","myclient"), [
			'20130301-225341',
			'20130302-101313',
			])
开发者ID:clam-project,项目名称:testfarm-server2,代码行数:20,代码来源:server_test.py

示例5: emulateExecution

# 需要导入模块: from server import Server [as 别名]
# 或者: from server.Server import executionStarts [as 别名]
	def emulateExecution(client, name, tasks,
			project='myproject') :
		s = Server("fixture")
		s = ArgPrepender(s, project, client, name)
		timestamp = "{:%Y-%m-%d %H:%M:%S}".format(
			datetime.datetime.strptime(name, "%Y%m%d-%H%M%S"))
		s.executionStarts(
			timestamp=timestamp,
			changelog=[])
		for i, (task,commands) in enumerate(tasks) :
			s.taskStarts(i+1,task)
			for j, (line, ok, output, info, stats) in enumerate(commands) :
				s.commandStarts(i+1, j+1, line)
				if ok is None : return # Running or interrupted
				s.commandEnds(i+1, j+1,
					output=output,
					ok=ok,
					info=info,
					stats=stats)
				if ok is False : break # Failed, fatal for the task
			s.taskEnds(i+1,ok)
		s.executionEnds(ok)
开发者ID:clam-project,项目名称:testfarm-server2,代码行数:24,代码来源:webgenerator.py


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