You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rocketmq.apache.org by aa...@apache.org on 2022/12/29 10:22:30 UTC

[rocketmq-clients] branch master updated: Typo fix (#330)

This is an automated email from the ASF dual-hosted git repository.

aaronai pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/rocketmq-clients.git


The following commit(s) were added to refs/heads/master by this push:
     new 577469b4 Typo fix (#330)
577469b4 is described below

commit 577469b4f56d2262904d51d3c2709257763efebf
Author: Lonre Wang <lo...@gmail.com>
AuthorDate: Thu Dec 29 18:22:24 2022 +0800

    Typo fix (#330)
---
 golang/client_manager_test.go | 10 +++++-----
 golang/client_test.go         |  2 +-
 golang/producer_test.go       |  2 +-
 3 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/golang/client_manager_test.go b/golang/client_manager_test.go
index ec8bf79d..ec20064e 100644
--- a/golang/client_manager_test.go
+++ b/golang/client_manager_test.go
@@ -108,9 +108,9 @@ func TestMain(m *testing.M) {
 	}, nil).AnyTimes()
 
 	MOCK_RPC_CLIENT.EXPECT().GracefulStop().Return(nil).AnyTimes()
-	MOCK_RPC_CLIENT.EXPECT().GetTarget().Return(fakeAddresss).AnyTimes()
+	MOCK_RPC_CLIENT.EXPECT().GetTarget().Return(fakeAddress).AnyTimes()
 	stubs := gostub.Stub(&NewRpcClient, func(target string, opts ...RpcClientOption) (RpcClient, error) {
-		if target == fakeAddresss {
+		if target == fakeAddress {
 			return MOCK_RPC_CLIENT, nil
 		}
 		return nil, fmt.Errorf("invalid target=%s", target)
@@ -146,9 +146,9 @@ func TestCMUnRegisterClient(t *testing.T) {
 }
 
 var (
-	fakeHost           = "127.0.0.1"
-	fakePort     int32 = 80
-	fakeAddresss       = fmt.Sprintf("%s:%d", fakeHost, fakePort)
+	fakeHost          = "127.0.0.1"
+	fakePort    int32 = 80
+	fakeAddress       = fmt.Sprintf("%s:%d", fakeHost, fakePort)
 )
 
 func fakeEndpoints() *v2.Endpoints {
diff --git a/golang/client_test.go b/golang/client_test.go
index 2d339990..5265a763 100644
--- a/golang/client_test.go
+++ b/golang/client_test.go
@@ -45,7 +45,7 @@ func TestCLINewClient(t *testing.T) {
 	})
 
 	stubs2 := gostub.Stub(&NewRpcClient, func(target string, opts ...RpcClientOption) (RpcClient, error) {
-		if target == fakeAddresss {
+		if target == fakeAddress {
 			return MOCK_RPC_CLIENT, nil
 		}
 		return nil, fmt.Errorf("invalid target=%s", target)
diff --git a/golang/producer_test.go b/golang/producer_test.go
index cc6679ea..2902eaa1 100644
--- a/golang/producer_test.go
+++ b/golang/producer_test.go
@@ -47,7 +47,7 @@ func TestProducer(t *testing.T) {
 	})
 
 	stubs2 := gostub.Stub(&NewRpcClient, func(target string, opts ...RpcClientOption) (RpcClient, error) {
-		if target == fakeAddresss {
+		if target == fakeAddress {
 			return MOCK_RPC_CLIENT, nil
 		}
 		return nil, fmt.Errorf("invalid target=%s", target)