Skip to content

Commit

Permalink
fix unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
FoghostCn committed Jan 16, 2024
1 parent 41bc0d5 commit da29d92
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions metadata/report/nacos/report_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ func Test_nacosMetadataReport_GetAppMetadata(t *testing.T) {

ctrl := gomock.NewController(t)
mnc := NewMockIConfigClient(ctrl)
mnc.EXPECT().GetConfig(gomock.Any()).Return(string(data), nil)
mnc.EXPECT().GetConfig(gomock.Any()).MaxTimes(2).Return(string(data), nil)
nc := &nacosClient.NacosConfigClient{}
nc.SetClient(mnc)

Expand Down Expand Up @@ -253,7 +253,7 @@ func Test_nacosMetadataReport_GetAppMetadata(t *testing.T) {
func Test_nacosMetadataReport_PublishAppMetadata(t *testing.T) {
ctrl := gomock.NewController(t)
mnc := NewMockIConfigClient(ctrl)
mnc.EXPECT().PublishConfig(gomock.Any()).Return(true, nil)
mnc.EXPECT().PublishConfig(gomock.Any()).Times(2).Return(true, nil)
nc := &nacosClient.NacosConfigClient{}
nc.SetClient(mnc)

Expand Down

0 comments on commit da29d92

Please sign in to comment.