- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 35 for errchk (0.17 sec)
-
test/fixedbugs/bug223.go
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Sep 23 20:27:09 UTC 2022 - 514 bytes - Viewed (0) -
pkg/kube/portforwarder.go
fw, err = f.buildK8sPortForwarder(readyCh) if err != nil { f.errCh <- fmt.Errorf("building port forwarded: %v", err) return } if err = fw.ForwardPorts(); err != nil { log.Errorf("port forward failed: %v", err) f.errCh <- fmt.Errorf("port forward: %v", err) return } log.Infof("port forward completed without error") f.errCh <- nil
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Mon Aug 14 02:12:37 UTC 2023 - 5.5K bytes - Viewed (0) -
pkg/scheduler/framework/parallelize/error_channel_test.go
import ( "context" "errors" "testing" ) func TestErrorChannel(t *testing.T) { errCh := NewErrorChannel() if actualErr := errCh.ReceiveError(); actualErr != nil { t.Errorf("expect nil from err channel, but got %v", actualErr) } err := errors.New("unknown error") errCh.SendError(err) if actualErr := errCh.ReceiveError(); actualErr != err { t.Errorf("expect %v from err channel, but got %v", err, actualErr) }
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Oct 20 17:39:23 UTC 2021 - 1.3K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/pkg/storage/cacher/ready_test.go
"sync" "testing" "time" ) func Test_newReady(t *testing.T) { errCh := make(chan error, 10) ready := newReady() ready.set(false) // create 10 goroutines waiting for ready for i := 0; i < 10; i++ { go func() { errCh <- ready.wait(context.Background()) }() } select { case <-time.After(1 * time.Second): case <-errCh: t.Errorf("ready should be blocking") } ready.set(true)
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Thu Mar 16 13:32:11 UTC 2023 - 4.6K bytes - Viewed (0) -
cmd/kube-scheduler/app/testing/testserver.go
logger := klog.FromContext(ctx) ctx, cancel := context.WithCancel(ctx) var errCh chan error tearDown := func() { cancel() // If the scheduler was started, let's wait for it to // shutdown clearly. if errCh != nil { err, ok := <-errCh if ok && err != nil { logger.Error(err, "Failed to shutdown test server clearly") } } if len(result.TmpDir) != 0 {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Thu Aug 24 10:35:59 UTC 2023 - 5.2K bytes - Viewed (0) -
cmd/kube-controller-manager/app/testing/testserver.go
logger := klog.FromContext(ctx) ctx, cancel := context.WithCancel(ctx) var errCh chan error tearDown := func() { cancel() // If the kube-controller-manager was started, let's wait for // it to shutdown cleanly. if errCh != nil { err, ok := <-errCh if ok && err != nil { logger.Error(err, "Failed to shutdown test server cleanly") } }
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Fri Oct 27 11:28:02 UTC 2023 - 5.4K bytes - Viewed (0) -
staging/src/k8s.io/apimachinery/pkg/util/httpstream/spdy/connection_test.go
serverDone <- struct{}{} } func TestConnectionCloseIsImmediateThroughAProxy(t *testing.T) { errCh := make(chan error) serverDone := make(chan struct{}, 1) backendUrlChan := make(chan string) go runServer(t, backendUrlChan, serverDone, errCh) var backendUrl string select { case err := <-errCh: t.Fatalf("server: error listening: %v", err) case backendUrl = <-backendUrlChan: }
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Mar 01 11:58:57 UTC 2023 - 7.9K bytes - Viewed (0) -
pkg/scheduler/framework/parallelize/error_channel.go
// are ignored, unless the existing error is received and the channel becomes empty // again. type ErrorChannel struct { errCh chan error } // SendError sends an error without blocking the sender. func (e *ErrorChannel) SendError(err error) { select { case e.errCh <- err: default: } } // SendErrorWithCancel sends an error without blocking the sender and calls // cancel function.
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Oct 20 17:39:23 UTC 2021 - 1.6K bytes - Viewed (0) -
staging/src/k8s.io/apiextensions-apiserver/pkg/cmd/server/testing/testserver.go
if err != nil { return result, fmt.Errorf("failed to create server: %v", err) } errCh = make(chan error) go func() { defer close(errCh) if err := server.GenericAPIServer.PrepareRun().RunWithContext(ctx); err != nil { errCh <- err } }() t.Logf("Waiting for /healthz to be ok...")
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Mon Apr 29 18:59:21 UTC 2024 - 9K bytes - Viewed (1) -
staging/src/k8s.io/apimachinery/pkg/util/httpstream/wsstream/stream_test.go
if err != nil { return data, err } return data, <-errCh } func expectWebSocketFrames(r *Reader, t *testing.T, fn func(*websocket.Conn), frames [][]byte, protocols ...string) error { errCh := make(chan error, 1) s, addr := newServer(http.HandlerFunc(func(w http.ResponseWriter, req *http.Request) { errCh <- r.Copy(w, req) })) defer s.Close()
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Thu Jun 29 15:48:39 UTC 2023 - 7.4K bytes - Viewed (0)