mirror of
https://github.com/httprunner/httprunner.git
synced 2026-06-02 22:39:42 +08:00
feat: stat HTTP request latencies (DNSLookup, TCP Connection and so on)
This commit is contained in:
@@ -54,6 +54,7 @@ func NewRunner(t *testing.T) *HRPRunner {
|
||||
type HRPRunner struct {
|
||||
t *testing.T
|
||||
failfast bool
|
||||
httpStatOn bool
|
||||
requestsLogOn bool
|
||||
pluginLogOn bool
|
||||
saveTests bool
|
||||
@@ -100,6 +101,13 @@ func (r *HRPRunner) SetRequestsLogOn() *HRPRunner {
|
||||
return r
|
||||
}
|
||||
|
||||
// SetHTTPStatOn turns on HTTP latency stat.
|
||||
func (r *HRPRunner) SetHTTPStatOn() *HRPRunner {
|
||||
log.Info().Msg("[init] SetHTTPStatOn")
|
||||
r.httpStatOn = true
|
||||
return r
|
||||
}
|
||||
|
||||
// SetPluginLogOn turns on plugin logging.
|
||||
func (r *HRPRunner) SetPluginLogOn() *HRPRunner {
|
||||
log.Info().Msg("[init] SetPluginLogOn")
|
||||
|
||||
Reference in New Issue
Block a user