package goroutines
import "github.com/uber/tchannel-go/testutils/goroutines"
Index ¶
- func VerifyNoLeaks(t *testing.T, opts *VerifyOpts)
- type Stack
- func GetAll() []Stack
- func (s Stack) Full() []byte
- func (s Stack) ID() int
- func (s Stack) State() string
- func (s Stack) String() string
- type VerifyOpts
Functions ¶
func VerifyNoLeaks ¶
func VerifyNoLeaks(t *testing.T, opts *VerifyOpts)
VerifyNoLeaks verifies that there are no goroutines running that are stuck inside of readFrames or writeFrames. Since some goroutines may still be performing work in the background, we retry the checks if any goroutines are fine in a running state a finite number of times.
Types ¶
type Stack ¶
type Stack struct {
// contains filtered or unexported fields
}
Stack represents a single Goroutine's stack.
func GetAll ¶
func GetAll() []Stack
GetAll returns the stacks for all running goroutines.
func (Stack) Full ¶
Full returns the full stack trace for this goroutine.
func (Stack) ID ¶
ID returns the goroutine ID.
func (Stack) State ¶
State returns the Goroutine's state.
func (Stack) String ¶
type VerifyOpts ¶
type VerifyOpts struct { // Exclude is a string that will exclude a stack from being considered a leak. Exclude string }
VerifyOpts contains
func (*VerifyOpts) ShouldSkip ¶
func (opts *VerifyOpts) ShouldSkip(s Stack) bool
ShouldSkip returns whether the given stack should be skipped when doing verification.
Source Files ¶
stacks.go verify.go verify_opts.go
- Version
- v1.0.4
- Published
- Mar 10, 2016
- Platform
- js/wasm
- Imports
- 9 packages
- Last checked
- 11 hours ago –
Tools for package owners.