diff --git a/test/go/src/bin/testclient/main.go b/test/go/src/bin/testclient/main.go
index b711958..95fcd47 100644
--- a/test/go/src/bin/testclient/main.go
+++ b/test/go/src/bin/testclient/main.go
@@ -140,6 +140,21 @@
 		}
 	}
 
+	uout := thrift.Tuuid{
+		0x00, 0x11, 0x22, 0x33,
+		0x44, 0x55,
+		0x66, 0x77,
+		0x88, 0x99,
+		0xaa, 0xbb, 0xcc, 0xdd, 0xee, 0xff,
+	}
+	u, err := client.TestUuid(defaultCtx, uout)
+	if err != nil {
+		t.Fatalf("TestUuid failed with %v", err)
+	}
+	if u != uout {
+		t.Fatalf("Unexpected TestUuid() result expected %v, got %v", uout, u)
+	}
+
 	xs := thrifttest.NewXtruct()
 	xs.StringThing = "thing"
 	xs.ByteThing = 42
diff --git a/test/go/src/common/clientserver_test.go b/test/go/src/common/clientserver_test.go
index 64b326a..a39519d 100644
--- a/test/go/src/common/clientserver_test.go
+++ b/test/go/src/common/clientserver_test.go
@@ -102,6 +102,13 @@
 var defaultCtx = context.Background()
 
 func callEverythingWithMock(t *testing.T, client *thrifttest.ThriftTestClient, handler *MockThriftTest) {
+	u := thrift.Tuuid{
+		0x00, 0x11, 0x22, 0x33,
+		0x44, 0x55,
+		0x66, 0x77,
+		0x88, 0x99,
+		0xaa, 0xbb, 0xcc, 0xdd, 0xee, 0xff,
+	}
 	gomock.InOrder(
 		handler.EXPECT().TestVoid(gomock.Any()),
 		handler.EXPECT().TestString(gomock.Any(), "thing").Return("thing", nil),
@@ -111,6 +118,7 @@
 		handler.EXPECT().TestI32(gomock.Any(), int32(4242)).Return(int32(4242), nil),
 		handler.EXPECT().TestI64(gomock.Any(), int64(424242)).Return(int64(424242), nil),
 		// TODO: add TestBinary()
+		handler.EXPECT().TestUuid(gomock.Any(), u).Return(u, nil),
 		handler.EXPECT().TestDouble(gomock.Any(), float64(42.42)).Return(float64(42.42), nil),
 		handler.EXPECT().TestStruct(gomock.Any(), &thrifttest.Xtruct{StringThing: "thing", ByteThing: 42, I32Thing: 4242, I64Thing: 424242}).Return(&thrifttest.Xtruct{StringThing: "thing", ByteThing: 42, I32Thing: 4242, I64Thing: 424242}, nil),
 		handler.EXPECT().TestNest(gomock.Any(), &thrifttest.Xtruct2{StructThing: &thrifttest.Xtruct{StringThing: "thing", ByteThing: 42, I32Thing: 4242, I64Thing: 424242}}).Return(&thrifttest.Xtruct2{StructThing: &thrifttest.Xtruct{StringThing: "thing", ByteThing: 42, I32Thing: 4242, I64Thing: 424242}}, nil),
@@ -182,6 +190,16 @@
 		t.Errorf("Unexpected TestI64() result expected 424242, got %d ", i64)
 	}
 
+	// TODO: add TestBinary() call
+
+	uret, err := client.TestUuid(defaultCtx, u)
+	if err != nil {
+		t.Errorf("Unexpected error in TestUuid() call: %s", err)
+	}
+	if uret != u {
+		t.Errorf("Unexpected TestUuid() result expected %v, got %v ", uret, u)
+	}
+
 	d, err := client.TestDouble(defaultCtx, 42.42)
 	if err != nil {
 		t.Errorf("Unexpected error in TestDouble() call: %s", err)
@@ -190,8 +208,6 @@
 		t.Errorf("Unexpected TestDouble() result expected 42.42, got %f ", d)
 	}
 
-	// TODO: add TestBinary() call
-
 	xs := thrifttest.NewXtruct()
 	xs.StringThing = "thing"
 	xs.ByteThing = 42
diff --git a/test/go/src/common/printing_handler.go b/test/go/src/common/printing_handler.go
index b726373..0939a01 100644
--- a/test/go/src/common/printing_handler.go
+++ b/test/go/src/common/printing_handler.go
@@ -26,6 +26,8 @@
 	"fmt"
 	"time"
 
+	"github.com/apache/thrift/lib/go/thrift"
+
 	//lint:ignore ST1001 allow dot import here
 	. "github.com/apache/thrift/test/go/src/gen/thrifttest"
 )
@@ -45,7 +47,7 @@
 // @return string - returns the string 'thing'
 //
 // Parameters:
-//  - Thing
+//   - Thing
 func (p *printingHandler) TestString(ctx context.Context, thing string) (r string, err error) {
 	fmt.Printf("testString(\"%s\")\n", thing)
 	return thing, nil
@@ -56,7 +58,7 @@
 // @return bool - returns the bool 'thing'
 //
 // Parameters:
-//  - Thing
+//   - Thing
 func (p *printingHandler) TestBool(ctx context.Context, thing bool) (r bool, err error) {
 	fmt.Printf("testBool(%t)\n", thing)
 	return thing, nil
@@ -67,7 +69,7 @@
 // @return byte - returns the byte 'thing'
 //
 // Parameters:
-//  - Thing
+//   - Thing
 func (p *printingHandler) TestByte(ctx context.Context, thing int8) (r int8, err error) {
 	fmt.Printf("testByte(%d)\n", thing)
 	return thing, nil
@@ -78,7 +80,7 @@
 // @return i32 - returns the i32 'thing'
 //
 // Parameters:
-//  - Thing
+//   - Thing
 func (p *printingHandler) TestI32(ctx context.Context, thing int32) (r int32, err error) {
 	fmt.Printf("testI32(%d)\n", thing)
 	return thing, nil
@@ -89,7 +91,7 @@
 // @return i64 - returns the i64 'thing'
 //
 // Parameters:
-//  - Thing
+//   - Thing
 func (p *printingHandler) TestI64(ctx context.Context, thing int64) (r int64, err error) {
 	fmt.Printf("testI64(%d)\n", thing)
 	return thing, nil
@@ -100,7 +102,7 @@
 // @return double - returns the double 'thing'
 //
 // Parameters:
-//  - Thing
+//   - Thing
 func (p *printingHandler) TestDouble(ctx context.Context, thing float64) (r float64, err error) {
 	fmt.Printf("testDouble(%f)\n", thing)
 	return thing, nil
@@ -111,18 +113,29 @@
 // @return []byte - returns the binary 'thing'
 //
 // Parameters:
-//  - Thing
+//   - Thing
 func (p *printingHandler) TestBinary(ctx context.Context, thing []byte) (r []byte, err error) {
 	fmt.Printf("testBinary(%s)\n", hex.EncodeToString(thing))
 	return thing, nil
 }
 
+// Prints 'testUuid("%s")' where '%s' is the uuid given. Note that the uuid byte order should be correct.
+// @param uuid  thing - the uuid to print
+// @return uuid  - returns the uuid 'thing'
+//
+// Parameters:
+//   - Thing
+func (p *printingHandler) TestUuid(ctx context.Context, thing thrift.Tuuid) (r thrift.Tuuid, err error) {
+	fmt.Printf("testUuid(%s)\n", thing.String())
+	return thing, nil
+}
+
 // Prints 'testStruct("{%s}")' where thing has been formatted into a string of comma separated values
 // @param Xtruct thing - the Xtruct to print
 // @return Xtruct - returns the Xtruct 'thing'
 //
 // Parameters:
-//  - Thing
+//   - Thing
 func (p *printingHandler) TestStruct(ctx context.Context, thing *Xtruct) (r *Xtruct, err error) {
 	fmt.Printf("testStruct({\"%s\", %d, %d, %d})\n", thing.StringThing, thing.ByteThing, thing.I32Thing, thing.I64Thing)
 	return thing, err
@@ -133,7 +146,7 @@
 // @return Xtruct2 - returns the Xtruct2 'thing'
 //
 // Parameters:
-//  - Thing
+//   - Thing
 func (p *printingHandler) TestNest(ctx context.Context, nest *Xtruct2) (r *Xtruct2, err error) {
 	thing := nest.StructThing
 	fmt.Printf("testNest({%d, {\"%s\", %d, %d, %d}, %d})\n", nest.ByteThing, thing.StringThing, thing.ByteThing, thing.I32Thing, thing.I64Thing, nest.I32Thing)
@@ -141,12 +154,14 @@
 }
 
 // Prints 'testMap("{%s")' where thing has been formatted into a string of  'key => value' pairs
-//  separated by commas and new lines
+//
+//	separated by commas and new lines
+//
 // @param map<i32,i32> thing - the map<i32,i32> to print
 // @return map<i32,i32> - returns the map<i32,i32> 'thing'
 //
 // Parameters:
-//  - Thing
+//   - Thing
 func (p *printingHandler) TestMap(ctx context.Context, thing map[int32]int32) (r map[int32]int32, err error) {
 	fmt.Printf("testMap({")
 	first := true
@@ -163,12 +178,14 @@
 }
 
 // Prints 'testStringMap("{%s}")' where thing has been formatted into a string of  'key => value' pairs
-//  separated by commas and new lines
+//
+//	separated by commas and new lines
+//
 // @param map<string,string> thing - the map<string,string> to print
 // @return map<string,string> - returns the map<string,string> 'thing'
 //
 // Parameters:
-//  - Thing
+//   - Thing
 func (p *printingHandler) TestStringMap(ctx context.Context, thing map[string]string) (r map[string]string, err error) {
 	fmt.Printf("testStringMap({")
 	first := true
@@ -185,12 +202,14 @@
 }
 
 // Prints 'testSet("{%s}")' where thing has been formatted into a string of  values
-//  separated by commas and new lines
+//
+//	separated by commas and new lines
+//
 // @param set<i32> thing - the set<i32> to print
 // @return set<i32> - returns the set<i32> 'thing'
 //
 // Parameters:
-//  - Thing
+//   - Thing
 func (p *printingHandler) TestSet(ctx context.Context, thing []int32) (r []int32, err error) {
 	fmt.Printf("testSet({")
 	first := true
@@ -207,12 +226,14 @@
 }
 
 // Prints 'testList("{%s}")' where thing has been formatted into a string of  values
-//  separated by commas and new lines
+//
+//	separated by commas and new lines
+//
 // @param list<i32> thing - the list<i32> to print
 // @return list<i32> - returns the list<i32> 'thing'
 //
 // Parameters:
-//  - Thing
+//   - Thing
 func (p *printingHandler) TestList(ctx context.Context, thing []int32) (r []int32, err error) {
 	fmt.Printf("testList({")
 	for i, v := range thing {
@@ -230,7 +251,7 @@
 // @return Numberz - returns the Numberz 'thing'
 //
 // Parameters:
-//  - Thing
+//   - Thing
 func (p *printingHandler) TestEnum(ctx context.Context, thing Numberz) (r Numberz, err error) {
 	fmt.Printf("testEnum(%d)\n", thing)
 	return thing, nil
@@ -241,7 +262,7 @@
 // @return UserId - returns the UserId 'thing'
 //
 // Parameters:
-//  - Thing
+//   - Thing
 func (p *printingHandler) TestTypedef(ctx context.Context, thing UserId) (r UserId, err error) {
 	fmt.Printf("testTypedef(%d)\n", thing)
 	return thing, nil
@@ -250,10 +271,11 @@
 // Prints 'testMapMap("%d")' with hello as '%d'
 // @param i32 hello - the i32 to print
 // @return map<i32,map<i32,i32>> - returns a dictionary with these values:
-//   {-4 => {-4 => -4, -3 => -3, -2 => -2, -1 => -1, }, 4 => {1 => 1, 2 => 2, 3 => 3, 4 => 4, }, }
+//
+//	{-4 => {-4 => -4, -3 => -3, -2 => -2, -1 => -1, }, 4 => {1 => 1, 2 => 2, 3 => 3, 4 => 4, }, }
 //
 // Parameters:
-//  - Hello
+//   - Hello
 func (p *printingHandler) TestMapMap(ctx context.Context, hello int32) (r map[int32]map[int32]int32, err error) {
 	fmt.Printf("testMapMap(%d)\n", hello)
 
@@ -267,15 +289,17 @@
 // So you think you've got this all worked, out eh?
 //
 // Creates a the returned map with these values and prints it out:
-//   { 1 => { 2 => argument,
-//            3 => argument,
-//          },
-//     2 => { 6 => <empty Insanity struct>, },
-//   }
+//
+//	{ 1 => { 2 => argument,
+//	         3 => argument,
+//	       },
+//	  2 => { 6 => <empty Insanity struct>, },
+//	}
+//
 // @return map<UserId, map<Numberz,Insanity>> - a map with the above values
 //
 // Parameters:
-//  - Argument
+//   - Argument
 func (p *printingHandler) TestInsanity(ctx context.Context, argument *Insanity) (r map[UserId]map[Numberz]*Insanity, err error) {
 	fmt.Printf("testInsanity()\n")
 	r = make(map[UserId]map[Numberz]*Insanity)
@@ -297,15 +321,16 @@
 // @param Numberz arg4 -
 // @param UserId arg5 -
 // @return Xtruct - returns an Xtruct with StringThing = "Hello2, ByteThing = arg0, I32Thing = arg1
-//    and I64Thing = arg2
+//
+//	and I64Thing = arg2
 //
 // Parameters:
-//  - Arg0
-//  - Arg1
-//  - Arg2
-//  - Arg3
-//  - Arg4
-//  - Arg5
+//   - Arg0
+//   - Arg1
+//   - Arg2
+//   - Arg3
+//   - Arg4
+//   - Arg5
 func (p *printingHandler) TestMulti(ctx context.Context, arg0 int8, arg1 int32, arg2 int64, arg3 map[int16]string, arg4 Numberz, arg5 UserId) (r *Xtruct, err error) {
 	fmt.Printf("testMulti()\n")
 	r = NewXtruct()
@@ -324,7 +349,7 @@
 // else do not throw anything
 //
 // Parameters:
-//  - Arg
+//   - Arg
 func (p *printingHandler) TestException(ctx context.Context, arg string) (err error) {
 	fmt.Printf("testException(%s)\n", arg)
 	switch arg {
@@ -348,8 +373,8 @@
 // @return Xtruct - an Xtruct with StringThing = arg1
 //
 // Parameters:
-//  - Arg0
-//  - Arg1
+//   - Arg0
+//   - Arg1
 func (p *printingHandler) TestMultiException(ctx context.Context, arg0 string, arg1 string) (r *Xtruct, err error) {
 	fmt.Printf("testMultiException(%s, %s)\n", arg0, arg1)
 	switch arg0 {
@@ -378,7 +403,7 @@
 // @param i32 secondsToSleep - the number of seconds to sleep
 //
 // Parameters:
-//  - SecondsToSleep
+//   - SecondsToSleep
 func (p *printingHandler) TestOneway(ctx context.Context, secondsToSleep int32) (err error) {
 	fmt.Printf("testOneway(%d): Sleeping...\n", secondsToSleep)
 	time.Sleep(time.Second * time.Duration(secondsToSleep))
diff --git a/test/go/src/common/simple_handler.go b/test/go/src/common/simple_handler.go
index fb95457..be5bc82 100644
--- a/test/go/src/common/simple_handler.go
+++ b/test/go/src/common/simple_handler.go
@@ -23,6 +23,8 @@
 	"errors"
 	"time"
 
+	"github.com/apache/thrift/lib/go/thrift"
+
 	//lint:ignore ST1001 allow dot import here
 	. "github.com/apache/thrift/test/go/src/gen/thrifttest"
 )
@@ -63,6 +65,10 @@
 	return thing, nil
 }
 
+func (p *simpleHandler) TestUuid(thing thrift.Tuuid) (r thrift.Tuuid, err error) {
+	return thing, nil
+}
+
 func (p *simpleHandler) TestStruct(thing *Xtruct) (r *Xtruct, err error) {
 	return r, err
 }
