INNER CODE UNIT · Go

handleInterruptSignals

eksctl-io/eksctl · integration/main.go:67

func handleInterruptSignals() (context.Context, chan os.Signal) {
	interrupts := make(chan os.Signal, 1)
	ctx, cancel := context.WithCancel(context.Background())
	go func() {
		<-interrupts // Blocks here until interrupted
		log.Println("=========================== Shutdown signal received ===========================")
		// Signal cancellation to context.Context, which aborts ginkgo child
		// processes, letting them run AfterSuite to destroy all clusters, and
		// then letting them naturally terminate.
		cancel()
	}()
	return ctx, interrupts
}

func listModules() []string {
	testsDir := path.Join("integration", "tests")

	// TEST_SUITE_DIRS is a list of test suite directories to run

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…