aboutsummaryrefslogtreecommitdiffhomepage
path: root/java/core/src/test/java/com/google/protobuf/WireFormatTest.java
diff options
context:
space:
mode:
Diffstat (limited to 'java/core/src/test/java/com/google/protobuf/WireFormatTest.java')
-rw-r--r--java/core/src/test/java/com/google/protobuf/WireFormatTest.java70
1 files changed, 0 insertions, 70 deletions
diff --git a/java/core/src/test/java/com/google/protobuf/WireFormatTest.java b/java/core/src/test/java/com/google/protobuf/WireFormatTest.java
index 370860c2..625d4b42 100644
--- a/java/core/src/test/java/com/google/protobuf/WireFormatTest.java
+++ b/java/core/src/test/java/com/google/protobuf/WireFormatTest.java
@@ -30,8 +30,6 @@
package com.google.protobuf;
-import com.google.protobuf.UnittestLite.TestAllExtensionsLite;
-import com.google.protobuf.UnittestLite.TestPackedExtensionsLite;
import protobuf_unittest.UnittestMset.RawMessageSet;
import protobuf_unittest.UnittestMset.TestMessageSetExtension1;
import protobuf_unittest.UnittestMset.TestMessageSetExtension2;
@@ -125,32 +123,6 @@ public class WireFormatTest extends TestCase {
TestUtil.assertPackedFieldsSet(message2);
}
- public void testSerializeExtensionsLite() throws Exception {
- // TestAllTypes and TestAllExtensions should have compatible wire formats,
- // so if we serialize a TestAllExtensions then parse it as TestAllTypes
- // it should work.
-
- TestAllExtensionsLite message = TestUtilLite.getAllLiteExtensionsSet();
- ByteString rawBytes = message.toByteString();
- assertEquals(rawBytes.size(), message.getSerializedSize());
-
- TestAllTypes message2 = TestAllTypes.parseFrom(rawBytes);
-
- TestUtil.assertAllFieldsSet(message2);
- }
-
- public void testSerializePackedExtensionsLite() throws Exception {
- // TestPackedTypes and TestPackedExtensions should have compatible wire
- // formats; check that they serialize to the same string.
- TestPackedExtensionsLite message = TestUtilLite.getLitePackedExtensionsSet();
- ByteString rawBytes = message.toByteString();
-
- TestPackedTypes message2 = TestUtil.getPackedSet();
- ByteString rawBytes2 = message2.toByteString();
-
- assertEquals(rawBytes, rawBytes2);
- }
-
public void testParseExtensions() throws Exception {
// TestAllTypes and TestAllExtensions should have compatible wire formats,
// so if we serialize a TestAllTypes then parse it as TestAllExtensions
@@ -180,48 +152,6 @@ public class WireFormatTest extends TestCase {
TestUtil.assertPackedExtensionsSet(message2);
}
- public void testParseExtensionsLite() throws Exception {
- // TestAllTypes and TestAllExtensions should have compatible wire formats,
- // so if we serialize a TestAllTypes then parse it as TestAllExtensions
- // it should work.
-
- TestAllTypes message = TestUtil.getAllSet();
- ByteString rawBytes = message.toByteString();
-
- ExtensionRegistryLite registry_lite = TestUtilLite.getExtensionRegistryLite();
-
- TestAllExtensionsLite message2 =
- TestAllExtensionsLite.parseFrom(rawBytes, registry_lite);
-
- TestUtil.assertAllExtensionsSet(message2);
-
- // Try again using a full extension registry.
- ExtensionRegistry registry = TestUtil.getExtensionRegistry();
-
- TestAllExtensionsLite message3 =
- TestAllExtensionsLite.parseFrom(rawBytes, registry);
-
- TestUtil.assertAllExtensionsSet(message3);
- }
-
- public void testParsePackedExtensionsLite() throws Exception {
- // Ensure that packed extensions can be properly parsed.
- TestPackedExtensionsLite message = TestUtilLite.getLitePackedExtensionsSet();
- ByteString rawBytes = message.toByteString();
-
- ExtensionRegistryLite registry = TestUtilLite.getExtensionRegistryLite();
-
- TestPackedExtensionsLite message2 =
- TestPackedExtensionsLite.parseFrom(rawBytes, registry);
-
- TestUtil.assertPackedExtensionsSet(message2);
- }
-
- public void testExtensionsSerializedSize() throws Exception {
- assertNotSame(TestUtil.getAllSet().getSerializedSize(),
- TestUtil.getAllExtensionsSet().getSerializedSize());
- }
-
public void testSerializeDelimited() throws Exception {
ByteArrayOutputStream output = new ByteArrayOutputStream();
TestUtil.getAllSet().writeDelimitedTo(output);