2016-07-13 4 views
0

전 Gatling을 처음 사용합니다 지난 5 일 동안 아래 요청을 캡처하려고하는데 아래에 해당 항목을 연관시킬 수 없습니다 "sesskey" 내 전체에서 사용됩니다 흐름 : 위의 요청에Gatling 성능 테스트 도구를 사용하여 상관 관계 문제

.feed(feeder) 

    .exec(http("request_2") 
     .post("/login/index.php") 
     .headers(headers_0) 
     .formParam("username", "${username}") 
     .formParam("password", "${password}") 
     .formParam("anchor", "") 
     .resources(http("request_3") 
     .get("/theme/image.php/clean/core/1468244430/t/block_to_dock"), 
     http("request_4") 

    .get("/lib/javascript.php/1468244430/blocks/course_overview/module.js"), 
     http("request_5") 
     .get("/theme/image.php/clean/core/1468244430/t/collapsed"), 
     http("request_6") 
     .get("/theme/image.php/clean/core/1468244430/t/expanded"), 
     http("request_7") 
     .get("/lib/requirejs.php/1468244430/core/first.js"), 
     http("request_8") 
     .get("/theme/yui_combo.php?3.17.2/anim-base/anim-base.js&3.17.2/anim-color/anim-color.js&3.17.2/anim-xy/anim-xy.js&3.17.2/anim-curve/anim-curve.js&3.17.2/anim-easing/anim-easing.js&3.17.2/anim-node-plugin/anim-node-plugin.js&3.17.2/anim-scroll/anim-scroll.js"), 
     http("request_9") 
     .get("/lib/javascript.php/1468244430/lib/requirejs/jquery-private.js"), 
     http("request_10") 
     .get("/theme/yui_combo.php?3.17.2/cssbutton/cssbutton-min.css") 
     .headers(headers_10), 
     http("request_11") 
     .get("/lib/javascript.php/1468244430/lib/jquery/jquery-1.12.1.min.js"), 
     http("request_12") 
     .get("/theme/yui_combo.php?3.17.2/handlebars-base/handlebars-base.js&3.17.2/handlebars-compiler/handlebars-compiler.js&m/1468244430/core/handlebars/handlebars-debug.js&3.17.2/plugin/plugin.js&m/1468244430/core/lockscroll/lockscroll-debug.js&m/1468244430/core/notification/notification-ajaxexception-debug.js&m/1468244430/core/notification/notification-alert-debug.js&m/1468244430/core/notification/notification-exception-debug.js&m/1468244430/core_message/messenger/messenger-debug.js"), 
     http("request_13") 
     .get("/theme/yui_combo.php?m/1468244430/calendar/info/info.css") 
     .headers(headers_10), 
     http("request_14") 
     .get("/theme/yui_combo.php?m/1468244430/calendar/info/info-debug.js"), 
     http("request_15") 
     .post("/lib/ajax/service.php?sesskey=LuyCPEUwdm") 
     .headers(headers_1) 
     .body(RawFileBody("MoodleViewPageV01_0015_request.txt")), 
     http("request_16") 
     .get("/theme/yui_combo.php?m/1468244430/core/formautosubmit/formautosubmit-debug.js"), 
     http("request_17") 
     .get("/theme/yui_combo.php?3.17.2/event-mousewheel/event-mousewheel.js&3.17.2/event-resize/event-resize.js&3.17.2/event-hover/event-hover.js&3.17.2/event-touch/event-touch.js&3.17.2/event-move/event-move.js&3.17.2/event-flick/event-flick.js&3.17.2/event-valuechange/event-valuechange.js&3.17.2/event-tap/event-tap.js&3.17.2/event-simulate/event-simulate.js&3.17.2/async-queue/async-queue.js&3.17.2/gesture-simulate/gesture-simulate.js&3.17.2/node-event-simulate/node-event-simulate.js&m/1468244430/core/actionmenu/actionmenu-debug.js"), 
     http("request_18") 
     .get("/theme/image.php/clean/core/1468244430/t/switch_minus"), 
     http("request_19") 
     .get("/theme/image.php/clean/core/1468244430/t/switch_plus"))) 

, Request_15 당신이 .post("/lib/ajax/service.php?sesskey=LuyCPEUwdm")를 얻을 것이다 내 시나리오 동안 여러 번 사용하려고합니다 sesskey 값 LuyCPEUwdm를 캡처 할 위치.

어떻게 그 키를 캡처해야합니까?

당신의 시간 :

답변

0

나는 대답을 얻었다을 감사합니다 도와주세요.

여기에서 레코더를 사용하여 스크립트를 녹음 할 때 ... "& 응답 본문을 저장 하시겠습니까?"를 선택해야합니다. 옵션을 선택하고 다음 따라서, 귀하의 응답이

그래서 당신에게 ".. \ 개틀링 - 차트 - highcharts-번들-2.2.2 \ 사용자 파일 \ 몸"경로에 저장됩니다 완료 녹화 후

를 기록 이동 스크립트의 시나리오를 응답 본문 파일과 비교하고 응답 본문 파일의 캡처 된 값을 기반으로 해당 값을 상호 연관시킬 수 있습니다.