quick

package
v1.19.0-beta2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 19, 2025 License: BSD-2-Clause Imports: 0 Imported by: 0

Documentation

Rendered for js/wasm

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GopherJSInternalMaxCountCap

func GopherJSInternalMaxCountCap(newCap int) (restore func())

GopherJSInternalMaxCountCap sets an upper bound of iterations quick test may perform. THIS IS GOPHERJS-INTERNAL API, DO NOT USE IT OUTSIDE OF THE GOPHERJS CODEBASE, IT MAY CHANGE OR DISAPPEAR WITHOUT NOTICE.

This function can be used to limit run time of standard library tests which use testing/quick with too many iterations for GopherJS to complete in a reasonable amount of time. This is a better compromise than disabling a slow test entirely.

//gopherjs:keep-original
func TestFoo(t *testing.T) {
    t.Cleanup(quick.GopherJSInternalMaxCountCap(100))
    _gopherjs_original_TestFoo(t)
}

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL