Commit cd11d541 authored by Sydney Acksman's avatar Sydney Acksman

Improve test to make sure the extensions are actually loaded for CustomOptions

parent 2b0b8385
......@@ -198,6 +198,10 @@ namespace Google.Protobuf.Test.Reflection
public void MultipleImportOfSameFileWithExtension()
{
var descriptor = ExtensionsCReflection.Descriptor;
var foo = Foo.Descriptor;
var bar = Bar.Descriptor;
AssertOption("bar", foo.CustomOptions.TryGetString, ExtensionsAExtensions.Opt, foo.GetOption);
AssertOption("foo", bar.CustomOptions.TryGetString, ExtensionsAExtensions.Opt, bar.GetOption);
}
private void AssertOption<T, D>(T expected, OptionFetcher<T> fetcher, Extension<D, T> extension, Func<Extension<D, T>, T> descriptorOptionFetcher) where D : IExtendableMessage<D>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment