diff --git a/bin/templates/internal/server_grpc/server_grpc_test.go_ b/bin/templates/internal/server_grpc/server_grpc_test.go_ index 330ab06..82c4deb 100644 --- a/bin/templates/internal/server_grpc/server_grpc_test.go_ +++ b/bin/templates/internal/server_grpc/server_grpc_test.go_ @@ -164,14 +164,18 @@ func Test_server_LawsuitStatusType_FindByExtID(t *testing.T) { server1 := &ServerGRPC{} Otvet1, err := server1.LawsuitStatusType_Read(ctx, &Request) if err != nil { - t.Error("Test_server_LawsuitStatusType_FindByExtId() error: ", err) + t.Error("Test_server_LawsuitStatusType_FindByExtID() error: ", err) } // получим модель из строки JSON Model := lawsuit_status_types.LawsuitStatusType{} err = Model.GetModelFromJSON(Otvet1.ModelString) if err != nil { - t.Error("Test_server_LawsuitStatusType_FindByExtId() GetModelFromJSON() error: ", err) + t.Error("Test_server_LawsuitStatusType_FindByExtID() GetModelFromJSON() error: ", err) + } + + if Model.ExtID == 0 { + return } @@ -181,7 +185,7 @@ func Test_server_LawsuitStatusType_FindByExtID(t *testing.T) { RequestExtId.ConnectionId = Model.ConnectionID RequestExtId.VersionModel = lawsuit_status_types.LawsuitStatusType{}.GetStructVersion() - Otvet, err := server1.LawsuitStatusType_FindByExtId(ctx, &RequestExtId) + Otvet, err := server1.LawsuitStatusType_FindByExtID(ctx, &RequestExtId) if err != nil { t.Error("Test_server_LawsuitStatusType_FindByExtId() error: ", err) } diff --git a/bin/templates/pkg/network/grpc/grpc_client/grpc_client_test.go_ b/bin/templates/pkg/network/grpc/grpc_client/grpc_client_test.go_ index 9de1936..317fb71 100644 --- a/bin/templates/pkg/network/grpc/grpc_client/grpc_client_test.go_ +++ b/bin/templates/pkg/network/grpc/grpc_client/grpc_client_test.go_ @@ -165,6 +165,10 @@ func TestFindByExtID(t *testing.T) { t.Error("TestFind_ByExtID() error: ", err) } + if Otvet1.ExtID == 0 { + return + } + Otvet := lawsuit_status_types.LawsuitStatusType{} Otvet.ExtID = Otvet1.ExtID Otvet.ConnectionID = Otvet1.ConnectionID diff --git a/bin/templates/pkg/network/nrpc/nrpc_client/nrpc_client_test.go_ b/bin/templates/pkg/network/nrpc/nrpc_client/nrpc_client_test.go_ index bf0c758..b360493 100644 --- a/bin/templates/pkg/network/nrpc/nrpc_client/nrpc_client_test.go_ +++ b/bin/templates/pkg/network/nrpc/nrpc_client/nrpc_client_test.go_ @@ -165,6 +165,10 @@ func TestFindByExtID(t *testing.T) { t.Error("TestFind_ByExtID() error: ", err) } + if Otvet1.ExtID == 0 { + return + } + Otvet := lawsuit_status_types.LawsuitStatusType{} Otvet.ExtID = Otvet1.ExtID Otvet.ConnectionID = Otvet1.ConnectionID