using System; | |
using NUnit.Framework; | |
namespace Google.ProtocolBuffers.CompatTests | |
{ | |
[TestFixture] | |
public class BinaryCompatibilityTests : CompatibilityTests | |
{ | |
protected override string TestName { get { return "binary"; } } | |
protected override object SerializeMessage<TMessage, TBuilder>(TMessage message) | |
{ | |
byte[] bresult = message.ToByteArray(); | |
return bresult; | |
} | |
protected override TBuilder DeerializeMessage<TMessage, TBuilder>(object message, TBuilder builder, ExtensionRegistry registry) | |
{ | |
return builder.MergeFrom((byte[])message, registry); | |
} | |
} | |
} |