MCPcopy
hub / github.com/tsenart/vegeta / String

Method String

lib/pacer.go:166–168  ·  view source on GitHub ↗

String returns a pretty-printed description of the SinePacer's behaviour: SinePacer{ Period: time.Hour, Mean: Rate{100, time.Second}, Amp: Rate{50, time.Second}, StartAt: MeanDown, } => Sine{Constant{100 hits/1s} ± Constant{50 hits/1s} / 1h, offset 1𝛑}

()

Source from the content-addressed store, hash-verified

164// } =>
165// Sine{Constant{100 hits/1s} ± Constant{50 hits/1s} / 1h, offset 1𝛑}
166func (sp SinePacer) String() string {
167 return fmt.Sprintf("Sine{%s ± %s / %s, offset %g𝛑}", sp.Mean, sp.Amp, sp.Period, sp.StartAt/math.Pi)
168}
169
170// invalid tests the constraints documented in the SinePacer struct definition.
171func (sp SinePacer) invalid() bool {

Callers 9

TestLocalAddrFunction · 0.45
TestAttackConnectToFunction · 0.45
NthMethod · 0.45
decodeMethod · 0.45
encodeMethod · 0.45
TestResultEncodingFunction · 0.45
TestPlotFunction · 0.45

Calls

no outgoing calls

Tested by 4

TestLocalAddrFunction · 0.36
TestAttackConnectToFunction · 0.36
TestResultEncodingFunction · 0.36
TestPlotFunction · 0.36