From a2624c8c6d681216be86275c993c2717cd846bea Mon Sep 17 00:00:00 2001 From: Xiang Zhang Date: Thu, 19 Oct 2023 03:23:45 -0500 Subject: [PATCH] Update driver_test.go --- driver_test.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/driver_test.go b/driver_test.go index 500080dc2..21128397e 100644 --- a/driver_test.go +++ b/driver_test.go @@ -3369,10 +3369,8 @@ func TestConnectionAttributes(t *testing.T) { value1 := "value1" attr2 := "fo/o" value2 := "bo/o" - dsn += fmt.Sprintf( - "&connectionAttributes=%s:%s,%s:%s", - attr1, value1, url.QueryEscape(attr2), url.QueryEscape(value2), - ) + dsn += "&connectionAttributes=" + url.QueryEscape(fmt.Sprintf("%s:%s,%s:%s", attr1, value1, attr2, value2)) + var db *sql.DB if _, err := ParseDSN(dsn); err != errInvalidDSNUnsafeCollation {