fiddler工具中想查看接口的響應時間可以通過
1、工具欄中rules->customize Rules
2、打開文件吧如下代碼添加到headers中
function BeginRequestTime(oS: Session)
{
if (oS.Timers != null)
{
return oS.Timers.ClientBeginRequest.ToString();
}
return String.Empty;
}
public static BindUIColumn("Time Taken")
function CalcTimingCol(oS: Session){
var sResult = String.Empty;
if ((oS.Timers.ServerDoneResponse > oS.Timers.ClientDoneRequest))
{
sResult = (oS.Timers.ServerDoneResponse - oS.Timers.ClientDoneRequest).ToString();
}
return sResult;
}
添加成功后如下圖所示
添加中customize Rules 會出現打不開或出錯的情況,可以直接搜索電腦中的customRules.js,直接貼到headers中也可以實現