(t *testing.T)
| 73 | } |
| 74 | |
| 75 | func TestPipeWriteBlock(t *testing.T) { |
| 76 | const atomicIOBytes = 2 |
| 77 | const capacity = MinimumPipeSize |
| 78 | |
| 79 | runTest(t, capacity, func(ctx context.Context, r *vfs.FileDescription, w *vfs.FileDescription) { |
| 80 | msg := make([]byte, capacity+1) |
| 81 | n, err := w.Write(ctx, usermem.BytesIOSequence(msg), vfs.WriteOptions{}) |
| 82 | if wantN, wantErr := int64(capacity), linuxerr.ErrWouldBlock; n != wantN || err != wantErr { |
| 83 | t.Fatalf("Writev: got (%d, %v), wanted (%d, %v)", n, err, wantN, wantErr) |
| 84 | } |
| 85 | }) |
| 86 | } |
| 87 | |
| 88 | func TestPipeWriteUntilEnd(t *testing.T) { |
| 89 | const atomicIOBytes = 2 |
nothing calls this directly
no test coverage detected
searching dependent graphs…