aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authorGravatar Jorge Canizales <jcanizales@google.com>2016-04-30 10:32:49 -0700
committerGravatar Jorge Canizales <jcanizales@google.com>2016-04-30 10:32:49 -0700
commit47b80bc558b8a0e79db2501a4b98c4e3790b0511 (patch)
treea48e9d67b3116238f3ed78e1b447de4591867b3a /src
parent514699c63b5470d90395b4511982d3dc3700cad3 (diff)
Test that GRPCCall transitions states properly
Diffstat (limited to 'src')
-rw-r--r--src/objective-c/tests/InteropTests.m6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/objective-c/tests/InteropTests.m b/src/objective-c/tests/InteropTests.m
index 26877b1ae8..4f096b9efa 100644
--- a/src/objective-c/tests/InteropTests.m
+++ b/src/objective-c/tests/InteropTests.m
@@ -272,8 +272,14 @@
XCTAssertEqual(error.code, GRPC_STATUS_CANCELLED);
[expectation fulfill];
}];
+ XCTAssertEqual(call.state, GRXWriterStateNotStarted);
+
[call start];
+ XCTAssertEqual(call.state, GRXWriterStateStarted);
+
[call cancel];
+ XCTAssertEqual(call.state, GRXWriterStateFinished);
+
[self waitForExpectationsWithTimeout:1 handler:nil];
}