In Go, you can use the standard fmt package to print debug output to the console.
fmt
While Go doesn’t include a built-in REPL, the community has created tools like gore to fill the gap.
gore
Go provides a built-in facility for debugging called delve.
delve
In Go, tests are typically written in the same package as the code they test.