Browse Source

Fix no output when Client=False,TestClient=True (#1765)

Severn 1 year ago
parent
commit
3a78b54dc5
1 changed files with 3 additions and 1 deletions
  1. 3 1
      Sources/protoc-gen-grpc-swift/main.swift

+ 3 - 1
Sources/protoc-gen-grpc-swift/main.swift

@@ -156,7 +156,9 @@ func main(args: [String]) throws {
         binaryFile.content = serializedFileDescriptorProto
         response.file.append(binaryFile)
       }
-      if !fileDescriptor.services.isEmpty && (options.generateClient || options.generateServer) {
+      if !fileDescriptor.services.isEmpty
+        && (options.generateClient || options.generateServer || options.generateTestClient)
+      {
         var grpcFile = Google_Protobuf_Compiler_CodeGeneratorResponse.File()
         let grpcFileName = uniqueOutputFileName(
           component: "grpc",