Some ideas:

- I assume the code isn't public? If it is, you might share it
- Are you running `go test -v` for verbose logging?
- Try fmt.Printf
- Try adding printing lines at points down the stack leading up to the 
point you think is failing, to make sure the code is actually running.
- Put a log line before each return in said function

On Thursday, November 16, 2017 at 10:54:53 PM UTC-8, Tom Denton wrote:
>
> Hello!
>
> I'm debugging a strange test failure, and with the magic of printf 
> debugging (t.Logf) have been adding bits to the test itself to get a sense 
> of what's wrong. The bad bahaviour is happening deep in library code, in a 
> function which returns nil for one of six reasons... I threw some 
> log.Fatalf() statements in that code in my citc to see what breaks, but 
> it's not showing up in the test logs at all.  Probably I'm making bad life 
> decisions; what, go community, am I supposed to be doing here?
>

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to