aboutsummaryrefslogtreecommitdiffhomepage
path: root/objectivec/Tests/GPBCodedInputStreamTests.m
diff options
context:
space:
mode:
Diffstat (limited to 'objectivec/Tests/GPBCodedInputStreamTests.m')
-rw-r--r--objectivec/Tests/GPBCodedInputStreamTests.m4
1 files changed, 3 insertions, 1 deletions
diff --git a/objectivec/Tests/GPBCodedInputStreamTests.m b/objectivec/Tests/GPBCodedInputStreamTests.m
index 579fe65c..7c3c006b 100644
--- a/objectivec/Tests/GPBCodedInputStreamTests.m
+++ b/objectivec/Tests/GPBCodedInputStreamTests.m
@@ -225,8 +225,10 @@
// Serialize and parse it. Make sure to parse from an InputStream, not
// directly from a ByteString, so that CodedInputStream uses buffered
// reading.
+ NSData *messageData = message.data;
+ XCTAssertNotNil(messageData);
GPBCodedInputStream* stream =
- [GPBCodedInputStream streamWithData:message.data];
+ [GPBCodedInputStream streamWithData:messageData];
TestAllTypes* message2 = [TestAllTypes parseFromCodedInputStream:stream
extensionRegistry:nil
error:NULL];