From 2d32771a1b82400877d1aefe01c82705a3e10a7b Mon Sep 17 00:00:00 2001 From: Nate Kibler <nkibler@google.com> Date: Fri, 25 Sep 2015 11:56:05 -0700 Subject: [PATCH] Removed comment from code generation and updated tests --- src/compiler/objective_c_generator.cc | 1 - src/objective-c/tests/InteropTests.m | 12 ++++++------ 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/src/compiler/objective_c_generator.cc b/src/compiler/objective_c_generator.cc index 9eed78c961..ff092053ad 100644 --- a/src/compiler/objective_c_generator.cc +++ b/src/compiler/objective_c_generator.cc @@ -241,7 +241,6 @@ void PrintMethodImplementations(Printer *printer, printer.Print(" serviceName:(NSString *)serviceName {\n"); printer.Print(" return [self initWithHost:host];\n"); printer.Print("}\n\n"); - printer.Print("// Class factory method\n"); printer.Print("+ (instancetype)serviceWithHost:(NSString *)host {\n"); printer.Print(" return [[self alloc] initWithHost:host];\n"); printer.Print("}\n\n\n"); diff --git a/src/objective-c/tests/InteropTests.m b/src/objective-c/tests/InteropTests.m index 1b63fe2059..af58e2bd04 100644 --- a/src/objective-c/tests/InteropTests.m +++ b/src/objective-c/tests/InteropTests.m @@ -89,7 +89,7 @@ static NSString * const kRemoteSSLHost = @"grpc-test.sandbox.google.com"; } - (void)setUp { - _service = [[RMTTestService alloc] initWithHost:self.class.host]; + _service = [RMTTestService serviceWithHost:self.class.host]; } - (void)testEmptyUnaryRPC { @@ -274,17 +274,17 @@ static NSString * const kRemoteSSLHost = @"grpc-test.sandbox.google.com"; - (void)testCancelAfterFirstResponseRPC { __weak XCTestExpectation *expectation = [self expectationWithDescription:@"CancelAfterFirstResponse"]; - + // A buffered pipe to which we write a single value but never close GRXBufferedPipe *requestsBuffer = [[GRXBufferedPipe alloc] init]; - + __block BOOL receivedResponse = NO; - + id request = [RMTStreamingOutputCallRequest messageWithPayloadSize:@21782 requestedResponseSize:@31415]; - + [requestsBuffer writeValue:request]; - + __block ProtoRPC *call = [_service RPCToFullDuplexCallWithRequestsWriter:requestsBuffer eventHandler:^(BOOL done, -- GitLab