主动防御接口case
This commit is contained in:
27
02-Keyword/tsg_bfapi/Log_keyword.robot
Normal file
27
02-Keyword/tsg_bfapi/Log_keyword.robot
Normal file
@@ -0,0 +1,27 @@
|
||||
*** Settings ***
|
||||
Library REST
|
||||
Library string
|
||||
Library Collections
|
||||
Library OperatingSystem
|
||||
Library RequestsLibrary
|
||||
Resource ../tsg_bfapi/ApiRequest.robot
|
||||
Resource ../../03-Variable/BifangApiVariable.txt
|
||||
Library json
|
||||
|
||||
*** Variables ***
|
||||
|
||||
*** Keywords ***
|
||||
GetLogCondition
|
||||
[Arguments] ${logname} ${start_time} ${end_time} ${page_size} ${page_no} ${condition1}
|
||||
${responsedata} Get-Request log/schema?logType=active_defence_event_log
|
||||
${fields} Set Variable ${responsedata['data']['fields']}
|
||||
${field} json.dumps ${fields}
|
||||
log ${field}
|
||||
${startTime} Set Variable ${start_time}
|
||||
${endTime} Set Variable ${end_time}
|
||||
${pageSize} Set Variable ${page_size}
|
||||
${pageNo} Set Variable ${page_no}
|
||||
${condition} Set Variable ${condition1}
|
||||
${logCondition} Set Variable {"pageNo":${pageNo},"pageSize":${pageSize},"logType":"${logname}","fields":${field},"start_common_recv_time":"${startTime}","end_common_recv_time":"${endTime}","conditions":${condition}}
|
||||
log this time query condition:${logCondition}
|
||||
[Return] ${logCondition}
|
||||
Reference in New Issue
Block a user