...

Source file src/github.com/aws/aws-sdk-go-v2/internal/awstesting/endless_reader.go

Documentation: github.com/aws/aws-sdk-go-v2/internal/awstesting

     1  package awstesting
     2  
     3  // EndlessReader is an io.Reader that will always return
     4  // that bytes have been read.
     5  type EndlessReader struct{}
     6  
     7  // Read will report that it has read len(p) bytes in p.
     8  // The content in the []byte will be unmodified.
     9  // This will never return an error.
    10  func (e EndlessReader) Read(p []byte) (int, error) {
    11  	return len(p), nil
    12  }
    13  

View as plain text