...

Package interrupt_handler

import "github.com/onsi/ginkgo/v2/internal/interrupt_handler"
Overview
Index

Overview ▾

Variables

var ABORT_POLLING_INTERVAL = 500 * time.Millisecond

func SwallowSigQuit

func SwallowSigQuit()

type InterruptCause

type InterruptCause uint
const (
    InterruptCauseInvalid InterruptCause = iota
    InterruptCauseSignal
    InterruptCauseAbortByOtherProcess
)

func (InterruptCause) String

func (ic InterruptCause) String() string

type InterruptHandler

type InterruptHandler struct {
    // contains filtered or unexported fields
}

func NewInterruptHandler

func NewInterruptHandler(client parallel_support.Client, signals ...os.Signal) *InterruptHandler

func (*InterruptHandler) Status

func (handler *InterruptHandler) Status() InterruptStatus

func (*InterruptHandler) Stop

func (handler *InterruptHandler) Stop()

type InterruptHandlerInterface

type InterruptHandlerInterface interface {
    Status() InterruptStatus
}

type InterruptLevel

type InterruptLevel uint
const (
    InterruptLevelUninterrupted InterruptLevel = iota
    InterruptLevelCleanupAndReport
    InterruptLevelReportOnly
    InterruptLevelBailOut
)

type InterruptStatus

type InterruptStatus struct {
    Channel chan interface{}
    Level   InterruptLevel
    Cause   InterruptCause
}

func (InterruptStatus) Interrupted

func (s InterruptStatus) Interrupted() bool

func (InterruptStatus) Message

func (s InterruptStatus) Message() string

func (InterruptStatus) ShouldIncludeProgressReport

func (s InterruptStatus) ShouldIncludeProgressReport() bool