diff --git a/test/Microsoft.AspNet.Mvc.FunctionalTests/RazorInstrumentationTests.cs b/test/Microsoft.AspNet.Mvc.FunctionalTests/RazorInstrumentationTests.cs index c571c97a35..9b5d8e6273 100644 --- a/test/Microsoft.AspNet.Mvc.FunctionalTests/RazorInstrumentationTests.cs +++ b/test/Microsoft.AspNet.Mvc.FunctionalTests/RazorInstrumentationTests.cs @@ -14,7 +14,7 @@ namespace Microsoft.AspNet.Mvc.FunctionalTests { public class RazorInstrumentationTests { - private readonly IServiceProvider _services = TestHelper.CreateServices("RazorInstrumentationWebSite"); + private readonly IServiceProvider _services = TestHelper.CreateServices("RazorInstrumentationWebsite"); private readonly Action _app = new Startup().Configure; public static IEnumerable InstrumentationData diff --git a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Metadata/DataAnnotationsMetadataDetailsProviderTest.cs b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Metadata/DataAnnotationsMetadataDetailsProviderTest.cs index d26820caf5..8d567a3f13 100644 --- a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Metadata/DataAnnotationsMetadataDetailsProviderTest.cs +++ b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Metadata/DataAnnotationsMetadataDetailsProviderTest.cs @@ -156,7 +156,7 @@ namespace Microsoft.AspNet.Mvc.ModelBinding.Metadata var display = new DisplayAttribute() { Name = "DisplayAttribute_Name", - ResourceType = typeof(Test.Resources), + ResourceType = typeof(Test.TestResources), }; var attributes = new Attribute[] { display }; @@ -180,7 +180,7 @@ namespace Microsoft.AspNet.Mvc.ModelBinding.Metadata var display = new DisplayAttribute() { Description = "DisplayAttribute_Description", - ResourceType = typeof(Test.Resources), + ResourceType = typeof(Test.TestResources), }; var attributes = new Attribute[] { display }; diff --git a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ModelBindingContextTest.cs b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ModelBindingContextTest.cs index f4e913d2a3..88e27740ec 100644 --- a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ModelBindingContextTest.cs +++ b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ModelBindingContextTest.cs @@ -1,7 +1,6 @@ // Copyright (c) Microsoft Open Technologies, Inc. All rights reserved. // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. - namespace Microsoft.AspNet.Mvc.ModelBinding.Test { //public class ModelBindingContextTest diff --git a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Properties/Resources.Designer.cs b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Properties/Resources.Designer.cs index 97e895f9f0..35e49f5cc1 100644 --- a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Properties/Resources.Designer.cs +++ b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Properties/Resources.Designer.cs @@ -26,38 +26,6 @@ namespace Microsoft.AspNet.Mvc.ModelBinding.Test return string.Format(CultureInfo.CurrentCulture, GetString("CompareAttributeTestResource"), p0, p1); } - /// - /// description from resources - /// - internal static string DisplayAttribute_Description - { - get { return GetString("DisplayAttribute_Description"); } - } - - /// - /// description from resources - /// - internal static string FormatDisplayAttribute_Description() - { - return GetString("DisplayAttribute_Description"); - } - - /// - /// name from resources - /// - internal static string DisplayAttribute_Name - { - get { return GetString("DisplayAttribute_Name"); } - } - - /// - /// name from resources - /// - internal static string FormatDisplayAttribute_Name() - { - return GetString("DisplayAttribute_Name"); - } - private static string GetString(string name, params string[] formatterNames) { var value = _resourceManager.GetString(name); diff --git a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/TestResources.cs b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/TestResources.cs new file mode 100644 index 0000000000..0868418b9a --- /dev/null +++ b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/TestResources.cs @@ -0,0 +1,14 @@ +// Copyright (c) Microsoft Open Technologies, Inc. All rights reserved. +// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. + +namespace Microsoft.AspNet.Mvc.ModelBinding.Test +{ + // This class is a 'fake' resources for testing DisplayAttribute. We can't use actual resources + // because our generator makes it an internal class, which doesn't work with DisplayAttribute. + public static class TestResources + { + public static string DisplayAttribute_Description { get; } = "description from resources"; + + public static string DisplayAttribute_Name { get; } = "name from resources"; + } +} \ No newline at end of file