Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for TestRingBufferCloseError (0.18 sec)

  1. internal/ringbuffer/ring_buffer_test.go

    	}
    	// check empty or full
    	if !rb.IsEmpty() {
    		t.Fatalf("expect IsEmpty is true but got false")
    	}
    	if rb.IsFull() {
    		t.Fatalf("expect IsFull is false but got true")
    	}
    }
    
    func TestRingBufferCloseError(t *testing.T) {
    	type testError1 struct{ error }
    	type testError2 struct{ error }
    
    	rb := New(100)
    	rb.CloseWithError(testError1{})
    	if _, err := rb.Write(nil); err != (testError1{}) {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Wed May 15 00:11:04 UTC 2024
    - 26.8K bytes
    - Viewed (0)
Back to top