package
0.57.0
Repository: https://github.com/grafana/k6.git
Documentation: pkg.go.dev

# Functions

ApplyCustomUserMetadata modifies the given metrics.TagsAndMeta object with the given custom metadata and their value.
ApplyCustomUserTag modifies the given metrics.TagsAndMeta object with the given custom tag and theirs value.
ApplyCustomUserTags modifies the given metrics.TagsAndMeta object with the user specified custom tags and metadata.
FieldName Returns the JS name for an exported struct field.
FreezeObject replicates the JavaScript Object.freeze function.
GetReader tries to return an io.Reader value from an exported Sobek value.
IsAsyncFunction checks if the provided value is an AsyncFunction.
IsNullish checks if the given value is nullish, i.e.
MethodName Returns the JS name for an exported method.
NewInitContextError returns a new InitContextError with the provided message.
NewRandSource is copied from Sobek's source code: https://github.com/grafana/sobek/blob/master/sobek/main.go#L44 The returned RandSource is NOT safe for concurrent use: https://golang.org/pkg/math/rand/#NewSource.
Throw a JS error; avoids re-wrapping GoErrors.
ToBytes tries to return a byte slice from compatible types.
ToString tries to return a string from compatible types.
UnwrapSobekInterruptedError returns the internal error handled by Sobek.

# Structs

Events are the event subscriber interfaces for the global event system, and the local (per-VU) event system.
FieldNameMapper for sobek.Runtime.SetFieldNameMapper().
InitEnvironment contains properties that can be accessed by Go code executed in the k6 init context.

# Type aliases

InitContextError is an error that happened during the a test init context.