本文整理汇总了Python中bzt.modules.blazemeter.BlazeMeterUploader.parameters['signature']方法的典型用法代码示例。如果您正苦于以下问题:Python BlazeMeterUploader.parameters['signature']方法的具体用法?Python BlazeMeterUploader.parameters['signature']怎么用?Python BlazeMeterUploader.parameters['signature']使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类bzt.modules.blazemeter.BlazeMeterUploader
的用法示例。
在下文中一共展示了BlazeMeterUploader.parameters['signature']方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: test_direct_feeding
# 需要导入模块: from bzt.modules.blazemeter import BlazeMeterUploader [as 别名]
# 或者: from bzt.modules.blazemeter.BlazeMeterUploader import parameters['signature'] [as 别名]
def test_direct_feeding(self):
obj = BlazeMeterUploader()
self.sniff_log(obj.log)
obj.engine = EngineEmul()
mock = BZMock(obj._user)
mock.mock_post.update({
'https://data.blazemeter.com/submit.php?session_id=direct&signature=sign&test_id=None&user_id=None&pq=0&target=labels_bulk&update=1': {},
'https://data.blazemeter.com/api/v4/image/direct/files?signature=sign': {"result": True},
'https://a.blazemeter.com/api/v4/sessions/direct/stop': {"result": True},
'https://data.blazemeter.com/submit.php?session_id=direct&signature=sign&test_id=None&user_id=None&pq=0&target=engine_health&update=1': {
'result': {'session': {}}}
})
mock.mock_get.update({
'https://a.blazemeter.com/api/v4/sessions/direct': {"result": {}}
})
mock.mock_patch.update({
'https://a.blazemeter.com/api/v4/sessions/direct': {"result": {}}
})
obj.parameters['session-id'] = 'direct'
obj.parameters['signature'] = 'sign'
obj.settings['token'] = 'FakeToken'
obj.prepare()
obj.startup()
obj.check()
obj.shutdown()
obj.engine.stopping_reason = TaurusException("To cover")
obj.post_process()
self.assertNotIn("Failed to finish online", self.log_recorder.warn_buff.getvalue())
self.assertEquals('direct', obj._session['id'])
self.assertEqual(9, len(mock.requests), "Requests were: %s" % mock.requests)