Skip to content

Commit

Permalink
Fix function names in documentation's comments (#3669)
Browse files Browse the repository at this point in the history
Signed-off-by: reallylowest <sunjinping@outlook.com>
  • Loading branch information
reallylowest authored Apr 3, 2024
1 parent aa9ce17 commit 2af1a3f
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion js/modules/k6/experimental/tracing/encoding.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"math/rand"
)

// randHexStringRunes returns a random string of n hex characters.
// randHexString returns a random string of n hex characters.
//
// Note that this function uses a non-cryptographic random number generator.
func randHexString(n int) string {
Expand Down
2 changes: 1 addition & 1 deletion js/modules/k6/grpc/listeners.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ func (l *eventListener) add(fn func(goja.Value) (goja.Value, error)) {
l.list = append(l.list, fn)
}

// getTypes return event listener of a certain type
// getType return event listener of a certain type
func (l *eventListeners) getType(t string) *eventListener {
switch t {
case eventData:
Expand Down
2 changes: 1 addition & 1 deletion js/modules/k6/grpc/teststate_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ func newTestState(t *testing.T) testState {
return ts
}

// ToInitContext moves the test state to the VU context.
// ToVUContext moves the test state to the VU context.
func (ts *testState) ToVUContext() {
registry := metrics.NewRegistry()
root, err := lib.NewGroup("", nil)
Expand Down
4 changes: 2 additions & 2 deletions metrics/thresholds_parser.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ func (te *thresholdExpression) SinkKey() string {
return te.AggregationMethod
}

// parseThresholdAssertion parses a threshold condition expression,
// parseThresholdExpression parses a threshold condition expression,
// as defined in a JS script (for instance p(95)<1000), into a thresholdExpression
// instance.
//
Expand Down Expand Up @@ -181,7 +181,7 @@ var aggregationMethodTokens = [8]string{ //nolint:gochecknoglobals
tokenPercentile,
}

// parseThresholdMethod will parse a threshold condition expression's method.
// parseThresholdAggregationMethod will parse a threshold condition expression's method.
// It assumes the provided input argument is already trimmed and cleaned up.
// If it encounters a percentile method, it will parse it and verify it
// boils down to an expression of the form: `p(float64)`, but will return
Expand Down

0 comments on commit 2af1a3f

Please sign in to comment.