# Test case that makes sure we print a nice error message
# instead of the generic "unknown godebug" error message
# for removed GODEBUGs.

! go list
stderr '^go.mod:3: removed GODEBUG "x509sha1" set to old value "1" \(https://go.dev/doc/godebug#go-124\)'

-- go.mod --
module example.com/bar

godebug x509sha1=1
