Update supported go versions

Client: go

With the release of go 1.23, update supported go versions to 1.22+1.23
according to our go support policy.

Also update the code to use the new range loop feature introduced in go
1.22 when appropriate.

Also fix a bug in TSSLServerSocket.Addr that it does not return the
listener address.
diff --git a/lib/go/test/go.mod b/lib/go/test/go.mod
index 0c032b7..541bffc 100644
--- a/lib/go/test/go.mod
+++ b/lib/go/test/go.mod
@@ -1,6 +1,6 @@
 module github.com/apache/thrift/lib/go/test
 
-go 1.21
+go 1.22.0
 
 require (
 	github.com/apache/thrift v0.0.0-00010101000000-000000000000