Commit 55980d76 authored by 邓莹莹's avatar 邓莹莹

注释jsonpath

parent a2f442f5
...@@ -3,7 +3,7 @@ import random ...@@ -3,7 +3,7 @@ import random
import string import string
import requests import requests
import yaml import yaml
from jsonpath import jsonpath # from jsonpath import jsonpath
from login_session_function import LoginFunction from login_session_function import LoginFunction
# from pymysql import OperationalError # from pymysql import OperationalError
...@@ -28,10 +28,10 @@ class BaseRequest: ...@@ -28,10 +28,10 @@ class BaseRequest:
def api_load(self, path: object) -> object: def api_load(self, path: object) -> object:
return self.yaml_load(path) return self.yaml_load(path)
def jsonpath(self, path, r=None, **kwargs): # def jsonpath(self, path, r=None, **kwargs):
if r is None: # if r is None:
r = self.r.json() # r = self.r.json()
return jsonpath(r, path) # return jsonpath(r, path)
def api_send(self, req: object) -> object: def api_send(self, req: object) -> object:
host = self.api_load(path_setting.HOSTYAML_CONFIG) host = self.api_load(path_setting.HOSTYAML_CONFIG)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment