Go’s interface provides a way to abstract away things like your database for
testing.

Read more at the source