Benchmarking Code II

Benchmarking buffered writing and reading

In this lesson, we are going to test whether the size of the buffer plays a key role in the performance of write operations. This also gives us the opportunity to discuss table tests as well as the use of the testdata folder, which is reserved by Go for storing files that are going to be used during benchmarking—both table tests and the testdata folder can also be used in testing functions.

Get hands-on with 1200+ tech skills courses.