Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for waitForWithContext (0.17 sec)

  1. staging/src/k8s.io/apimachinery/pkg/util/wait/wait_test.go

    // waitForWithContext cancels the context it supplies to the WaitWithContextFunc.
    func Test_waitForWithContextCancelsContext(t *testing.T) {
    	ctx, cancel := context.WithCancel(context.Background())
    	defer cancel()
    	waitFn := poller(time.Millisecond, ForeverTestTimeout)
    
    	var ctxPassedToWait context.Context
    	waitForWithContext(ctx, func(ctx context.Context) <-chan struct{} {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Mar 26 16:28:45 UTC 2024
    - 41.1K bytes
    - Viewed (0)
  2. staging/src/k8s.io/apimachinery/pkg/util/wait/poll.go

    		}
    	}
    
    	select {
    	case <-ctx.Done():
    		// returning ctx.Err() will break backward compatibility, use new PollUntilContext*
    		// methods instead
    		return ErrWaitTimeout
    	default:
    		return waitForWithContext(ctx, wait, condition)
    	}
    }
    
    // poller returns a WaitFunc that will send to the channel every interval until
    // timeout has elapsed and then closes the channel.
    //
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri May 26 06:13:35 UTC 2023
    - 14K bytes
    - Viewed (0)
Back to top