?????????????????п????????????????????????
???????????£????????????????????????????磬??????????????????????????????????????????????д?????????????????????????????????????????????а?????????????session?????????????????????????????????????????????????????????????????????????????????????????????????
???????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????? AppiumBooster ???????????????????????????????????????????????????????????????????????????????????????????????????
????????????????????????????????????????????????????????????ε?????????????????????????????????????????????????????????????????????????????????????????????????????????????????У???????? ${??????} ???ɡ?
??????????з????????????????ò?????????????ò?????????????в???
????????????е??????????????????y???????????????????????????н????????????????????????????????????????????y??????????и???????? ?????+??????? ??????
???????????????????ò??????????????????????????????????????????????????????????????????????????????????????У????????????????????????????????????????????
?????????????????????????????????????????????????????????????????????????????????????????????????????????????????в????????????????????????????????
????????????????????????????????????壬?????????????????????????????????????????????У?顢??????????????????????????????????????ε?????
????????????????????????????????????????????????????????????Σ????????????????????????????????????????????????????????????????????????úú???????????????????????????????????????????????????????????????????????????????????????????
?????????????????????????????????????????????????????????????????
???????????????棬???????????????????“???”?????????????????????????????????ж????н????????????????ɡ???“????”?????????????????????????????????????????y??????????????????????????????????????????????????????????????
????????? locust ????????? HTTP ????? ????????????????????????????????????????? requests.Session ???????? HttpSession ????д?????? request ??????????? request ?????ж? requests.Session.request ?????????????
??request_meta = {}
????# set up pre_request hook for attaching meta data to the request object
????request_meta["method"] = method
????request_meta["start_time"] = time.time()
????response = self._send_request_safe_mode(method?? url?? **kwargs)
????# record the consumed time
????request_meta["response_time"] = int((time.time() - request_meta["start_time"]) * 1000)
????request_meta["content_size"] = int(response.headers.get("content-length") or 0)
?????? HttpLocust ???????????????client????????? HttpSession ????????????????? HTTP ????????????????? Requests ????????????????????????????????С??????????????б??棬????ν????????
???????????????????????????????????????????????????????磬????? Response ?? Headers ?? Body ???????????????д???
request_meta["response_headers"] = response.headers
request_meta["response_content"] = response.content
?????????????????????????????????????????????????Locust??
?????????????????????????????????????????????????????Χ?????????????????????????????????????????????????????????????????????????????????????
??????????? locust ?????????????????????????????????????????
????????????? HttpLocust ???????????????client????????? HttpSession ??????? HttpSession ?????? requests.Session ?????? HttpLocust ???????????????client????? requests.Session ????????
?????????????????? Requests ??????????????????????????? requests.Session ??????????????????????? requests ????÷???
?????????????÷???????
??resp = requests.get('http://debugtalk.com')
????# ?????
????client = requests.Session()
????resp = client.get('http://debugtalk.com')
????????????????????????????????????????????л????????????????????????????????·??????? HTTP ??????
def __init__(self?? origin?? kwargs?? http_client_session=None):
????   self.http_client_session = http_client_session or requests.Session()
???????????£? http_client_session ?? requests.Session ?????????????н????????????????????????????????? locust ?? HttpSession ??????ɡ?
???????п?????????????????Web????
?????????????????????????????????壨?????????????????????????????Web???????????????Web?????????????????????????????????????á???????????????й?????????????
???????????????????????? Web?? ????????????????????????????????????????????У?CLI?????÷?????淶??????洢????????????Web??????Flask?????????Web???????
????д?????
?????????????? ApiTestEngine ??????????????????????????????????? ???????? ???????????