Fix build break

This commit is contained in:
Pranav K 2018-04-02 10:29:46 -07:00
parent c7559e1ff4
commit fdc4df35ed
No known key found for this signature in database
GPG Key ID: 1963DA6D96C3057A
1 changed files with 4 additions and 1 deletions

View File

@ -6,6 +6,7 @@ using System.Linq;
using System.Reflection;
using Microsoft.AspNetCore.Mvc.ApplicationModels;
using Microsoft.AspNetCore.Mvc.Internal;
using Microsoft.AspNetCore.Mvc.ModelBinding;
using Microsoft.Extensions.Options;
using Xunit;
@ -67,7 +68,9 @@ namespace Microsoft.AspNetCore.Mvc.ViewFeatures.Internal
private static ApplicationModelProviderContext GetContext(Type type)
{
var defaultProvider = new DefaultApplicationModelProvider(Options.Create(new MvcOptions()));
var defaultProvider = new DefaultApplicationModelProvider(
Options.Create(new MvcOptions()),
new EmptyModelMetadataProvider());
var context = new ApplicationModelProviderContext(new[] { type.GetTypeInfo() });
defaultProvider.OnProvidersExecuting(context);