From 315908af5fa9e08dfc703b5070b39925d48360eb Mon Sep 17 00:00:00 2001 From: Doug Bunting Date: Thu, 20 Nov 2014 21:15:46 -0800 Subject: [PATCH] Apply VS' FormatDocument and RemoveAndSort to all *.cs files - #EngineeringDay - VS does not yet format auto-properties nicely; reverted what it did Also revert changes under - test/Microsoft.AspNet.Mvc.Razor.Host.Test/TestFiles --- samples/MvcSample.Web/Components/TagCloud.cs | 4 +- .../ProductsAdminController.cs | 4 +- .../ApiExplorerSamples/ProductsController.cs | 3 +- .../Filters/AgeEnhancerFilterAttribute.cs | 2 +- .../MvcSample.Web/Filters/BlockAnonymous.cs | 2 +- .../Filters/ErrorMessagesAttribute.cs | 1 - .../Filters/FakeUserAttribute.cs | 4 +- .../Filters/PassThroughAttribute.cs | 6 +- .../MvcSample.Web/Filters/UserNameService.cs | 2 - samples/MvcSample.Web/LinkController.cs | 1 - .../Models/ApiExplorerSamples/Product.cs | 4 +- .../ProductOrderConfirmation.cs | 4 +- .../Monitoring/MonitoringModule.cs | 2 +- samples/MvcSample.Web/Services/TestService.cs | 22 ++-- .../CopyOnWriteDictionary.cs | 1 - .../ActionContext.cs | 1 - src/Microsoft.AspNet.Mvc.Core/ActionResult.cs | 1 - .../ActionResults/ContentResult.cs | 1 - .../ActionResults/FileContentResult.cs | 1 - .../ActionResults/NoContentResult.cs | 2 + .../ActionResults/ObjectResult.cs | 3 - .../ActionResults/RedirectToActionResult.cs | 1 - .../ActionResults/RedirectToRouteResult.cs | 1 - .../AmbiguousActionException.cs | 10 +- .../AntiForgery/AntiForgery.cs | 3 +- .../AntiForgery/AntiForgeryToken.cs | 1 - .../AntiForgery/AntiForgeryTokenStore.cs | 1 - .../AntiForgery/AntiForgeryWorker.cs | 10 +- .../AntiForgery/BinaryBlob.cs | 2 - .../AntiForgery/IClaimUidExtractor.cs | 1 - .../AntiForgery/ITokenGenerator.cs | 1 - .../AntiForgery/ITokenValidator.cs | 1 - .../ApplicationModels/IActionModelBuilder.cs | 1 - src/Microsoft.AspNet.Mvc.Core/Controller.cs | 2 +- .../ControllerActionDescriptorProvider.cs | 3 +- .../ControllerActionInvoker.cs | 7 +- .../ControllerActionInvokerProvider.cs | 1 - .../ControllerDescriptor.cs | 1 - src/Microsoft.AspNet.Mvc.Core/DefaultOrder.cs | 10 +- .../DefaultApiDescriptionProvider.cs | 2 +- .../FilterActionInvoker.cs | 1 - .../Filters/AuthorizationContext.cs | 1 - .../Filters/AuthorizationFilterAttribute.cs | 4 +- .../Filters/AuthorizeAttribute.cs | 8 +- .../Filters/DefaultGlobalFilterProvider.cs | 1 - .../Filters/ExceptionFilterAttribute.cs | 4 +- .../Filters/IAsyncAuthorizationFilter.cs | 1 - .../Filters/IAsyncExceptionFilter.cs | 1 - .../Filters/IAuthorizationFilter.cs | 2 - .../Filters/IExceptionFilter.cs | 2 - .../DefaultInputFormattersProvider.cs | 1 - .../Formatters/DelegatingStream.cs | 2 + .../Formatters/FormattingUtilities.cs | 2 + .../HttpNoContentOutputFormatter.cs | 2 +- .../Formatters/IInputFormatter.cs | 3 - .../Formatters/IInputFormatterSelector.cs | 5 - .../Formatters/IInputFormattersProvider.cs | 1 - .../Formatters/IOutputFormatter.cs | 5 - .../Formatters/InputFormatterContext.cs | 3 - .../Formatters/TextPlainFormatter.cs | 5 - .../HttpDeleteAttribute.cs | 1 - .../HttpGetAttribute.cs | 1 - .../HttpPatchAttribute.cs | 1 - .../HttpPostAttribute.cs | 1 - .../HttpPutAttribute.cs | 1 - .../Internal/MvcServicesHelper.cs | 1 - .../InputFormatterDescriptor.cs | 1 - .../InputFormatterDescriptorExtensions.cs | 1 - .../IActionBindingContextProvider.cs | 1 - .../ParameterBinding/ModelBindingHelper.cs | 1 - .../Rendering/Html/DefaultHtmlGenerator.cs | 106 +++++++++--------- .../Rendering/Html/TagBuilder.cs | 16 +-- .../Rendering/MvcOptions.cs | 1 - .../RequireHttpsAttribute.cs | 1 - .../Routing/ActionSelectorDecisionTree.cs | 2 + .../Routing/AttributeRoute.cs | 2 +- .../Routing/AttributeRouteMatchingEntry.cs | 1 - src/Microsoft.AspNet.Mvc.Core/UrlHelper.cs | 1 - .../ViewComponents/JsonViewComponentResult.cs | 6 +- .../ViewComponents/ViewComponentContext.cs | 1 - .../ViewComponentInvokerProviderContext.cs | 1 - .../ViewComponents/ViewViewComponentResult.cs | 1 - .../MediaTypeWithQualityHeaderValue.cs | 16 +-- .../StringWithQualityHeaderValue.cs | 2 +- .../Binders/CompositeModelBinder.cs | 2 - .../Binders/ICompositeModelBinder.cs | 1 - .../Metadata/AssociatedMetadataProvider.cs | 2 +- .../ClientModelValidationContext.cs | 1 - .../ModelClientValidationRegexRule.cs | 1 - .../FormValueProviderFactory.cs | 1 - .../MetadataAwareValueProvider.cs | 1 - .../Directives/InjectChunkMerger.cs | 1 - .../GeneratedTagHelperAttributeContext.cs | 5 +- .../InjectChunkVisitor.cs | 1 - .../Compilation/CompilationFailedException.cs | 1 - .../Compilation/CompilerCacheEntry.cs | 2 +- .../RazorViewEngine.cs | 1 - .../InputTagHelper.cs | 52 ++++----- .../TextAreaTagHelper.cs | 2 +- .../ActionResults/InvalidModelStateResult.cs | 2 +- .../ActionResults/ResponseMessageResult.cs | 1 - .../ApiController.cs | 1 - .../HttpResponseMessageOutputFormatter.cs | 2 +- .../HttpRequestMessageExtensions.cs | 5 +- .../HttpRequestMessageModelBinder.cs | 4 +- .../IHttpRequestMessageFeature.cs | 2 +- .../HttpResponseException.cs | 2 +- .../OverloadActionConstraint.cs | 2 +- src/Microsoft.AspNet.Mvc/MvcOptionsSetup.cs | 1 - .../ActionResults/FileContentResultTest.cs | 1 - .../ActionResults/FilePathResultTest.cs | 4 +- .../HttpStatusCodeResultTests.cs | 4 +- .../ActionResults/ObjectResultTests.cs | 10 +- .../ActionResults/RedirectResultTest.cs | 1 - .../RedirectToActionResultTest.cs | 1 - .../AntiForgeryTokenSerializerTest.cs | 3 - .../AntiXsrf/TokenProviderTests.cs | 11 +- .../ValidateAntiForgeryTokenAttributeTest.cs | 4 +- .../AttributeRouteModelTests.cs | 2 +- .../BodyModelBinderTests.cs | 1 - ...ControllerActionDescriptorProviderTests.cs | 2 +- .../ControllerActionInvokerTest.cs | 1 - .../ControllerTests.cs | 6 +- .../DefaultActionSelectorTests.cs | 2 +- .../DefaultInputFormatterSelectorTests.cs | 2 - .../Filters/AuthorizeAttributeTestsBase.cs | 2 +- .../Filters/DefaultFilterProviderTest.cs | 3 +- .../Formatters/DelegatingStreamTests.cs | 2 - .../Formatters/JsonInputFormatterTest.cs | 2 +- .../Formatters/JsonOutputFormatterTests.cs | 3 - .../Formatters/NoContentFormatterTests.cs | 4 - .../Formatters/OutputFormatterTests.cs | 1 - .../Formatters/TextPlainFormatterTests.cs | 3 - .../InputObjectBindingTests.cs | 1 - .../DecisionTree/DecisionTreeBuilderTest.cs | 2 +- .../JsonResultTest.cs | 2 +- .../KnownRouteValueConstraintTests.cs | 4 +- .../Logging/TestLogger.cs | 6 +- .../MediaTypeWithQualityHeaderValueTests.cs | 5 - .../MockMvcOptionsAccessor.cs | 6 +- .../MvcRouteHandlerTests.cs | 1 - .../InputFormatterDescriptorExtensionTest.cs | 1 - .../InputFormatterDescriptorTest.cs | 1 - .../OutputFormatterDescriptorTest.cs | 3 +- .../ExpressionMetadataProviderTest.cs | 2 +- .../Rendering/HtmlHelperCheckboxTest.cs | 2 +- .../HtmlHelperLabelExtensionsTest.cs | 1 - .../Rendering/HtmlHelperTest.cs | 1 - .../HtmlHelperValueExtensionsTest.cs | 4 +- .../ViewEngine/CompositeViewEngineTest.cs | 1 - .../RequireHttpsAttributeTests.cs | 3 +- .../Routing/AttributeRoutePrecedenceTests.cs | 1 - .../Routing/AttributeRouteTests.cs | 4 +- .../Routing/AttributeRoutingTest.cs | 4 +- .../TestController.cs | 16 +-- .../TypeHelperTest.cs | 2 +- .../UrlHelperTest.cs | 2 +- .../ApiExplorerTest.cs | 2 +- .../ApplicationModelTest.cs | 2 +- .../ConnegTests.cs | 1 - .../FlushPointTest.cs | 1 - .../NullLoggerFactory.cs | 4 +- .../TestAssemblyProvider.cs | 6 +- .../VersioningTests.cs | 3 +- .../WebApiCompatShimActionResultTest.cs | 6 - .../WebApiCompatShimBasicTest.cs | 6 +- .../WebApiCompatShimParameterBindingTest.cs | 2 - .../XmlOutputFormatterTests.cs | 1 - .../Binders/CollectionModelBinderTest.cs | 2 + .../Binders/ComplexModelDtoResultTest.cs | 2 +- .../AssociatedMetadataProviderTest.cs | 2 + .../ModelBindingContextTest.cs | 6 - .../DataAnnotationsModelValidatorTest.cs | 2 +- .../DictionaryBasedValueProviderTests.cs | 2 +- .../QueryStringValueProviderFactoryTest.cs | 4 +- ...dableStringCollectionValueProviderTests.cs | 1 - .../Directives/SetBaseTypeChunkMergerTest.cs | 2 +- ...TagHelperAttributeValueCodeRendererTest.cs | 5 +- .../DefaultViewLocationCacheTest.cs | 2 +- .../RazorPageCreateTagHelperTest.cs | 1 - .../RazorTextWriterTest.cs | 6 +- .../OptionTagHelperTest.cs | 2 +- .../TagHelperOutputExtensionsTest.cs | 1 - .../MvcOptionSetupTest.cs | 1 - .../InvalidModelStateResultTest.cs | 2 +- .../DefaultContentNegotiatorTest.cs | 2 +- .../HttpErrorTest.cs | 2 +- .../HttpResponseExceptionTest.cs | 8 +- .../OverloadActionConstraintTest.cs | 1 - .../TestUtils/MediaTypeAssert.cs | 1 - .../Components/ValueComponent.cs | 2 +- .../Controllers/AccountController.cs | 1 - .../ApiExplorerHttpMethodController.cs | 1 - ...piExplorerResponseContentTypeController.cs | 1 - ...seContentTypeOverrideOnActionController.cs | 1 - ...rResponseTypeOverrideOnActionController.cs | 1 - ...orerResponseTypeWithAttributeController.cs | 2 +- ...rResponseTypeWithoutAttributeController.cs | 2 +- test/WebSites/AutofacWebSite/Startup.cs | 5 +- .../Controllers/HomeController.cs | 1 - .../Controllers/MonitorController.cs | 2 +- test/WebSites/BasicWebSite/Models/Person.cs | 4 +- test/WebSites/BasicWebSite/Startup.cs | 1 - .../FallbackOnTypeBasedMatchController.cs | 7 -- ...oNotTreatNullValueAsNoContentController.cs | 1 - .../Controllers/NormalController.cs | 2 - .../ProducesContentBaseController.cs | 2 +- .../WebSites/ConnegWebSite/CustomFormatter.cs | 2 - test/WebSites/ConnegWebSite/Models/User.cs | 1 - .../ConnegWebSite/PlainTextFormatter.cs | 2 - .../FilesWebSite/SendFileMiddleware.cs | 2 +- .../Filters/AddHeaderAttribute.cs | 1 - .../Filters/AuthorizeUserAttribute.cs | 2 +- .../Filters/GlobalActionFilter.cs | 2 +- .../Filters/HandleExceptionActionFilter.cs | 1 - .../Controllers/InputFormatterController.cs | 13 +-- .../Controllers/JsonFormatterController.cs | 3 +- .../Controllers/ValidationController.cs | 2 +- .../FormatterWebSite/Models/Developer.cs | 1 - .../DefaultCommandLineArgumentBuilder.cs | 1 - .../ModelBindingWebSite/Model/Employee.cs | 1 - .../Model/EmployeeWithBinderMetadata.cs | 1 - .../ModelBindingWebSite/Model/ExternalType.cs | 1 - .../ModelBindingWebSite/Model/Person.cs | 2 +- test/WebSites/ModelBindingWebSite/Startup.cs | 2 +- .../WebSites/PrecompilationWebSite/Startup.cs | 1 - .../HomeController.cs | 1 - .../Controllers/DirectivesController.cs | 1 - .../PartialViewEngineController.cs | 2 +- .../Controllers/TemplateExpander.cs | 1 - test/WebSites/RazorWebSite/Models/Address.cs | 2 +- test/WebSites/RazorWebSite/MyBasePage.cs | 1 - .../Controllers/BanksController.cs | 8 +- .../Controllers/DuplicateController.cs | 1 - .../Controllers/EmployeeController.cs | 3 +- .../Controllers/MapsController.cs | 5 +- .../Controllers/StoreController.cs | 4 +- .../Controllers/TeamController.cs | 3 +- .../RoutingWebSite/HttpMergeAttribute.cs | 1 - .../TagHelpers/ATagHelper.cs | 1 - .../TagHelpers/PrettyTagHelper.cs | 1 - .../TagCloudViewComponentTagHelper.cs | 1 - test/WebSites/UrlHelperWebSite/AppOptions.cs | 4 +- .../Controllers/SimplePocoController.cs | 3 +- .../UrlHelperWebSite/CustomUrlHelper.cs | 1 - test/WebSites/UrlHelperWebSite/Startup.cs | 4 +- .../Controllers/VouchersController.cs | 1 - .../VersionRangeValidator.cs | 1 - .../VersioningWebSite/VersionRoute.cs | 2 +- .../ActionResults/ActionResultController.cs | 11 +- .../EnumParameterOverloadsController.cs | 1 - .../Legacy/ParameterAttributeController.cs | 1 - .../HttpResponseExceptionController.cs | 1 - .../WebApiCompatShimWebSite/Models/User.cs | 1 - .../Models/UserAddress.cs | 1 - .../WebApiCompatShimWebSite/Startup.cs | 1 - 256 files changed, 305 insertions(+), 529 deletions(-) diff --git a/samples/MvcSample.Web/Components/TagCloud.cs b/samples/MvcSample.Web/Components/TagCloud.cs index 5d9803addc..bec7b7d91d 100644 --- a/samples/MvcSample.Web/Components/TagCloud.cs +++ b/samples/MvcSample.Web/Components/TagCloud.cs @@ -5,7 +5,7 @@ using Microsoft.AspNet.Mvc; namespace MvcSample.Web.Components { - [ViewComponent(Name="Tags")] + [ViewComponent(Name = "Tags")] public class TagCloud : ViewComponent { private readonly string[] Tags = @@ -13,7 +13,7 @@ namespace MvcSample.Web.Components "Ut enim ad minim veniam quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat Duis aute irure " + "dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur Excepteur sint occaecat cupidatat" + "non proident, sunt in culpa qui officia deserunt mollit anim id est laborum") - .Split(new char[] {' '}, StringSplitOptions.RemoveEmptyEntries) + .Split(new char[] { ' ' }, StringSplitOptions.RemoveEmptyEntries) .OrderBy(s => Guid.NewGuid().ToString()) .ToArray(); diff --git a/samples/MvcSample.Web/Controllers/ApiExplorerSamples/ProductsAdminController.cs b/samples/MvcSample.Web/Controllers/ApiExplorerSamples/ProductsAdminController.cs index 5db309cc24..b46222345c 100644 --- a/samples/MvcSample.Web/Controllers/ApiExplorerSamples/ProductsAdminController.cs +++ b/samples/MvcSample.Web/Controllers/ApiExplorerSamples/ProductsAdminController.cs @@ -1,6 +1,6 @@ -using Microsoft.AspNet.Mvc; -using System; +using System; using System.Collections.Generic; +using Microsoft.AspNet.Mvc; namespace MvcSample.Web.ApiExplorerSamples { diff --git a/samples/MvcSample.Web/Controllers/ApiExplorerSamples/ProductsController.cs b/samples/MvcSample.Web/Controllers/ApiExplorerSamples/ProductsController.cs index 538791b98d..2da3800c6e 100644 --- a/samples/MvcSample.Web/Controllers/ApiExplorerSamples/ProductsController.cs +++ b/samples/MvcSample.Web/Controllers/ApiExplorerSamples/ProductsController.cs @@ -1,6 +1,5 @@ -using System; +using System.Collections.Generic; using Microsoft.AspNet.Mvc; -using System.Collections.Generic; namespace MvcSample.Web.ApiExplorerSamples { diff --git a/samples/MvcSample.Web/Filters/AgeEnhancerFilterAttribute.cs b/samples/MvcSample.Web/Filters/AgeEnhancerFilterAttribute.cs index aaceb495ba..b3f4ca7afd 100644 --- a/samples/MvcSample.Web/Filters/AgeEnhancerFilterAttribute.cs +++ b/samples/MvcSample.Web/Filters/AgeEnhancerFilterAttribute.cs @@ -20,7 +20,7 @@ namespace MvcSample.Web.Filters { if (age is int) { - var intAge = (int) age; + var intAge = (int)age; if (intAge < 21) { diff --git a/samples/MvcSample.Web/Filters/BlockAnonymous.cs b/samples/MvcSample.Web/Filters/BlockAnonymous.cs index 495ddab1b5..2d67958fde 100644 --- a/samples/MvcSample.Web/Filters/BlockAnonymous.cs +++ b/samples/MvcSample.Web/Filters/BlockAnonymous.cs @@ -14,7 +14,7 @@ namespace MvcSample.Web.Filters user.Identity == null || !user.Identity.IsAuthenticated; - if(userIsAnonymous) + if (userIsAnonymous) { base.Fail(context); } diff --git a/samples/MvcSample.Web/Filters/ErrorMessagesAttribute.cs b/samples/MvcSample.Web/Filters/ErrorMessagesAttribute.cs index 7afd313fc2..13865e020e 100644 --- a/samples/MvcSample.Web/Filters/ErrorMessagesAttribute.cs +++ b/samples/MvcSample.Web/Filters/ErrorMessagesAttribute.cs @@ -1,5 +1,4 @@ using Microsoft.AspNet.Mvc; -using Microsoft.AspNet.Mvc.Filters; namespace MvcSample.Web { diff --git a/samples/MvcSample.Web/Filters/FakeUserAttribute.cs b/samples/MvcSample.Web/Filters/FakeUserAttribute.cs index c8a6f869c4..a65f86171e 100644 --- a/samples/MvcSample.Web/Filters/FakeUserAttribute.cs +++ b/samples/MvcSample.Web/Filters/FakeUserAttribute.cs @@ -1,7 +1,5 @@ -using System; -using System.Threading.Tasks; -using Microsoft.AspNet.Mvc; using System.Security.Claims; +using Microsoft.AspNet.Mvc; namespace MvcSample.Web { diff --git a/samples/MvcSample.Web/Filters/PassThroughAttribute.cs b/samples/MvcSample.Web/Filters/PassThroughAttribute.cs index 4268880f17..16fafd02bf 100644 --- a/samples/MvcSample.Web/Filters/PassThroughAttribute.cs +++ b/samples/MvcSample.Web/Filters/PassThroughAttribute.cs @@ -1,16 +1,14 @@ -using System; using System.Threading.Tasks; using Microsoft.AspNet.Mvc; -using Microsoft.AspNet.Mvc.Filters; namespace MvcSample.Web { public class PassThroughAttribute : AuthorizationFilterAttribute { - #pragma warning disable 1998 +#pragma warning disable 1998 public override async Task OnAuthorizationAsync(AuthorizationContext context) { } - #pragma warning restore 1998 +#pragma warning restore 1998 } } diff --git a/samples/MvcSample.Web/Filters/UserNameService.cs b/samples/MvcSample.Web/Filters/UserNameService.cs index 0af9c5a44f..5fd5ef8853 100644 --- a/samples/MvcSample.Web/Filters/UserNameService.cs +++ b/samples/MvcSample.Web/Filters/UserNameService.cs @@ -1,5 +1,3 @@ -using Microsoft.AspNet.Mvc; - namespace MvcSample.Web.Filters { public class UserNameService diff --git a/samples/MvcSample.Web/LinkController.cs b/samples/MvcSample.Web/LinkController.cs index a8ed612017..59631ace0e 100644 --- a/samples/MvcSample.Web/LinkController.cs +++ b/samples/MvcSample.Web/LinkController.cs @@ -1,5 +1,4 @@ using Microsoft.AspNet.Mvc; -using Microsoft.AspNet.Mvc.Rendering; namespace MvcSample.Web { diff --git a/samples/MvcSample.Web/Models/ApiExplorerSamples/Product.cs b/samples/MvcSample.Web/Models/ApiExplorerSamples/Product.cs index c05cce51d6..275fb5da49 100644 --- a/samples/MvcSample.Web/Models/ApiExplorerSamples/Product.cs +++ b/samples/MvcSample.Web/Models/ApiExplorerSamples/Product.cs @@ -1,6 +1,4 @@ -using System; - -namespace MvcSample.Web.ApiExplorerSamples +namespace MvcSample.Web.ApiExplorerSamples { public class Product { diff --git a/samples/MvcSample.Web/Models/ApiExplorerSamples/ProductOrderConfirmation.cs b/samples/MvcSample.Web/Models/ApiExplorerSamples/ProductOrderConfirmation.cs index 92dbff1032..87148d01c4 100644 --- a/samples/MvcSample.Web/Models/ApiExplorerSamples/ProductOrderConfirmation.cs +++ b/samples/MvcSample.Web/Models/ApiExplorerSamples/ProductOrderConfirmation.cs @@ -1,6 +1,4 @@ -using System; - -namespace MvcSample.Web.ApiExplorerSamples +namespace MvcSample.Web.ApiExplorerSamples { public class ProductOrderConfirmation { diff --git a/samples/MvcSample.Web/Monitoring/MonitoringModule.cs b/samples/MvcSample.Web/Monitoring/MonitoringModule.cs index f742a4c03c..381322c53b 100644 --- a/samples/MvcSample.Web/Monitoring/MonitoringModule.cs +++ b/samples/MvcSample.Web/Monitoring/MonitoringModule.cs @@ -70,7 +70,7 @@ namespace MvcSample.Web _instances.Clear(); _registrations.Clear(); - // return count; + // return count; } } } diff --git a/samples/MvcSample.Web/Services/TestService.cs b/samples/MvcSample.Web/Services/TestService.cs index 153dfeaa75..345ed6d8fe 100644 --- a/samples/MvcSample.Web/Services/TestService.cs +++ b/samples/MvcSample.Web/Services/TestService.cs @@ -5,17 +5,17 @@ using System; namespace MvcSample.Web.Services { - public interface ITestService - { - string GetFoo(); - } + public interface ITestService + { + string GetFoo(); + } - public class TestService : ITestService - { - public string GetFoo() - { - return "Hello world " + DateTime.UtcNow; - } - } + public class TestService : ITestService + { + public string GetFoo() + { + return "Hello world " + DateTime.UtcNow; + } + } } \ No newline at end of file diff --git a/src/Microsoft.AspNet.Mvc.Common/CopyOnWriteDictionary.cs b/src/Microsoft.AspNet.Mvc.Common/CopyOnWriteDictionary.cs index 716e9245ea..2bd36c8a04 100644 --- a/src/Microsoft.AspNet.Mvc.Common/CopyOnWriteDictionary.cs +++ b/src/Microsoft.AspNet.Mvc.Common/CopyOnWriteDictionary.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. -using System; using System.Collections; using System.Collections.Generic; diff --git a/src/Microsoft.AspNet.Mvc.Core/ActionContext.cs b/src/Microsoft.AspNet.Mvc.Core/ActionContext.cs index ad2135f90b..79de5fffee 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ActionContext.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ActionContext.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. -using System; using System.Collections.Generic; using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc.ModelBinding; diff --git a/src/Microsoft.AspNet.Mvc.Core/ActionResult.cs b/src/Microsoft.AspNet.Mvc.Core/ActionResult.cs index d6cb12920e..f8f79de453 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ActionResult.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ActionResult.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. -using System; using System.Threading.Tasks; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/ActionResults/ContentResult.cs b/src/Microsoft.AspNet.Mvc.Core/ActionResults/ContentResult.cs index 38069e71c9..997a1dadc7 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ActionResults/ContentResult.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ActionResults/ContentResult.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. -using System; using System.Text; using System.Threading.Tasks; using Microsoft.AspNet.Http; diff --git a/src/Microsoft.AspNet.Mvc.Core/ActionResults/FileContentResult.cs b/src/Microsoft.AspNet.Mvc.Core/ActionResults/FileContentResult.cs index cb608f1ec8..9fe50228ee 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ActionResults/FileContentResult.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ActionResults/FileContentResult.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. -using System; using System.Threading; using System.Threading.Tasks; using Microsoft.AspNet.Http; diff --git a/src/Microsoft.AspNet.Mvc.Core/ActionResults/NoContentResult.cs b/src/Microsoft.AspNet.Mvc.Core/ActionResults/NoContentResult.cs index 95eef22d0e..59ee0f6edd 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ActionResults/NoContentResult.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ActionResults/NoContentResult.cs @@ -1,7 +1,9 @@ // 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. +#if ASPNET50 using System.Net; +#endif namespace Microsoft.AspNet.Mvc { diff --git a/src/Microsoft.AspNet.Mvc.Core/ActionResults/ObjectResult.cs b/src/Microsoft.AspNet.Mvc.Core/ActionResults/ObjectResult.cs index 3564310835..ce3b91e1d5 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ActionResults/ObjectResult.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ActionResults/ObjectResult.cs @@ -4,12 +4,9 @@ using System; using System.Collections.Generic; using System.Linq; -using System.Threading; using System.Threading.Tasks; -using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc.HeaderValueAbstractions; using Microsoft.Framework.DependencyInjection; -using Microsoft.Framework.OptionsModel; namespace Microsoft.AspNet.Mvc { diff --git a/src/Microsoft.AspNet.Mvc.Core/ActionResults/RedirectToActionResult.cs b/src/Microsoft.AspNet.Mvc.Core/ActionResults/RedirectToActionResult.cs index 0437909f0c..7798a220bd 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ActionResults/RedirectToActionResult.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ActionResults/RedirectToActionResult.cs @@ -3,7 +3,6 @@ using System; using System.Collections.Generic; -using System.Threading.Tasks; using Microsoft.AspNet.Mvc.Core; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/ActionResults/RedirectToRouteResult.cs b/src/Microsoft.AspNet.Mvc.Core/ActionResults/RedirectToRouteResult.cs index e658e5fcb3..1186e5a0ac 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ActionResults/RedirectToRouteResult.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ActionResults/RedirectToRouteResult.cs @@ -3,7 +3,6 @@ using System; using System.Collections.Generic; -using System.Threading.Tasks; using Microsoft.AspNet.Mvc.Core; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/AmbiguousActionException.cs b/src/Microsoft.AspNet.Mvc.Core/AmbiguousActionException.cs index c9e7f7f0fc..df59e59671 100644 --- a/src/Microsoft.AspNet.Mvc.Core/AmbiguousActionException.cs +++ b/src/Microsoft.AspNet.Mvc.Core/AmbiguousActionException.cs @@ -2,16 +2,18 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; +#if ASPNET50 using System.Runtime.Serialization; +#endif namespace Microsoft.AspNet.Mvc { /// /// An exception which indicates multiple matches in action selection. /// - #if ASPNET50 +#if ASPNET50 [Serializable] - #endif +#endif public class AmbiguousActionException : InvalidOperationException { public AmbiguousActionException(string message) @@ -19,11 +21,11 @@ namespace Microsoft.AspNet.Mvc { } - #if ASPNET50 +#if ASPNET50 protected AmbiguousActionException(SerializationInfo info, StreamingContext context) : base(info, context) { } - #endif +#endif } } \ No newline at end of file diff --git a/src/Microsoft.AspNet.Mvc.Core/AntiForgery/AntiForgery.cs b/src/Microsoft.AspNet.Mvc.Core/AntiForgery/AntiForgery.cs index 47f56a906b..644ee99287 100644 --- a/src/Microsoft.AspNet.Mvc.Core/AntiForgery/AntiForgery.cs +++ b/src/Microsoft.AspNet.Mvc.Core/AntiForgery/AntiForgery.cs @@ -5,7 +5,6 @@ using System.Threading.Tasks; using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc.Rendering; using Microsoft.AspNet.Security.DataProtection; -using Microsoft.Framework.DependencyInjection; using Microsoft.Framework.OptionsModel; namespace Microsoft.AspNet.Mvc @@ -80,7 +79,7 @@ namespace Microsoft.AspNet.Mvc /// The HTTP context associated with the current call. public async Task ValidateAsync([NotNull] HttpContext context) { - await _worker.ValidateAsync(context); + await _worker.ValidateAsync(context); } /// diff --git a/src/Microsoft.AspNet.Mvc.Core/AntiForgery/AntiForgeryToken.cs b/src/Microsoft.AspNet.Mvc.Core/AntiForgery/AntiForgeryToken.cs index 9eed0a7d30..3affb8fac6 100644 --- a/src/Microsoft.AspNet.Mvc.Core/AntiForgery/AntiForgeryToken.cs +++ b/src/Microsoft.AspNet.Mvc.Core/AntiForgery/AntiForgeryToken.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. -using System; namespace Microsoft.AspNet.Mvc { diff --git a/src/Microsoft.AspNet.Mvc.Core/AntiForgery/AntiForgeryTokenStore.cs b/src/Microsoft.AspNet.Mvc.Core/AntiForgery/AntiForgeryTokenStore.cs index 99b7a93b7e..0ab6401f88 100644 --- a/src/Microsoft.AspNet.Mvc.Core/AntiForgery/AntiForgeryTokenStore.cs +++ b/src/Microsoft.AspNet.Mvc.Core/AntiForgery/AntiForgeryTokenStore.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. -using System; using System.Diagnostics; using System.Threading.Tasks; using Microsoft.AspNet.Http; diff --git a/src/Microsoft.AspNet.Mvc.Core/AntiForgery/AntiForgeryWorker.cs b/src/Microsoft.AspNet.Mvc.Core/AntiForgery/AntiForgeryWorker.cs index a997d4f128..a2056fe0e3 100644 --- a/src/Microsoft.AspNet.Mvc.Core/AntiForgery/AntiForgeryWorker.cs +++ b/src/Microsoft.AspNet.Mvc.Core/AntiForgery/AntiForgeryWorker.cs @@ -158,11 +158,11 @@ namespace Microsoft.AspNet.Mvc oldCookieToken); return new AntiForgeryTokenSetInternal() - { - // Note : The new cookie would be null if the old cookie is valid. - CookieToken = newCookieToken, - FormToken = formToken - }; + { + // Note : The new cookie would be null if the old cookie is valid. + CookieToken = newCookieToken, + FormToken = formToken + }; } private string Serialize(AntiForgeryToken token) diff --git a/src/Microsoft.AspNet.Mvc.Core/AntiForgery/BinaryBlob.cs b/src/Microsoft.AspNet.Mvc.Core/AntiForgery/BinaryBlob.cs index 2bc8c9859c..2bb396b851 100644 --- a/src/Microsoft.AspNet.Mvc.Core/AntiForgery/BinaryBlob.cs +++ b/src/Microsoft.AspNet.Mvc.Core/AntiForgery/BinaryBlob.cs @@ -3,12 +3,10 @@ using System; using System.Diagnostics; -using System.Diagnostics.CodeAnalysis; using System.Globalization; using System.Runtime.CompilerServices; using System.Security.Cryptography; using System.Text; -using Microsoft.AspNet.Security.DataProtection; namespace Microsoft.AspNet.Mvc { diff --git a/src/Microsoft.AspNet.Mvc.Core/AntiForgery/IClaimUidExtractor.cs b/src/Microsoft.AspNet.Mvc.Core/AntiForgery/IClaimUidExtractor.cs index f3fa94b645..9210fa9245 100644 --- a/src/Microsoft.AspNet.Mvc.Core/AntiForgery/IClaimUidExtractor.cs +++ b/src/Microsoft.AspNet.Mvc.Core/AntiForgery/IClaimUidExtractor.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System.Security.Claims; -using System.Security.Principal; namespace Microsoft.AspNet.Mvc { diff --git a/src/Microsoft.AspNet.Mvc.Core/AntiForgery/ITokenGenerator.cs b/src/Microsoft.AspNet.Mvc.Core/AntiForgery/ITokenGenerator.cs index da048fd91f..535b95a7bf 100644 --- a/src/Microsoft.AspNet.Mvc.Core/AntiForgery/ITokenGenerator.cs +++ b/src/Microsoft.AspNet.Mvc.Core/AntiForgery/ITokenGenerator.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System.Security.Claims; -using System.Security.Principal; using Microsoft.AspNet.Http; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/AntiForgery/ITokenValidator.cs b/src/Microsoft.AspNet.Mvc.Core/AntiForgery/ITokenValidator.cs index 16dc9906c2..f66bf88a48 100644 --- a/src/Microsoft.AspNet.Mvc.Core/AntiForgery/ITokenValidator.cs +++ b/src/Microsoft.AspNet.Mvc.Core/AntiForgery/ITokenValidator.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System.Security.Claims; -using System.Security.Principal; using Microsoft.AspNet.Http; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/ApplicationModels/IActionModelBuilder.cs b/src/Microsoft.AspNet.Mvc.Core/ApplicationModels/IActionModelBuilder.cs index ee4aa5134c..7f27dc47cc 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ApplicationModels/IActionModelBuilder.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ApplicationModels/IActionModelBuilder.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. -using System; using System.Collections.Generic; using System.Reflection; diff --git a/src/Microsoft.AspNet.Mvc.Core/Controller.cs b/src/Microsoft.AspNet.Mvc.Core/Controller.cs index 6c3bb03aef..c617f4817f 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Controller.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Controller.cs @@ -8,10 +8,10 @@ using System.Text; using System.Threading.Tasks; using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc.Core; -using Microsoft.Framework.DependencyInjection; using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.AspNet.Mvc.Rendering; using Microsoft.AspNet.Routing; +using Microsoft.Framework.DependencyInjection; namespace Microsoft.AspNet.Mvc { diff --git a/src/Microsoft.AspNet.Mvc.Core/ControllerActionDescriptorProvider.cs b/src/Microsoft.AspNet.Mvc.Core/ControllerActionDescriptorProvider.cs index 5cfc27296d..c5bffe2322 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ControllerActionDescriptorProvider.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ControllerActionDescriptorProvider.cs @@ -4,9 +4,8 @@ using System; using System.Collections.Generic; using System.Linq; -using System.Reflection; -using Microsoft.AspNet.Mvc.Filters; using Microsoft.AspNet.Mvc.ApplicationModels; +using Microsoft.AspNet.Mvc.Filters; using Microsoft.Framework.OptionsModel; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/ControllerActionInvoker.cs b/src/Microsoft.AspNet.Mvc.Core/ControllerActionInvoker.cs index ffbed7e548..4d1b6ae9e9 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ControllerActionInvoker.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ControllerActionInvoker.cs @@ -6,7 +6,6 @@ using System.Collections.Generic; using System.Linq; using System.Threading.Tasks; using Microsoft.AspNet.Mvc.Core; -using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.Framework.DependencyInjection; namespace Microsoft.AspNet.Mvc @@ -103,9 +102,9 @@ namespace Microsoft.AspNet.Mvc } return new ObjectResult(actionReturnValue) - { - DeclaredType = actualReturnType - }; + { + DeclaredType = actualReturnType + }; } } } diff --git a/src/Microsoft.AspNet.Mvc.Core/ControllerActionInvokerProvider.cs b/src/Microsoft.AspNet.Mvc.Core/ControllerActionInvokerProvider.cs index 3706723041..b8b120f901 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ControllerActionInvokerProvider.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ControllerActionInvokerProvider.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.Framework.DependencyInjection; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/ControllerDescriptor.cs b/src/Microsoft.AspNet.Mvc.Core/ControllerDescriptor.cs index 0bd7b7024b..4f6283225e 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ControllerDescriptor.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ControllerDescriptor.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. -using System; using System.Reflection; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/DefaultOrder.cs b/src/Microsoft.AspNet.Mvc.Core/DefaultOrder.cs index a12a612953..f1c48f6052 100644 --- a/src/Microsoft.AspNet.Mvc.Core/DefaultOrder.cs +++ b/src/Microsoft.AspNet.Mvc.Core/DefaultOrder.cs @@ -2,11 +2,11 @@ { public static class DefaultOrder { - /// - /// The default order for sorting is -1000. Other framework code - /// the depends on order should be ordered between -1 to -1999. - /// User code should order at bigger than 0 or smaller than -2000. - /// + /// + /// The default order for sorting is -1000. Other framework code + /// the depends on order should be ordered between -1 to -1999. + /// User code should order at bigger than 0 or smaller than -2000. + /// public static readonly int DefaultFrameworkSortOrder = -1000; } } diff --git a/src/Microsoft.AspNet.Mvc.Core/Description/DefaultApiDescriptionProvider.cs b/src/Microsoft.AspNet.Mvc.Core/Description/DefaultApiDescriptionProvider.cs index c6a55e9cfb..830f96bbed 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Description/DefaultApiDescriptionProvider.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Description/DefaultApiDescriptionProvider.cs @@ -238,7 +238,7 @@ namespace Microsoft.AspNet.Mvc.Description templateParameter, parameterDescriptor); } - else if(templateParameter == null && parameterDescriptor != null) + else if (templateParameter == null && parameterDescriptor != null) { // The parameter is part of the ActionDescriptor but is not part of the route template. parameterDescription = CreateParameterFromParameterDescriptor(parameterDescriptor); diff --git a/src/Microsoft.AspNet.Mvc.Core/FilterActionInvoker.cs b/src/Microsoft.AspNet.Mvc.Core/FilterActionInvoker.cs index 6c4732fc50..c039ca0304 100644 --- a/src/Microsoft.AspNet.Mvc.Core/FilterActionInvoker.cs +++ b/src/Microsoft.AspNet.Mvc.Core/FilterActionInvoker.cs @@ -8,7 +8,6 @@ using System.Linq; using System.Runtime.ExceptionServices; using System.Threading.Tasks; using Microsoft.AspNet.Mvc.Core; -using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.Framework.DependencyInjection; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/Filters/AuthorizationContext.cs b/src/Microsoft.AspNet.Mvc.Core/Filters/AuthorizationContext.cs index bd16789ed2..7a72a82754 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Filters/AuthorizationContext.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Filters/AuthorizationContext.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System.Collections.Generic; -using Microsoft.AspNet.Mvc.Filters; namespace Microsoft.AspNet.Mvc { diff --git a/src/Microsoft.AspNet.Mvc.Core/Filters/AuthorizationFilterAttribute.cs b/src/Microsoft.AspNet.Mvc.Core/Filters/AuthorizationFilterAttribute.cs index 05b18baa9f..be3a462ff3 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Filters/AuthorizationFilterAttribute.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Filters/AuthorizationFilterAttribute.cs @@ -13,12 +13,12 @@ namespace Microsoft.AspNet.Mvc { public int Order { get; set; } - #pragma warning disable 1998 +#pragma warning disable 1998 public virtual async Task OnAuthorizationAsync([NotNull] AuthorizationContext context) { OnAuthorization(context); } - #pragma warning restore 1998 +#pragma warning restore 1998 public virtual void OnAuthorization([NotNull] AuthorizationContext context) { diff --git a/src/Microsoft.AspNet.Mvc.Core/Filters/AuthorizeAttribute.cs b/src/Microsoft.AspNet.Mvc.Core/Filters/AuthorizeAttribute.cs index 836b447921..d4ff495086 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Filters/AuthorizeAttribute.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Filters/AuthorizeAttribute.cs @@ -53,10 +53,10 @@ namespace Microsoft.AspNet.Mvc user.Identity == null || !user.Identity.IsAuthenticated; - if (userIsAnonymous && !HasAllowAnonymous(context)) - { - Fail(context); - } + if (userIsAnonymous && !HasAllowAnonymous(context)) + { + Fail(context); + } } else { diff --git a/src/Microsoft.AspNet.Mvc.Core/Filters/DefaultGlobalFilterProvider.cs b/src/Microsoft.AspNet.Mvc.Core/Filters/DefaultGlobalFilterProvider.cs index 8200c1c034..26ce093d2d 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Filters/DefaultGlobalFilterProvider.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Filters/DefaultGlobalFilterProvider.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System.Collections.Generic; -using System.Collections.ObjectModel; using System.Linq; using Microsoft.Framework.OptionsModel; diff --git a/src/Microsoft.AspNet.Mvc.Core/Filters/ExceptionFilterAttribute.cs b/src/Microsoft.AspNet.Mvc.Core/Filters/ExceptionFilterAttribute.cs index 26985f2b01..bad973eb3e 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Filters/ExceptionFilterAttribute.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Filters/ExceptionFilterAttribute.cs @@ -11,12 +11,12 @@ namespace Microsoft.AspNet.Mvc { public int Order { get; set; } - #pragma warning disable 1998 +#pragma warning disable 1998 public virtual async Task OnExceptionAsync([NotNull] ExceptionContext context) { OnException(context); } - #pragma warning restore 1998 +#pragma warning restore 1998 public virtual void OnException([NotNull] ExceptionContext context) { diff --git a/src/Microsoft.AspNet.Mvc.Core/Filters/IAsyncAuthorizationFilter.cs b/src/Microsoft.AspNet.Mvc.Core/Filters/IAsyncAuthorizationFilter.cs index 0dd3806320..54451873aa 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Filters/IAsyncAuthorizationFilter.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Filters/IAsyncAuthorizationFilter.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. -using System; using System.Threading.Tasks; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/Filters/IAsyncExceptionFilter.cs b/src/Microsoft.AspNet.Mvc.Core/Filters/IAsyncExceptionFilter.cs index 71b71ea217..83891377b4 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Filters/IAsyncExceptionFilter.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Filters/IAsyncExceptionFilter.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. -using System; using System.Threading.Tasks; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/Filters/IAuthorizationFilter.cs b/src/Microsoft.AspNet.Mvc.Core/Filters/IAuthorizationFilter.cs index 31d984671c..9b1cbccd50 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Filters/IAuthorizationFilter.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Filters/IAuthorizationFilter.cs @@ -1,8 +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. -using System; -using System.Threading.Tasks; namespace Microsoft.AspNet.Mvc { diff --git a/src/Microsoft.AspNet.Mvc.Core/Filters/IExceptionFilter.cs b/src/Microsoft.AspNet.Mvc.Core/Filters/IExceptionFilter.cs index 41bf88be1b..8d6bbf41e9 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Filters/IExceptionFilter.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Filters/IExceptionFilter.cs @@ -1,8 +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. -using System; -using System.Threading.Tasks; namespace Microsoft.AspNet.Mvc { diff --git a/src/Microsoft.AspNet.Mvc.Core/Formatters/DefaultInputFormattersProvider.cs b/src/Microsoft.AspNet.Mvc.Core/Formatters/DefaultInputFormattersProvider.cs index ea2df785a2..651695fe29 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Formatters/DefaultInputFormattersProvider.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Formatters/DefaultInputFormattersProvider.cs @@ -3,7 +3,6 @@ using System; using System.Collections.Generic; -using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.Framework.DependencyInjection; using Microsoft.Framework.OptionsModel; diff --git a/src/Microsoft.AspNet.Mvc.Core/Formatters/DelegatingStream.cs b/src/Microsoft.AspNet.Mvc.Core/Formatters/DelegatingStream.cs index c34bb0578f..0be1a3b322 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Formatters/DelegatingStream.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Formatters/DelegatingStream.cs @@ -1,7 +1,9 @@ // 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. +#if ASPNET50 using System; +#endif using System.IO; using System.Threading; using System.Threading.Tasks; diff --git a/src/Microsoft.AspNet.Mvc.Core/Formatters/FormattingUtilities.cs b/src/Microsoft.AspNet.Mvc.Core/Formatters/FormattingUtilities.cs index b799d39343..db52d37d35 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Formatters/FormattingUtilities.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Formatters/FormattingUtilities.cs @@ -1,7 +1,9 @@ // 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. +#if ASPNET50 using System.Runtime.Serialization; +#endif using System.Xml; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/Formatters/HttpNoContentOutputFormatter.cs b/src/Microsoft.AspNet.Mvc.Core/Formatters/HttpNoContentOutputFormatter.cs index 7c4327e7b4..f33d8641ee 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Formatters/HttpNoContentOutputFormatter.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Formatters/HttpNoContentOutputFormatter.cs @@ -24,7 +24,7 @@ namespace Microsoft.AspNet.Mvc // ignore the contentType and just look at the content. // This formatter will be selected if the content is null. // We check for Task as a user can directly create an ObjectContentResult with the unwrapped type. - if(context.DeclaredType == typeof(void) || context.DeclaredType == typeof(Task)) + if (context.DeclaredType == typeof(void) || context.DeclaredType == typeof(Task)) { return true; } diff --git a/src/Microsoft.AspNet.Mvc.Core/Formatters/IInputFormatter.cs b/src/Microsoft.AspNet.Mvc.Core/Formatters/IInputFormatter.cs index ac56ecd526..a61be7794a 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Formatters/IInputFormatter.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Formatters/IInputFormatter.cs @@ -1,10 +1,7 @@ // 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. -using System.Collections.Generic; -using System.Text; using System.Threading.Tasks; -using Microsoft.AspNet.Mvc.HeaderValueAbstractions; namespace Microsoft.AspNet.Mvc { diff --git a/src/Microsoft.AspNet.Mvc.Core/Formatters/IInputFormatterSelector.cs b/src/Microsoft.AspNet.Mvc.Core/Formatters/IInputFormatterSelector.cs index 4450a6618d..81dc2095d2 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Formatters/IInputFormatterSelector.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Formatters/IInputFormatterSelector.cs @@ -1,11 +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. -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; namespace Microsoft.AspNet.Mvc { diff --git a/src/Microsoft.AspNet.Mvc.Core/Formatters/IInputFormattersProvider.cs b/src/Microsoft.AspNet.Mvc.Core/Formatters/IInputFormattersProvider.cs index 9325f4e114..384bb0b878 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Formatters/IInputFormattersProvider.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Formatters/IInputFormattersProvider.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System.Collections.Generic; -using Microsoft.AspNet.Mvc.ModelBinding; namespace Microsoft.AspNet.Mvc { diff --git a/src/Microsoft.AspNet.Mvc.Core/Formatters/IOutputFormatter.cs b/src/Microsoft.AspNet.Mvc.Core/Formatters/IOutputFormatter.cs index a3b40c5d4a..4ab6f8455a 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Formatters/IOutputFormatter.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Formatters/IOutputFormatter.cs @@ -3,12 +3,7 @@ using System; using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading; using System.Threading.Tasks; -using Microsoft.AspNet.Http; -using Microsoft.AspNet.Mvc.Core; using Microsoft.AspNet.Mvc.HeaderValueAbstractions; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/Formatters/InputFormatterContext.cs b/src/Microsoft.AspNet.Mvc.Core/Formatters/InputFormatterContext.cs index 96a798ca86..3d43b394a4 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Formatters/InputFormatterContext.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Formatters/InputFormatterContext.cs @@ -2,9 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using System.Text; -using Microsoft.AspNet.Http; -using Microsoft.AspNet.Mvc.ModelBinding; namespace Microsoft.AspNet.Mvc { diff --git a/src/Microsoft.AspNet.Mvc.Core/Formatters/TextPlainFormatter.cs b/src/Microsoft.AspNet.Mvc.Core/Formatters/TextPlainFormatter.cs index 9570a0ed2b..c608381b8b 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Formatters/TextPlainFormatter.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Formatters/TextPlainFormatter.cs @@ -1,13 +1,8 @@ // 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. -using System; using System.IO; -using System.Text; -using System.Threading; using System.Threading.Tasks; -using Microsoft.AspNet.Http; -using Microsoft.AspNet.Mvc; using Microsoft.AspNet.Mvc.HeaderValueAbstractions; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/HttpDeleteAttribute.cs b/src/Microsoft.AspNet.Mvc.Core/HttpDeleteAttribute.cs index 7595f906d6..04f1eee627 100644 --- a/src/Microsoft.AspNet.Mvc.Core/HttpDeleteAttribute.cs +++ b/src/Microsoft.AspNet.Mvc.Core/HttpDeleteAttribute.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. -using System; using System.Collections.Generic; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/HttpGetAttribute.cs b/src/Microsoft.AspNet.Mvc.Core/HttpGetAttribute.cs index 8ef6d09939..bad4eb19ea 100644 --- a/src/Microsoft.AspNet.Mvc.Core/HttpGetAttribute.cs +++ b/src/Microsoft.AspNet.Mvc.Core/HttpGetAttribute.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. -using System; using System.Collections.Generic; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/HttpPatchAttribute.cs b/src/Microsoft.AspNet.Mvc.Core/HttpPatchAttribute.cs index 143b361d7e..6270fce84e 100644 --- a/src/Microsoft.AspNet.Mvc.Core/HttpPatchAttribute.cs +++ b/src/Microsoft.AspNet.Mvc.Core/HttpPatchAttribute.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. -using System; using System.Collections.Generic; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/HttpPostAttribute.cs b/src/Microsoft.AspNet.Mvc.Core/HttpPostAttribute.cs index 3a06c25aa8..8a9328dd46 100644 --- a/src/Microsoft.AspNet.Mvc.Core/HttpPostAttribute.cs +++ b/src/Microsoft.AspNet.Mvc.Core/HttpPostAttribute.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. -using System; using System.Collections.Generic; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/HttpPutAttribute.cs b/src/Microsoft.AspNet.Mvc.Core/HttpPutAttribute.cs index c1beff4256..47db4abde0 100644 --- a/src/Microsoft.AspNet.Mvc.Core/HttpPutAttribute.cs +++ b/src/Microsoft.AspNet.Mvc.Core/HttpPutAttribute.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. -using System; using System.Collections.Generic; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/Internal/MvcServicesHelper.cs b/src/Microsoft.AspNet.Mvc.Core/Internal/MvcServicesHelper.cs index 6e8a55b37c..5fb9f13067 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Internal/MvcServicesHelper.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Internal/MvcServicesHelper.cs @@ -3,7 +3,6 @@ using System; using Microsoft.AspNet.Mvc.Core; -using Microsoft.Framework.DependencyInjection; namespace Microsoft.AspNet.Mvc.Internal { diff --git a/src/Microsoft.AspNet.Mvc.Core/OptionDescriptors/InputFormatterDescriptor.cs b/src/Microsoft.AspNet.Mvc.Core/OptionDescriptors/InputFormatterDescriptor.cs index 1b2ccd5da3..8786acf4a4 100644 --- a/src/Microsoft.AspNet.Mvc.Core/OptionDescriptors/InputFormatterDescriptor.cs +++ b/src/Microsoft.AspNet.Mvc.Core/OptionDescriptors/InputFormatterDescriptor.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using Microsoft.AspNet.Mvc.ModelBinding; namespace Microsoft.AspNet.Mvc.OptionDescriptors { diff --git a/src/Microsoft.AspNet.Mvc.Core/OptionDescriptors/InputFormatterDescriptorExtensions.cs b/src/Microsoft.AspNet.Mvc.Core/OptionDescriptors/InputFormatterDescriptorExtensions.cs index 8b1902c1e5..17f6c06762 100644 --- a/src/Microsoft.AspNet.Mvc.Core/OptionDescriptors/InputFormatterDescriptorExtensions.cs +++ b/src/Microsoft.AspNet.Mvc.Core/OptionDescriptors/InputFormatterDescriptorExtensions.cs @@ -3,7 +3,6 @@ using System; using System.Collections.Generic; -using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.AspNet.Mvc.OptionDescriptors; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/ParameterBinding/IActionBindingContextProvider.cs b/src/Microsoft.AspNet.Mvc.Core/ParameterBinding/IActionBindingContextProvider.cs index b72cec6668..d03bce089e 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ParameterBinding/IActionBindingContextProvider.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ParameterBinding/IActionBindingContextProvider.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System.Threading.Tasks; -using Microsoft.AspNet.Mvc.ModelBinding; namespace Microsoft.AspNet.Mvc { diff --git a/src/Microsoft.AspNet.Mvc.Core/ParameterBinding/ModelBindingHelper.cs b/src/Microsoft.AspNet.Mvc.Core/ParameterBinding/ModelBindingHelper.cs index 76d3e0645d..ee97ebfee6 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ParameterBinding/ModelBindingHelper.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ParameterBinding/ModelBindingHelper.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. -using System.Collections.Generic; using System.Threading.Tasks; using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc.ModelBinding; diff --git a/src/Microsoft.AspNet.Mvc.Core/Rendering/Html/DefaultHtmlGenerator.cs b/src/Microsoft.AspNet.Mvc.Core/Rendering/Html/DefaultHtmlGenerator.cs index a5f6efd435..0c3f2754d1 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Rendering/Html/DefaultHtmlGenerator.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Rendering/Html/DefaultHtmlGenerator.cs @@ -851,58 +851,58 @@ namespace Microsoft.AspNet.Mvc.Rendering var usedModelState = false; switch (inputType) { - case InputType.CheckBox: - var modelStateWasChecked = GetModelStateValue(viewContext, fullName, typeof(bool)) as bool?; - if (modelStateWasChecked.HasValue) - { - isChecked = modelStateWasChecked.Value; - usedModelState = true; - } - - goto case InputType.Radio; - - case InputType.Radio: - if (!usedModelState) - { - var modelStateValue = GetModelStateValue(viewContext, fullName, typeof(string)) as string; - if (modelStateValue != null) + case InputType.CheckBox: + var modelStateWasChecked = GetModelStateValue(viewContext, fullName, typeof(bool)) as bool?; + if (modelStateWasChecked.HasValue) { - isChecked = string.Equals(modelStateValue, valueParameter, StringComparison.Ordinal); + isChecked = modelStateWasChecked.Value; usedModelState = true; } - } - if (!usedModelState && useViewData) - { - isChecked = EvalBoolean(viewContext, fullName); - } + goto case InputType.Radio; - if (isChecked) - { - tagBuilder.MergeAttribute("checked", "checked"); - } + case InputType.Radio: + if (!usedModelState) + { + var modelStateValue = GetModelStateValue(viewContext, fullName, typeof(string)) as string; + if (modelStateValue != null) + { + isChecked = string.Equals(modelStateValue, valueParameter, StringComparison.Ordinal); + usedModelState = true; + } + } - tagBuilder.MergeAttribute("value", valueParameter, isExplicitValue); - break; + if (!usedModelState && useViewData) + { + isChecked = EvalBoolean(viewContext, fullName); + } + + if (isChecked) + { + tagBuilder.MergeAttribute("checked", "checked"); + } - case InputType.Password: - if (value != null) - { tagBuilder.MergeAttribute("value", valueParameter, isExplicitValue); - } + break; - break; + case InputType.Password: + if (value != null) + { + tagBuilder.MergeAttribute("value", valueParameter, isExplicitValue); + } - case InputType.Text: - default: - var attributeValue = (string)GetModelStateValue(viewContext, fullName, typeof(string)); - if (attributeValue == null) - { - attributeValue = useViewData ? EvalString(viewContext, fullName, format) : valueParameter; - } + break; - tagBuilder.MergeAttribute("value", attributeValue, replaceExisting: isExplicitValue); - break; + case InputType.Text: + default: + var attributeValue = (string)GetModelStateValue(viewContext, fullName, typeof(string)); + if (attributeValue == null) + { + attributeValue = useViewData ? EvalString(viewContext, fullName, format) : valueParameter; + } + + tagBuilder.MergeAttribute("value", attributeValue, replaceExisting: isExplicitValue); + break; } if (setId) @@ -993,18 +993,18 @@ namespace Microsoft.AspNet.Mvc.Rendering { switch (inputType) { - case InputType.CheckBox: - return "checkbox"; - case InputType.Hidden: - return "hidden"; - case InputType.Password: - return "password"; - case InputType.Radio: - return "radio"; - case InputType.Text: - return "text"; - default: - return "text"; + case InputType.CheckBox: + return "checkbox"; + case InputType.Hidden: + return "hidden"; + case InputType.Password: + return "password"; + case InputType.Radio: + return "radio"; + case InputType.Text: + return "text"; + default: + return "text"; } } diff --git a/src/Microsoft.AspNet.Mvc.Core/Rendering/Html/TagBuilder.cs b/src/Microsoft.AspNet.Mvc.Core/Rendering/Html/TagBuilder.cs index e7622b7ad7..71272a2b2e 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Rendering/Html/TagBuilder.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Rendering/Html/TagBuilder.cs @@ -234,15 +234,15 @@ namespace Microsoft.AspNet.Mvc.Rendering { switch (testChar) { - case '-': - case '_': - case ':': - // Note '.' is valid according to the HTML 4.01 specification. Disallowed here to avoid confusion - // with CSS class selectors or when using jQuery. - return true; + case '-': + case '_': + case ':': + // Note '.' is valid according to the HTML 4.01 specification. Disallowed here to avoid confusion + // with CSS class selectors or when using jQuery. + return true; - default: - return false; + default: + return false; } } } diff --git a/src/Microsoft.AspNet.Mvc.Core/Rendering/MvcOptions.cs b/src/Microsoft.AspNet.Mvc.Core/Rendering/MvcOptions.cs index 34f355d499..ab5e271cd8 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Rendering/MvcOptions.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Rendering/MvcOptions.cs @@ -5,7 +5,6 @@ using System; using System.Collections.Generic; using Microsoft.AspNet.Mvc.ApplicationModels; using Microsoft.AspNet.Mvc.Core; -using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.AspNet.Mvc.OptionDescriptors; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/RequireHttpsAttribute.cs b/src/Microsoft.AspNet.Mvc.Core/RequireHttpsAttribute.cs index d6fa16f1b2..cc9745b59c 100644 --- a/src/Microsoft.AspNet.Mvc.Core/RequireHttpsAttribute.cs +++ b/src/Microsoft.AspNet.Mvc.Core/RequireHttpsAttribute.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using System.Threading.Tasks; namespace Microsoft.AspNet.Mvc { diff --git a/src/Microsoft.AspNet.Mvc.Core/Routing/ActionSelectorDecisionTree.cs b/src/Microsoft.AspNet.Mvc.Core/Routing/ActionSelectorDecisionTree.cs index c6353d6995..6084065a6f 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Routing/ActionSelectorDecisionTree.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Routing/ActionSelectorDecisionTree.cs @@ -3,7 +3,9 @@ using System; using System.Collections.Generic; +#if ASPNET50 using System.ComponentModel; +#endif using System.Diagnostics; using Microsoft.AspNet.Mvc.Internal.DecisionTree; diff --git a/src/Microsoft.AspNet.Mvc.Core/Routing/AttributeRoute.cs b/src/Microsoft.AspNet.Mvc.Core/Routing/AttributeRoute.cs index 228b5faa32..362d4c67f1 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Routing/AttributeRoute.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Routing/AttributeRoute.cs @@ -121,7 +121,7 @@ namespace Microsoft.AspNet.Mvc.Routing } } - if (_logger.IsEnabled(LogLevel.Verbose)) + if (_logger.IsEnabled(LogLevel.Verbose)) { _logger.WriteValues(new AttributeRouteRouteAsyncValues() { diff --git a/src/Microsoft.AspNet.Mvc.Core/Routing/AttributeRouteMatchingEntry.cs b/src/Microsoft.AspNet.Mvc.Core/Routing/AttributeRouteMatchingEntry.cs index 8816b3882f..505dfd2e0c 100644 --- a/src/Microsoft.AspNet.Mvc.Core/Routing/AttributeRouteMatchingEntry.cs +++ b/src/Microsoft.AspNet.Mvc.Core/Routing/AttributeRouteMatchingEntry.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. -using System.Collections.Generic; using Microsoft.AspNet.Routing.Template; namespace Microsoft.AspNet.Mvc.Routing diff --git a/src/Microsoft.AspNet.Mvc.Core/UrlHelper.cs b/src/Microsoft.AspNet.Mvc.Core/UrlHelper.cs index b5ebb491a8..66003c1a09 100644 --- a/src/Microsoft.AspNet.Mvc.Core/UrlHelper.cs +++ b/src/Microsoft.AspNet.Mvc.Core/UrlHelper.cs @@ -4,7 +4,6 @@ using System; using System.Collections.Generic; using System.Diagnostics; -using System.Linq; using Microsoft.AspNet.Http; using Microsoft.AspNet.Routing; using Microsoft.Framework.DependencyInjection; diff --git a/src/Microsoft.AspNet.Mvc.Core/ViewComponents/JsonViewComponentResult.cs b/src/Microsoft.AspNet.Mvc.Core/ViewComponents/JsonViewComponentResult.cs index d3b7ad3c2b..be3e34785b 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ViewComponents/JsonViewComponentResult.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ViewComponents/JsonViewComponentResult.cs @@ -1,9 +1,7 @@ // 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. -using System; using System.Threading.Tasks; -using Newtonsoft.Json; namespace Microsoft.AspNet.Mvc { @@ -22,11 +20,11 @@ namespace Microsoft.AspNet.Mvc formatter.WriteObject(context.Writer, Data); } - #pragma warning disable 1998 +#pragma warning disable 1998 public async Task ExecuteAsync([NotNull] ViewComponentContext context) { Execute(context); } - #pragma warning restore 1998 +#pragma warning restore 1998 } } diff --git a/src/Microsoft.AspNet.Mvc.Core/ViewComponents/ViewComponentContext.cs b/src/Microsoft.AspNet.Mvc.Core/ViewComponents/ViewComponentContext.cs index 6c18fe8cc1..49b0aead49 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ViewComponents/ViewComponentContext.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ViewComponents/ViewComponentContext.cs @@ -3,7 +3,6 @@ using System.IO; using System.Reflection; -using Microsoft.AspNet.Mvc.Rendering; namespace Microsoft.AspNet.Mvc { diff --git a/src/Microsoft.AspNet.Mvc.Core/ViewComponents/ViewComponentInvokerProviderContext.cs b/src/Microsoft.AspNet.Mvc.Core/ViewComponents/ViewComponentInvokerProviderContext.cs index 3e17764ed2..f2e63623fd 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ViewComponents/ViewComponentInvokerProviderContext.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ViewComponents/ViewComponentInvokerProviderContext.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. -using System; using System.Reflection; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.Core/ViewComponents/ViewViewComponentResult.cs b/src/Microsoft.AspNet.Mvc.Core/ViewComponents/ViewViewComponentResult.cs index 8a03ab2a7b..5cbf81f539 100644 --- a/src/Microsoft.AspNet.Mvc.Core/ViewComponents/ViewViewComponentResult.cs +++ b/src/Microsoft.AspNet.Mvc.Core/ViewComponents/ViewViewComponentResult.cs @@ -4,7 +4,6 @@ using System; using System.Globalization; using System.Threading.Tasks; -using Microsoft.AspNet.Mvc.Core; using Microsoft.AspNet.Mvc.Rendering; namespace Microsoft.AspNet.Mvc diff --git a/src/Microsoft.AspNet.Mvc.HeaderValueAbstractions/MediaTypeWithQualityHeaderValue.cs b/src/Microsoft.AspNet.Mvc.HeaderValueAbstractions/MediaTypeWithQualityHeaderValue.cs index 44903df4b3..5dc820ba99 100644 --- a/src/Microsoft.AspNet.Mvc.HeaderValueAbstractions/MediaTypeWithQualityHeaderValue.cs +++ b/src/Microsoft.AspNet.Mvc.HeaderValueAbstractions/MediaTypeWithQualityHeaderValue.cs @@ -36,14 +36,14 @@ namespace Microsoft.AspNet.Mvc.HeaderValueAbstractions } headerValue = new MediaTypeWithQualityHeaderValue() - { - MediaType = mediaTypeHeaderValue.MediaType, - MediaSubType = mediaTypeHeaderValue.MediaSubType, - MediaTypeRange = mediaTypeHeaderValue.MediaTypeRange, - Charset = mediaTypeHeaderValue.Charset, - Parameters = mediaTypeHeaderValue.Parameters, - Quality = quality, - }; + { + MediaType = mediaTypeHeaderValue.MediaType, + MediaSubType = mediaTypeHeaderValue.MediaSubType, + MediaTypeRange = mediaTypeHeaderValue.MediaTypeRange, + Charset = mediaTypeHeaderValue.Charset, + Parameters = mediaTypeHeaderValue.Parameters, + Quality = quality, + }; return true; } diff --git a/src/Microsoft.AspNet.Mvc.HeaderValueAbstractions/StringWithQualityHeaderValue.cs b/src/Microsoft.AspNet.Mvc.HeaderValueAbstractions/StringWithQualityHeaderValue.cs index 0d6bef346f..dae4a1b448 100644 --- a/src/Microsoft.AspNet.Mvc.HeaderValueAbstractions/StringWithQualityHeaderValue.cs +++ b/src/Microsoft.AspNet.Mvc.HeaderValueAbstractions/StringWithQualityHeaderValue.cs @@ -54,7 +54,7 @@ namespace Microsoft.AspNet.Mvc.HeaderValueAbstractions public static StringWithQualityHeaderValue Parse(string input) { StringWithQualityHeaderValue headerValue; - if(!TryParse(input, out headerValue)) + if (!TryParse(input, out headerValue)) { throw new ArgumentException(Resources.FormatInvalidAcceptCharset(input)); } diff --git a/src/Microsoft.AspNet.Mvc.ModelBinding/Binders/CompositeModelBinder.cs b/src/Microsoft.AspNet.Mvc.ModelBinding/Binders/CompositeModelBinder.cs index 461a6bd581..ffbf9fb2c3 100644 --- a/src/Microsoft.AspNet.Mvc.ModelBinding/Binders/CompositeModelBinder.cs +++ b/src/Microsoft.AspNet.Mvc.ModelBinding/Binders/CompositeModelBinder.cs @@ -2,8 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System.Collections.Generic; -using System.Globalization; -using System.Linq; using System.Runtime.CompilerServices; using System.Threading.Tasks; diff --git a/src/Microsoft.AspNet.Mvc.ModelBinding/Binders/ICompositeModelBinder.cs b/src/Microsoft.AspNet.Mvc.ModelBinding/Binders/ICompositeModelBinder.cs index 8e7498a282..7ba9ad00c6 100644 --- a/src/Microsoft.AspNet.Mvc.ModelBinding/Binders/ICompositeModelBinder.cs +++ b/src/Microsoft.AspNet.Mvc.ModelBinding/Binders/ICompositeModelBinder.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. -using System.Collections.Generic; namespace Microsoft.AspNet.Mvc.ModelBinding { diff --git a/src/Microsoft.AspNet.Mvc.ModelBinding/Metadata/AssociatedMetadataProvider.cs b/src/Microsoft.AspNet.Mvc.ModelBinding/Metadata/AssociatedMetadataProvider.cs index 3b47e89004..8ff812929e 100644 --- a/src/Microsoft.AspNet.Mvc.ModelBinding/Metadata/AssociatedMetadataProvider.cs +++ b/src/Microsoft.AspNet.Mvc.ModelBinding/Metadata/AssociatedMetadataProvider.cs @@ -199,7 +199,7 @@ namespace Microsoft.AspNet.Mvc.ModelBinding return new ParameterInformation { - Prototype = metadataProtoType + Prototype = metadataProtoType }; } diff --git a/src/Microsoft.AspNet.Mvc.ModelBinding/Validation/ClientModelValidationContext.cs b/src/Microsoft.AspNet.Mvc.ModelBinding/Validation/ClientModelValidationContext.cs index 542d47fca1..76101f10c7 100644 --- a/src/Microsoft.AspNet.Mvc.ModelBinding/Validation/ClientModelValidationContext.cs +++ b/src/Microsoft.AspNet.Mvc.ModelBinding/Validation/ClientModelValidationContext.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. -using System.Collections.Generic; namespace Microsoft.AspNet.Mvc.ModelBinding { diff --git a/src/Microsoft.AspNet.Mvc.ModelBinding/Validation/ModelClientValidationRegexRule.cs b/src/Microsoft.AspNet.Mvc.ModelBinding/Validation/ModelClientValidationRegexRule.cs index baca8aaf36..8db5f92558 100644 --- a/src/Microsoft.AspNet.Mvc.ModelBinding/Validation/ModelClientValidationRegexRule.cs +++ b/src/Microsoft.AspNet.Mvc.ModelBinding/Validation/ModelClientValidationRegexRule.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. -using System.Runtime.CompilerServices; namespace Microsoft.AspNet.Mvc.ModelBinding { diff --git a/src/Microsoft.AspNet.Mvc.ModelBinding/ValueProviders/FormValueProviderFactory.cs b/src/Microsoft.AspNet.Mvc.ModelBinding/ValueProviders/FormValueProviderFactory.cs index 4318068775..7c3a4b282c 100644 --- a/src/Microsoft.AspNet.Mvc.ModelBinding/ValueProviders/FormValueProviderFactory.cs +++ b/src/Microsoft.AspNet.Mvc.ModelBinding/ValueProviders/FormValueProviderFactory.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. -using System; using System.Globalization; using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc.HeaderValueAbstractions; diff --git a/src/Microsoft.AspNet.Mvc.ModelBinding/ValueProviders/MetadataAwareValueProvider.cs b/src/Microsoft.AspNet.Mvc.ModelBinding/ValueProviders/MetadataAwareValueProvider.cs index 7784fa9712..63123f688d 100644 --- a/src/Microsoft.AspNet.Mvc.ModelBinding/ValueProviders/MetadataAwareValueProvider.cs +++ b/src/Microsoft.AspNet.Mvc.ModelBinding/ValueProviders/MetadataAwareValueProvider.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. -using System; using System.Threading.Tasks; namespace Microsoft.AspNet.Mvc.ModelBinding diff --git a/src/Microsoft.AspNet.Mvc.Razor.Host/Directives/InjectChunkMerger.cs b/src/Microsoft.AspNet.Mvc.Razor.Host/Directives/InjectChunkMerger.cs index 5f93ca8233..70ab3a878c 100644 --- a/src/Microsoft.AspNet.Mvc.Razor.Host/Directives/InjectChunkMerger.cs +++ b/src/Microsoft.AspNet.Mvc.Razor.Host/Directives/InjectChunkMerger.cs @@ -3,7 +3,6 @@ using System; using System.Collections.Generic; -using System.Linq; using Microsoft.AspNet.Razor.Generator.Compiler; namespace Microsoft.AspNet.Mvc.Razor.Directives diff --git a/src/Microsoft.AspNet.Mvc.Razor.Host/GeneratedTagHelperAttributeContext.cs b/src/Microsoft.AspNet.Mvc.Razor.Host/GeneratedTagHelperAttributeContext.cs index 296959aeaf..3620d6426b 100644 --- a/src/Microsoft.AspNet.Mvc.Razor.Host/GeneratedTagHelperAttributeContext.cs +++ b/src/Microsoft.AspNet.Mvc.Razor.Host/GeneratedTagHelperAttributeContext.cs @@ -1,12 +1,11 @@ // 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. -using Microsoft.AspNet.Razor.Runtime.TagHelpers; - namespace Microsoft.AspNet.Mvc.Razor { /// - /// Contains information for the attribute code generation process. + /// Contains information for the attribute code + /// generation process. /// public class GeneratedTagHelperAttributeContext { diff --git a/src/Microsoft.AspNet.Mvc.Razor.Host/InjectChunkVisitor.cs b/src/Microsoft.AspNet.Mvc.Razor.Host/InjectChunkVisitor.cs index 42c289a7a7..5cd8548fb5 100644 --- a/src/Microsoft.AspNet.Mvc.Razor.Host/InjectChunkVisitor.cs +++ b/src/Microsoft.AspNet.Mvc.Razor.Host/InjectChunkVisitor.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System.Collections.Generic; -using System.Globalization; using Microsoft.AspNet.Razor.Generator; using Microsoft.AspNet.Razor.Generator.Compiler.CSharp; diff --git a/src/Microsoft.AspNet.Mvc.Razor/Compilation/CompilationFailedException.cs b/src/Microsoft.AspNet.Mvc.Razor/Compilation/CompilationFailedException.cs index 871e958d62..2b81c500aa 100644 --- a/src/Microsoft.AspNet.Mvc.Razor/Compilation/CompilationFailedException.cs +++ b/src/Microsoft.AspNet.Mvc.Razor/Compilation/CompilationFailedException.cs @@ -4,7 +4,6 @@ using System; using System.Collections.Generic; using System.Linq; -using Microsoft.AspNet.FileSystems; namespace Microsoft.AspNet.Mvc.Razor { diff --git a/src/Microsoft.AspNet.Mvc.Razor/Compilation/CompilerCacheEntry.cs b/src/Microsoft.AspNet.Mvc.Razor/Compilation/CompilerCacheEntry.cs index 4025a5c6bc..4972a1f3fd 100644 --- a/src/Microsoft.AspNet.Mvc.Razor/Compilation/CompilerCacheEntry.cs +++ b/src/Microsoft.AspNet.Mvc.Razor/Compilation/CompilerCacheEntry.cs @@ -65,6 +65,6 @@ namespace Microsoft.AspNet.Mvc.Razor /// /// Gets a flag that indicates if the file is precompiled. /// - public bool IsPreCompiled { get { return Hash != null; } } + public bool IsPreCompiled { get { return Hash != null; } } } } diff --git a/src/Microsoft.AspNet.Mvc.Razor/RazorViewEngine.cs b/src/Microsoft.AspNet.Mvc.Razor/RazorViewEngine.cs index 9b84c22f56..5f1cb87875 100644 --- a/src/Microsoft.AspNet.Mvc.Razor/RazorViewEngine.cs +++ b/src/Microsoft.AspNet.Mvc.Razor/RazorViewEngine.cs @@ -7,7 +7,6 @@ using System.Diagnostics; using System.Globalization; using Microsoft.AspNet.Mvc.Razor.OptionDescriptors; using Microsoft.AspNet.Mvc.Rendering; -using Microsoft.Framework.DependencyInjection; namespace Microsoft.AspNet.Mvc.Razor { diff --git a/src/Microsoft.AspNet.Mvc.TagHelpers/InputTagHelper.cs b/src/Microsoft.AspNet.Mvc.TagHelpers/InputTagHelper.cs index e4447cf67b..0a917e7400 100644 --- a/src/Microsoft.AspNet.Mvc.TagHelpers/InputTagHelper.cs +++ b/src/Microsoft.AspNet.Mvc.TagHelpers/InputTagHelper.cs @@ -161,36 +161,36 @@ namespace Microsoft.AspNet.Mvc.TagHelpers TagBuilder tagBuilder; switch (inputType) { - case "checkbox": - GenerateCheckBox(metadata, output); - return; + case "checkbox": + GenerateCheckBox(metadata, output); + return; - case "hidden": - tagBuilder = Generator.GenerateHidden( - ViewContext, - metadata, - For.Name, - value: metadata.Model, - useViewData: false, - htmlAttributes: null); - break; + case "hidden": + tagBuilder = Generator.GenerateHidden( + ViewContext, + metadata, + For.Name, + value: metadata.Model, + useViewData: false, + htmlAttributes: null); + break; - case "password": - tagBuilder = Generator.GeneratePassword( - ViewContext, - metadata, - For.Name, - value: null, - htmlAttributes: null); - break; + case "password": + tagBuilder = Generator.GeneratePassword( + ViewContext, + metadata, + For.Name, + value: null, + htmlAttributes: null); + break; - case "radio": - tagBuilder = GenerateRadio(metadata); - break; + case "radio": + tagBuilder = GenerateRadio(metadata); + break; - default: - tagBuilder = GenerateTextBox(metadata, inputTypeHint, inputType); - break; + default: + tagBuilder = GenerateTextBox(metadata, inputTypeHint, inputType); + break; } if (tagBuilder != null) diff --git a/src/Microsoft.AspNet.Mvc.TagHelpers/TextAreaTagHelper.cs b/src/Microsoft.AspNet.Mvc.TagHelpers/TextAreaTagHelper.cs index 586a9ed3a4..ed751977de 100644 --- a/src/Microsoft.AspNet.Mvc.TagHelpers/TextAreaTagHelper.cs +++ b/src/Microsoft.AspNet.Mvc.TagHelpers/TextAreaTagHelper.cs @@ -2,8 +2,8 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using Microsoft.AspNet.Mvc.Rendering; -using Microsoft.AspNet.Razor.TagHelpers; using Microsoft.AspNet.Razor.Runtime.TagHelpers; +using Microsoft.AspNet.Razor.TagHelpers; namespace Microsoft.AspNet.Mvc.TagHelpers { diff --git a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/ActionResults/InvalidModelStateResult.cs b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/ActionResults/InvalidModelStateResult.cs index 498d6b0614..f03d108321 100644 --- a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/ActionResults/InvalidModelStateResult.cs +++ b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/ActionResults/InvalidModelStateResult.cs @@ -3,8 +3,8 @@ using System.Net; using System.Threading.Tasks; -using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.AspNet.Mvc; +using Microsoft.AspNet.Mvc.ModelBinding; namespace System.Web.Http { diff --git a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/ActionResults/ResponseMessageResult.cs b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/ActionResults/ResponseMessageResult.cs index 397d625670..32fed522f6 100644 --- a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/ActionResults/ResponseMessageResult.cs +++ b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/ActionResults/ResponseMessageResult.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System.Net.Http; -using System.Threading.Tasks; using Microsoft.AspNet.Mvc; namespace System.Web.Http diff --git a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/ApiController.cs b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/ApiController.cs index f155079dfe..8e040f4ec4 100644 --- a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/ApiController.cs +++ b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/ApiController.cs @@ -13,7 +13,6 @@ using Microsoft.AspNet.Mvc.WebApiCompatShim; using Microsoft.AspNet.Routing; using Microsoft.Framework.DependencyInjection; using Newtonsoft.Json; -using MvcMediaTypeHeaderValue = Microsoft.AspNet.Mvc.HeaderValueAbstractions.MediaTypeHeaderValue; namespace System.Web.Http { diff --git a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/Formatters/HttpResponseMessageOutputFormatter.cs b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/Formatters/HttpResponseMessageOutputFormatter.cs index 0816da323b..655e926ad5 100644 --- a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/Formatters/HttpResponseMessageOutputFormatter.cs +++ b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/Formatters/HttpResponseMessageOutputFormatter.cs @@ -6,8 +6,8 @@ using System.Collections.Generic; using System.Linq; using System.Net.Http; using System.Threading.Tasks; -using Microsoft.AspNet.Mvc.HeaderValueAbstractions; using Microsoft.AspNet.HttpFeature; +using Microsoft.AspNet.Mvc.HeaderValueAbstractions; namespace Microsoft.AspNet.Mvc.WebApiCompatShim { diff --git a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/HttpRequestMessage/HttpRequestMessageExtensions.cs b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/HttpRequestMessage/HttpRequestMessageExtensions.cs index 49ca91d943..a5c61e5a9a 100644 --- a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/HttpRequestMessage/HttpRequestMessageExtensions.cs +++ b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/HttpRequestMessage/HttpRequestMessageExtensions.cs @@ -1,17 +1,16 @@ // Copyright (c) Microsoft Open Technologies, Inc. All rights reserved. See License.txt in the project root for license information. using System.Collections.Generic; +using System.Net.Http.Formatting; using System.Net.Http.Headers; using System.Web.Http; -using System.Net.Http.Formatting; using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc; using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.AspNet.Mvc.WebApiCompatShim; using Microsoft.Framework.DependencyInjection; - -using ShimResources = Microsoft.AspNet.Mvc.WebApiCompatShim.Resources; using Microsoft.Framework.OptionsModel; +using ShimResources = Microsoft.AspNet.Mvc.WebApiCompatShim.Resources; namespace System.Net.Http { diff --git a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/HttpRequestMessage/HttpRequestMessageModelBinder.cs b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/HttpRequestMessage/HttpRequestMessageModelBinder.cs index 7da8febdbf..a7761b795e 100644 --- a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/HttpRequestMessage/HttpRequestMessageModelBinder.cs +++ b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/HttpRequestMessage/HttpRequestMessageModelBinder.cs @@ -1,9 +1,9 @@ -using Microsoft.AspNet.Mvc.ModelBinding; -// Copyright (c) Microsoft Open Technologies, Inc. All rights reserved. +// 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. using System.Net.Http; using System.Threading.Tasks; +using Microsoft.AspNet.Mvc.ModelBinding; namespace Microsoft.AspNet.Mvc.WebApiCompatShim { diff --git a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/HttpRequestMessage/IHttpRequestMessageFeature.cs b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/HttpRequestMessage/IHttpRequestMessageFeature.cs index 246ad83c3c..3776e5db4d 100644 --- a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/HttpRequestMessage/IHttpRequestMessageFeature.cs +++ b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/HttpRequestMessage/IHttpRequestMessageFeature.cs @@ -7,6 +7,6 @@ namespace Microsoft.AspNet.Mvc.WebApiCompatShim { public interface IHttpRequestMessageFeature { - HttpRequestMessage HttpRequestMessage { get; set; } + HttpRequestMessage HttpRequestMessage { get; set; } } } diff --git a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/HttpResponseException.cs b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/HttpResponseException.cs index d87bc6f633..c804995857 100644 --- a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/HttpResponseException.cs +++ b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/HttpResponseException.cs @@ -1,9 +1,9 @@ // 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. -using Microsoft.AspNet.Mvc; using System.Net; using System.Net.Http; +using Microsoft.AspNet.Mvc; using ShimResources = Microsoft.AspNet.Mvc.WebApiCompatShim.Resources; namespace System.Web.Http diff --git a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/OverloadActionConstraint.cs b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/OverloadActionConstraint.cs index 99d6bed121..1808d8cd99 100644 --- a/src/Microsoft.AspNet.Mvc.WebApiCompatShim/OverloadActionConstraint.cs +++ b/src/Microsoft.AspNet.Mvc.WebApiCompatShim/OverloadActionConstraint.cs @@ -4,9 +4,9 @@ using System; using System.Collections.Generic; using System.Linq; +using System.Net.Http.Formatting; using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.AspNet.Routing; -using System.Net.Http.Formatting; namespace Microsoft.AspNet.Mvc.WebApiCompatShim { diff --git a/src/Microsoft.AspNet.Mvc/MvcOptionsSetup.cs b/src/Microsoft.AspNet.Mvc/MvcOptionsSetup.cs index 6b25295798..2c0e2f4690 100644 --- a/src/Microsoft.AspNet.Mvc/MvcOptionsSetup.cs +++ b/src/Microsoft.AspNet.Mvc/MvcOptionsSetup.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using System.Xml; using System.Xml.Linq; using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.AspNet.Mvc.Razor; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/FileContentResultTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/FileContentResultTest.cs index 5d0837b2b2..802e0ad346 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/FileContentResultTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/FileContentResultTest.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System.IO; -using System.Linq; using System.Threading.Tasks; using Microsoft.AspNet.PipelineCore; using Microsoft.AspNet.Routing; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/FilePathResultTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/FilePathResultTest.cs index 9a88d5e997..10291a6dac 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/FilePathResultTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/FilePathResultTest.cs @@ -1,18 +1,16 @@ // 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. -using System; using System.IO; using System.Threading; using System.Threading.Tasks; +using Microsoft.AspNet.FileSystems; using Microsoft.AspNet.Hosting; using Microsoft.AspNet.HttpFeature; -using Microsoft.AspNet.FileSystems; using Microsoft.AspNet.PipelineCore; using Microsoft.AspNet.Routing; using Microsoft.Framework.DependencyInjection; using Microsoft.Framework.DependencyInjection.Fallback; -using Microsoft.Framework.Runtime; using Moq; using Xunit; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/HttpStatusCodeResultTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/HttpStatusCodeResultTests.cs index ed4c548b90..f61af56f5c 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/HttpStatusCodeResultTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/HttpStatusCodeResultTests.cs @@ -1,6 +1,4 @@ -using System.IO; -using System.Threading.Tasks; -using Microsoft.AspNet.PipelineCore; +using Microsoft.AspNet.PipelineCore; using Microsoft.AspNet.Routing; using Xunit; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/ObjectResultTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/ObjectResultTests.cs index 5ddd3d02d1..d27fca8279 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/ObjectResultTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/ObjectResultTests.cs @@ -450,11 +450,11 @@ namespace Microsoft.AspNet.Mvc.Core.Test.ActionResults new RouteData(), new ActionDescriptor()); var formatterContext = new OutputFormatterContext() - { - ActionContext = tempActionContext, - Object = nonStringValue, - DeclaredType = nonStringValue.GetType() - }; + { + ActionContext = tempActionContext, + Object = nonStringValue, + DeclaredType = nonStringValue.GetType() + }; var formatter = new JsonOutputFormatter(); formatter.WriteResponseHeaders(formatterContext); await formatter.WriteAsync(formatterContext); diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/RedirectResultTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/RedirectResultTest.cs index 6c969114d8..ff538dba27 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/RedirectResultTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/RedirectResultTest.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using System.Collections.Generic; using Microsoft.AspNet.Http; using Microsoft.AspNet.Routing; using Microsoft.Framework.DependencyInjection; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/RedirectToActionResultTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/RedirectToActionResultTest.cs index d287ebd74d..4dd5e8b509 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/RedirectToActionResultTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/ActionResults/RedirectToActionResultTest.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using System.Collections.Generic; using Microsoft.AspNet.Http; using Microsoft.AspNet.Routing; using Microsoft.AspNet.Testing; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/AntiXsrf/AntiForgeryTokenSerializerTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/AntiXsrf/AntiForgeryTokenSerializerTest.cs index 7fcb56e40c..867a081506 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/AntiXsrf/AntiForgeryTokenSerializerTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/AntiXsrf/AntiForgeryTokenSerializerTest.cs @@ -3,10 +3,7 @@ using System; using System.Collections.Generic; -using System.Globalization; using System.Linq; -using System.Security.Claims; -using System.Text; using Microsoft.AspNet.Security.DataProtection; using Moq; using Xunit; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/AntiXsrf/TokenProviderTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/AntiXsrf/TokenProviderTests.cs index 1d496d738c..c7126dee1d 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/AntiXsrf/TokenProviderTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/AntiXsrf/TokenProviderTests.cs @@ -4,10 +4,7 @@ using System; using System.Security.Claims; using System.Security.Cryptography; -using System.Security.Principal; using Microsoft.AspNet.Http; -using Microsoft.AspNet.PipelineCore; -using Microsoft.AspNet.Security.DataProtection; using Moq; using Xunit; @@ -84,9 +81,9 @@ namespace Microsoft.AspNet.Mvc.Core.Test Assert.Throws( () => tokenProvider.GenerateFormToken(httpContext, identity, cookieToken)); Assert.Equal( - "The provided identity of type "+ - "'Microsoft.AspNet.Mvc.Core.Test.TokenProviderTest+MyAuthenticatedIdentityWithoutUsername' "+ - "is marked IsAuthenticated = true but does not have a value for Name. "+ + "The provided identity of type " + + "'Microsoft.AspNet.Mvc.Core.Test.TokenProviderTest+MyAuthenticatedIdentityWithoutUsername' " + + "is marked IsAuthenticated = true but does not have a value for Name. " + "By default, the anti-forgery system requires that all authenticated identities have a unique Name. " + "If it is not possible to provide a unique Name for this identity, " + "consider extending IAdditionalDataProvider by overriding the DefaultAdditionalDataProvider " + @@ -333,7 +330,7 @@ namespace Microsoft.AspNet.Mvc.Core.Test Assert.Throws( () => tokenProvider.ValidateTokens(httpContext, identity, fieldtoken, fieldtoken)); Assert.Equal( - "Validation of the provided anti-forgery token failed. "+ + "Validation of the provided anti-forgery token failed. " + @"The cookie ""my-cookie-name"" and the form field ""my-form-field-name"" were swapped.", ex1.Message); diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/AntiXsrf/ValidateAntiForgeryTokenAttributeTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/AntiXsrf/ValidateAntiForgeryTokenAttributeTest.cs index 808acd39ee..c890f750b9 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/AntiXsrf/ValidateAntiForgeryTokenAttributeTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/AntiXsrf/ValidateAntiForgeryTokenAttributeTest.cs @@ -1,12 +1,12 @@ // 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. +using Microsoft.AspNet.Security.DataProtection; using Microsoft.Framework.DependencyInjection; using Microsoft.Framework.DependencyInjection.Fallback; -using Microsoft.AspNet.Security.DataProtection; +using Microsoft.Framework.OptionsModel; using Moq; using Xunit; -using Microsoft.Framework.OptionsModel; namespace Microsoft.AspNet.Mvc.Core.Test { diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/ApplicationModel/AttributeRouteModelTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/ApplicationModel/AttributeRouteModelTests.cs index d46359d92c..233155c919 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/ApplicationModel/AttributeRouteModelTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/ApplicationModel/AttributeRouteModelTests.cs @@ -1,9 +1,9 @@ // 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. -using Microsoft.AspNet.Routing; using System; using System.Collections.Generic; +using Microsoft.AspNet.Routing; using Xunit; namespace Microsoft.AspNet.Mvc.ApplicationModels diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/BodyModelBinderTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/BodyModelBinderTests.cs index eba59afe8a..4c497179fc 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/BodyModelBinderTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/BodyModelBinderTests.cs @@ -9,7 +9,6 @@ using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.AspNet.PipelineCore; using Microsoft.AspNet.Routing; using Microsoft.Framework.DependencyInjection; -using Microsoft.Framework.OptionsModel; using Moq; using Xunit; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/ControllerActionDescriptorProviderTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/ControllerActionDescriptorProviderTests.cs index 33227b9bda..286f311e67 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/ControllerActionDescriptorProviderTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/ControllerActionDescriptorProviderTests.cs @@ -5,9 +5,9 @@ using System; using System.Collections.Generic; using System.Linq; using System.Reflection; +using Microsoft.AspNet.Mvc.ApplicationModels; using Microsoft.AspNet.Mvc.Description; using Microsoft.AspNet.Mvc.Routing; -using Microsoft.AspNet.Mvc.ApplicationModels; using Microsoft.Framework.OptionsModel; using Moq; using Xunit; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/ControllerActionInvokerTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/ControllerActionInvokerTest.cs index ed5e65b0af..038b732ae7 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/ControllerActionInvokerTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/ControllerActionInvokerTest.cs @@ -9,7 +9,6 @@ using System.Reflection; using System.Threading.Tasks; using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc.ModelBinding; -using Microsoft.AspNet.PipelineCore; using Microsoft.AspNet.Routing; using Microsoft.AspNet.Testing; using Microsoft.Framework.DependencyInjection; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/ControllerTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/ControllerTests.cs index b0c55f4c30..4f0b900fad 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/ControllerTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/ControllerTests.cs @@ -921,9 +921,9 @@ namespace Microsoft.AspNet.Mvc.Test .Returns(viewEngine); var httpContext = new Mock(); - httpContext - .Setup(c => c.RequestServices) - .Returns(serviceProvider.Object); + httpContext + .Setup(c => c.RequestServices) + .Returns(serviceProvider.Object); controller.ActionContext = new ActionContext(httpContext.Object, Mock.Of(), diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/DefaultActionSelectorTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/DefaultActionSelectorTests.cs index c78ee3da3c..cb709acaf7 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/DefaultActionSelectorTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/DefaultActionSelectorTests.cs @@ -5,8 +5,8 @@ using System; using System.Collections.Generic; using System.ComponentModel.Design; using System.Linq; -using System.Threading.Tasks; using System.Reflection; +using System.Threading.Tasks; using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc.ApplicationModels; using Microsoft.AspNet.Mvc.Logging; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/DefaultInputFormatterSelectorTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/DefaultInputFormatterSelectorTests.cs index 1fad3a7b76..4c47ad6f14 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/DefaultInputFormatterSelectorTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/DefaultInputFormatterSelectorTests.cs @@ -1,12 +1,10 @@ // 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. -using System; using System.Collections.Generic; using System.Threading.Tasks; using Microsoft.AspNet.Http; using Microsoft.AspNet.Routing; -using Microsoft.Framework.DependencyInjection; using Moq; using Xunit; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Filters/AuthorizeAttributeTestsBase.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Filters/AuthorizeAttributeTestsBase.cs index a48aecebac..2daddc8006 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Filters/AuthorizeAttributeTestsBase.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Filters/AuthorizeAttributeTestsBase.cs @@ -5,10 +5,10 @@ using System; using System.Linq; using System.Security.Claims; using Microsoft.AspNet.Http; +using Microsoft.AspNet.Routing; using Microsoft.Framework.DependencyInjection; using Microsoft.Framework.DependencyInjection.Fallback; using Moq; -using Microsoft.AspNet.Routing; namespace Microsoft.AspNet.Mvc.Core.Test { diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Filters/DefaultFilterProviderTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Filters/DefaultFilterProviderTest.cs index bb4ad77f9f..868f9f3443 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Filters/DefaultFilterProviderTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Filters/DefaultFilterProviderTest.cs @@ -7,9 +7,8 @@ using System.ComponentModel.Design; using System.Linq; using Microsoft.AspNet.PipelineCore; using Microsoft.AspNet.Routing; -using Microsoft.Framework.DependencyInjection; -using Xunit; using Moq; +using Xunit; namespace Microsoft.AspNet.Mvc.Filters { diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/DelegatingStreamTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/DelegatingStreamTests.cs index 716359adb8..8d4a09730d 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/DelegatingStreamTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/DelegatingStreamTests.cs @@ -3,10 +3,8 @@ #if ASPNET50 using System.IO; -using System.Threading; using System.Threading.Tasks; using Microsoft.AspNet.Mvc.Core; -using Moq; using Xunit; namespace Microsoft.AspNet.Mvc diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/JsonInputFormatterTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/JsonInputFormatterTest.cs index 93ba175f82..ead3939c9f 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/JsonInputFormatterTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/JsonInputFormatterTest.cs @@ -3,9 +3,9 @@ #if ASPNET50 using System; -using System.Linq; using System.Collections.Generic; using System.IO; +using System.Linq; using System.Text; using System.Threading.Tasks; using Microsoft.AspNet.Http; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/JsonOutputFormatterTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/JsonOutputFormatterTests.cs index 03bee39f53..ea2f23ea9b 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/JsonOutputFormatterTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/JsonOutputFormatterTests.cs @@ -2,14 +2,11 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using System.Collections.Generic; using System.IO; using System.Text; -using System.Threading; using System.Threading.Tasks; using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc.HeaderValueAbstractions; -using Microsoft.AspNet.Routing; using Moq; using Newtonsoft.Json; using Newtonsoft.Json.Serialization; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/NoContentFormatterTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/NoContentFormatterTests.cs index 6a63c56cd1..b21d3c2de8 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/NoContentFormatterTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/NoContentFormatterTests.cs @@ -3,14 +3,10 @@ using System; using System.Collections.Generic; -using System.Text; -using System.Threading; using System.Threading.Tasks; -using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc.HeaderValueAbstractions; using Microsoft.AspNet.PipelineCore; using Microsoft.AspNet.Routing; -using Moq; using Xunit; namespace Microsoft.AspNet.Mvc.Test diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/OutputFormatterTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/OutputFormatterTests.cs index bbbb0862c1..2818bcaa77 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/OutputFormatterTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/OutputFormatterTests.cs @@ -4,7 +4,6 @@ using System; using System.Collections.Generic; using System.Text; -using System.Threading; using System.Threading.Tasks; using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc.HeaderValueAbstractions; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/TextPlainFormatterTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/TextPlainFormatterTests.cs index ba0086aff7..6b6de7931d 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/TextPlainFormatterTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Formatters/TextPlainFormatterTests.cs @@ -1,14 +1,11 @@ // 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. -using System; using System.Collections.Generic; using System.IO; using System.Text; -using System.Threading; using System.Threading.Tasks; using Microsoft.AspNet.Http; -using Microsoft.AspNet.Mvc.HeaderValueAbstractions; using Microsoft.AspNet.Routing; using Moq; using Xunit; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/InputObjectBindingTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/InputObjectBindingTests.cs index 5f675d23fe..e07dca5054 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/InputObjectBindingTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/InputObjectBindingTests.cs @@ -13,7 +13,6 @@ using Microsoft.AspNet.Routing; using Microsoft.Framework.DependencyInjection; using Microsoft.Framework.OptionsModel; using Moq; -using Xunit; namespace Microsoft.AspNet.Mvc { diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Internal/DecisionTree/DecisionTreeBuilderTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Internal/DecisionTree/DecisionTreeBuilderTest.cs index 2e0f31079a..4d6ed1e329 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Internal/DecisionTree/DecisionTreeBuilderTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Internal/DecisionTree/DecisionTreeBuilderTest.cs @@ -1,9 +1,9 @@ // 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. -using Microsoft.AspNet.Mvc.Routing; using System; using System.Collections.Generic; +using Microsoft.AspNet.Mvc.Routing; using Xunit; namespace Microsoft.AspNet.Mvc.Internal.DecisionTree diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/JsonResultTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/JsonResultTest.cs index a911be5982..e352613dc0 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/JsonResultTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/JsonResultTest.cs @@ -34,7 +34,7 @@ namespace Microsoft.AspNet.Mvc }; var context = GetHttpContext(optionsFormatters); - var actionContext = new ActionContext(context, new RouteData(), new ActionDescriptor()); + var actionContext = new ActionContext(context, new RouteData(), new ActionDescriptor()); var result = new JsonResult(new { foo = "abcd" }); diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/KnownRouteValueConstraintTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/KnownRouteValueConstraintTests.cs index 1fbae11502..9afcdac612 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/KnownRouteValueConstraintTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/KnownRouteValueConstraintTests.cs @@ -142,9 +142,9 @@ namespace Microsoft.AspNet.Routing.Tests () => _constraint.Match(httpContext.Object, null, "area", - new Dictionary{ { "area", "area" } }, + new Dictionary { { "area", "area" } }, direction)); - Assert.Equal("The 'ActionDescriptors' property of "+ + Assert.Equal("The 'ActionDescriptors' property of " + "'Castle.Proxies.IActionDescriptorsCollectionProviderProxy' must not be null.", ex.Message); } diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Logging/TestLogger.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Logging/TestLogger.cs index 591de4bb5b..da509314e9 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Logging/TestLogger.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Logging/TestLogger.cs @@ -12,11 +12,11 @@ namespace Microsoft.AspNet.Mvc private TestSink _sink; private string _name; - public TestLogger(string name, TestSink sink) - { + public TestLogger(string name, TestSink sink) + { _sink = sink; _name = name; - } + } public string Name { get; set; } diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/MediaTypeWithQualityHeaderValueTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/MediaTypeWithQualityHeaderValueTests.cs index 6d7652361a..627d9afebb 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/MediaTypeWithQualityHeaderValueTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/MediaTypeWithQualityHeaderValueTests.cs @@ -1,14 +1,9 @@ // 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. -using System; using System.Collections.Generic; using System.Linq; -using System.Threading.Tasks; using Microsoft.AspNet.Mvc.HeaderValueAbstractions; -using Microsoft.AspNet.Http; -using Microsoft.AspNet.Routing; -using Moq; using Xunit; namespace Microsoft.AspNet.Mvc.Core.Test diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/MockMvcOptionsAccessor.cs b/test/Microsoft.AspNet.Mvc.Core.Test/MockMvcOptionsAccessor.cs index 050df56ea3..89050f49c6 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/MockMvcOptionsAccessor.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/MockMvcOptionsAccessor.cs @@ -7,10 +7,10 @@ namespace Microsoft.AspNet.Mvc { public class MockMvcOptionsAccessor : IOptions { - public MockMvcOptionsAccessor() - { + public MockMvcOptionsAccessor() + { Options = new MvcOptions(); - } + } public MvcOptions Options { get; private set; } diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/MvcRouteHandlerTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/MvcRouteHandlerTests.cs index f3be3f42ea..56388a5ba2 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/MvcRouteHandlerTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/MvcRouteHandlerTests.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using System.Collections.Generic; using System.Threading.Tasks; using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc.Internal; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/OptionDescriptors/InputFormatterDescriptorExtensionTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/OptionDescriptors/InputFormatterDescriptorExtensionTest.cs index 0feed6ca1f..4ad8286832 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/OptionDescriptors/InputFormatterDescriptorExtensionTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/OptionDescriptors/InputFormatterDescriptorExtensionTest.cs @@ -3,7 +3,6 @@ using System; using System.Collections.Generic; -using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.AspNet.Mvc.OptionDescriptors; using Moq; using Xunit; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/OptionDescriptors/InputFormatterDescriptorTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/OptionDescriptors/InputFormatterDescriptorTest.cs index 298b766a49..212589bd31 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/OptionDescriptors/InputFormatterDescriptorTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/OptionDescriptors/InputFormatterDescriptorTest.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using System.Collections.Generic; using System.Threading.Tasks; using Microsoft.AspNet.Mvc.OptionDescriptors; using Microsoft.AspNet.Testing; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/OptionDescriptors/OutputFormatterDescriptorTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/OptionDescriptors/OutputFormatterDescriptorTest.cs index 0a4affb277..c0dafa0fc2 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/OptionDescriptors/OutputFormatterDescriptorTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/OptionDescriptors/OutputFormatterDescriptorTest.cs @@ -3,7 +3,6 @@ using System; using System.Collections.Generic; -using System.Text; using System.Threading.Tasks; using Microsoft.AspNet.Mvc.HeaderValueAbstractions; using Microsoft.AspNet.Mvc.OptionDescriptors; @@ -27,7 +26,7 @@ namespace Microsoft.AspNet.Mvc.Core ExceptionAssert.ThrowsArgument(() => new OutputFormatterDescriptor(type), "type", expected); } - [Fact] + [Fact] public void ConstructorSets_OutputFormatterType() { // Arrange diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/Expression/ExpressionMetadataProviderTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/Expression/ExpressionMetadataProviderTest.cs index 7ab558e520..779512e4d7 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/Expression/ExpressionMetadataProviderTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/Expression/ExpressionMetadataProviderTest.cs @@ -18,7 +18,7 @@ namespace Microsoft.AspNet.Mvc.Rendering.Expressions viewData.Model = myModel; // Act - var metadata = ExpressionMetadataProvider.FromLambdaExpression( + var metadata = ExpressionMetadataProvider.FromLambdaExpression( model => model.SelectedCategory, viewData, provider); diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/HtmlHelperCheckboxTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/HtmlHelperCheckboxTest.cs index 2d7de1f772..be8ea71cc8 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/HtmlHelperCheckboxTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/HtmlHelperCheckboxTest.cs @@ -201,7 +201,7 @@ namespace Microsoft.AspNet.Mvc.Rendering public void CheckBoxWithComplexExpressionsEvaluatesValuesInViewDataDictionary() { // Arrange - var expected = @""; var helper = DefaultTemplatesUtilities.GetHtmlHelper(GetModelWithValidationViewData()); diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/HtmlHelperLabelExtensionsTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/HtmlHelperLabelExtensionsTest.cs index 24d934a855..50c2511417 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/HtmlHelperLabelExtensionsTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/HtmlHelperLabelExtensionsTest.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using System.Collections.Generic; using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.AspNet.Mvc.Rendering; using Moq; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/HtmlHelperTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/HtmlHelperTest.cs index 0d5aef76cb..2757604593 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/HtmlHelperTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/HtmlHelperTest.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System.Collections.Generic; -using System.Linq; using Xunit; namespace Microsoft.AspNet.Mvc.Rendering diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/HtmlHelperValueExtensionsTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/HtmlHelperValueExtensionsTest.cs index 209aee8b12..73028c093c 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/HtmlHelperValueExtensionsTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/HtmlHelperValueExtensionsTest.cs @@ -2,12 +2,10 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using System.Collections.Generic; using System.Globalization; -using Microsoft.AspNet.Testing; using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.AspNet.Mvc.Rendering; -using Moq; +using Microsoft.AspNet.Testing; using Xunit; namespace Microsoft.AspNet.Mvc.Core diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/ViewEngine/CompositeViewEngineTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/ViewEngine/CompositeViewEngineTest.cs index eeb08be2aa..a36eaad895 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/ViewEngine/CompositeViewEngineTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Rendering/ViewEngine/CompositeViewEngineTest.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. -using System.Collections.Generic; using System.Linq; using Microsoft.AspNet.Http; using Microsoft.AspNet.Routing; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/RequireHttpsAttributeTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/RequireHttpsAttributeTests.cs index 2461269880..6fcf85ac94 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/RequireHttpsAttributeTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/RequireHttpsAttributeTests.cs @@ -3,11 +3,10 @@ using System.Collections.Generic; using System.Linq; -using Moq; -using Xunit; using Microsoft.AspNet.Http; using Microsoft.AspNet.PipelineCore; using Microsoft.AspNet.Routing; +using Xunit; namespace Microsoft.AspNet.Mvc { diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Routing/AttributeRoutePrecedenceTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Routing/AttributeRoutePrecedenceTests.cs index 21064e5d6e..ca319a2914 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Routing/AttributeRoutePrecedenceTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Routing/AttributeRoutePrecedenceTests.cs @@ -6,7 +6,6 @@ using Microsoft.AspNet.Routing; using Microsoft.AspNet.Routing.Template; using Microsoft.Framework.OptionsModel; using Moq; -using System; using Xunit; namespace Microsoft.AspNet.Mvc.Routing diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Routing/AttributeRouteTests.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Routing/AttributeRouteTests.cs index eab19973ab..23478c6fe5 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Routing/AttributeRouteTests.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Routing/AttributeRouteTests.cs @@ -6,11 +6,11 @@ using System.Collections.Generic; using System.Linq; using System.Threading.Tasks; using Microsoft.AspNet.Http; +using Microsoft.AspNet.Mvc.Logging; using Microsoft.AspNet.Routing; using Microsoft.AspNet.Routing.Template; -using Microsoft.AspNet.Mvc.Logging; -using Microsoft.Framework.OptionsModel; using Microsoft.Framework.Logging; +using Microsoft.Framework.OptionsModel; using Moq; using Xunit; diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/Routing/AttributeRoutingTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/Routing/AttributeRoutingTest.cs index 7416473691..ec96c45b82 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/Routing/AttributeRoutingTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/Routing/AttributeRoutingTest.cs @@ -2,11 +2,11 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. #if ASPNET50 +using System; +using System.Collections.Generic; using Microsoft.AspNet.Routing; using Microsoft.Framework.OptionsModel; using Moq; -using System; -using System.Collections.Generic; using Xunit; namespace Microsoft.AspNet.Mvc.Routing diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/TestController.cs b/test/Microsoft.AspNet.Mvc.Core.Test/TestController.cs index 86f8f27386..369f4a7778 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/TestController.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/TestController.cs @@ -12,38 +12,38 @@ namespace Microsoft.AspNet.Mvc.Core.Test { } - #pragma warning disable 1998 +#pragma warning disable 1998 public async Task TaskAction(int i, string s) { return; } - #pragma warning restore 1998 +#pragma warning restore 1998 - #pragma warning disable 1998 +#pragma warning disable 1998 public async Task TaskValueTypeAction(int i, string s) { return i; } - #pragma warning restore 1998 +#pragma warning restore 1998 - #pragma warning disable 1998 +#pragma warning disable 1998 public async Task> TaskOfTaskAction(int i, string s) { return TaskValueTypeAction(i, s); } - #pragma warning restore 1998 +#pragma warning restore 1998 public Task TaskValueTypeActionWithoutAsync(int i, string s) { return TaskValueTypeAction(i, s); } - #pragma warning disable 1998 +#pragma warning disable 1998 public async Task TaskActionWithException(int i, string s) { throw new NotImplementedException("Not Implemented Exception"); } - #pragma warning restore 1998 +#pragma warning restore 1998 public Task TaskActionWithExceptionWithoutAsync(int i, string s) { diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/TypeHelperTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/TypeHelperTest.cs index 54cc2aaee2..e31ccda9f8 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/TypeHelperTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/TypeHelperTest.cs @@ -86,7 +86,7 @@ namespace Microsoft.AspNet.Mvc public void ObjectToDictionary_ReturnsInheritedProperties() { // Arrange - var value = new ThreeDPoint() {X = 5, Y = 10, Z = 17}; + var value = new ThreeDPoint() { X = 5, Y = 10, Z = 17 }; // Act var dictValues = TypeHelper.ObjectToDictionary(value); diff --git a/test/Microsoft.AspNet.Mvc.Core.Test/UrlHelperTest.cs b/test/Microsoft.AspNet.Mvc.Core.Test/UrlHelperTest.cs index a407c8d1cb..c2c490a6b9 100644 --- a/test/Microsoft.AspNet.Mvc.Core.Test/UrlHelperTest.cs +++ b/test/Microsoft.AspNet.Mvc.Core.Test/UrlHelperTest.cs @@ -6,10 +6,10 @@ using System.Collections.Generic; using Microsoft.AspNet.Http; using Microsoft.AspNet.Routing; using Microsoft.Framework.DependencyInjection; +using Microsoft.Framework.Logging; using Microsoft.Framework.OptionsModel; using Moq; using Xunit; -using Microsoft.Framework.Logging; namespace Microsoft.AspNet.Mvc.Core.Test { diff --git a/test/Microsoft.AspNet.Mvc.FunctionalTests/ApiExplorerTest.cs b/test/Microsoft.AspNet.Mvc.FunctionalTests/ApiExplorerTest.cs index a75f62c00a..b167f31292 100644 --- a/test/Microsoft.AspNet.Mvc.FunctionalTests/ApiExplorerTest.cs +++ b/test/Microsoft.AspNet.Mvc.FunctionalTests/ApiExplorerTest.cs @@ -7,8 +7,8 @@ using System.Net.Http; using System.Threading.Tasks; using Microsoft.AspNet.Builder; using Microsoft.AspNet.TestHost; -using Xunit; using Newtonsoft.Json; +using Xunit; namespace Microsoft.AspNet.Mvc.FunctionalTests { diff --git a/test/Microsoft.AspNet.Mvc.FunctionalTests/ApplicationModelTest.cs b/test/Microsoft.AspNet.Mvc.FunctionalTests/ApplicationModelTest.cs index 049319a710..50cb6af45e 100644 --- a/test/Microsoft.AspNet.Mvc.FunctionalTests/ApplicationModelTest.cs +++ b/test/Microsoft.AspNet.Mvc.FunctionalTests/ApplicationModelTest.cs @@ -2,11 +2,11 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; +using System.Net; using System.Threading.Tasks; using Microsoft.AspNet.Builder; using Microsoft.AspNet.TestHost; using Xunit; -using System.Net; namespace Microsoft.AspNet.Mvc.FunctionalTests { diff --git a/test/Microsoft.AspNet.Mvc.FunctionalTests/ConnegTests.cs b/test/Microsoft.AspNet.Mvc.FunctionalTests/ConnegTests.cs index 567921fa68..ca20a57065 100644 --- a/test/Microsoft.AspNet.Mvc.FunctionalTests/ConnegTests.cs +++ b/test/Microsoft.AspNet.Mvc.FunctionalTests/ConnegTests.cs @@ -10,7 +10,6 @@ using System.Threading.Tasks; using ConnegWebsite; using Microsoft.AspNet.Builder; using Microsoft.AspNet.TestHost; -using Newtonsoft.Json; using Xunit; namespace Microsoft.AspNet.Mvc.FunctionalTests diff --git a/test/Microsoft.AspNet.Mvc.FunctionalTests/FlushPointTest.cs b/test/Microsoft.AspNet.Mvc.FunctionalTests/FlushPointTest.cs index b3fb2bec39..efcfcba7de 100644 --- a/test/Microsoft.AspNet.Mvc.FunctionalTests/FlushPointTest.cs +++ b/test/Microsoft.AspNet.Mvc.FunctionalTests/FlushPointTest.cs @@ -8,7 +8,6 @@ using System.Threading.Tasks; using Microsoft.AspNet.Builder; using Microsoft.AspNet.TestHost; using Microsoft.Framework.DependencyInjection; -using Microsoft.Framework.DependencyInjection.Fallback; using RazorWebSite; using Xunit; diff --git a/test/Microsoft.AspNet.Mvc.FunctionalTests/NullLoggerFactory.cs b/test/Microsoft.AspNet.Mvc.FunctionalTests/NullLoggerFactory.cs index 22af435de9..5ba975769f 100644 --- a/test/Microsoft.AspNet.Mvc.FunctionalTests/NullLoggerFactory.cs +++ b/test/Microsoft.AspNet.Mvc.FunctionalTests/NullLoggerFactory.cs @@ -1,5 +1,5 @@ -using Microsoft.Framework.Logging; -using System; +using System; +using Microsoft.Framework.Logging; namespace Microsoft.AspNet.Mvc { diff --git a/test/Microsoft.AspNet.Mvc.FunctionalTests/TestAssemblyProvider.cs b/test/Microsoft.AspNet.Mvc.FunctionalTests/TestAssemblyProvider.cs index 1ef1bec151..cc69db2a66 100644 --- a/test/Microsoft.AspNet.Mvc.FunctionalTests/TestAssemblyProvider.cs +++ b/test/Microsoft.AspNet.Mvc.FunctionalTests/TestAssemblyProvider.cs @@ -15,10 +15,10 @@ namespace Microsoft.AspNet.Mvc.FunctionalTests /// public class TestAssemblyProvider : IAssemblyProvider { - public TestAssemblyProvider() - { + public TestAssemblyProvider() + { CandidateAssemblies = new Assembly[] { typeof(T).GetTypeInfo().Assembly }; - } + } public IEnumerable CandidateAssemblies { get; private set; } } diff --git a/test/Microsoft.AspNet.Mvc.FunctionalTests/VersioningTests.cs b/test/Microsoft.AspNet.Mvc.FunctionalTests/VersioningTests.cs index 8e844de594..82a371b710 100644 --- a/test/Microsoft.AspNet.Mvc.FunctionalTests/VersioningTests.cs +++ b/test/Microsoft.AspNet.Mvc.FunctionalTests/VersioningTests.cs @@ -3,7 +3,6 @@ using System; using System.Collections.Generic; -using System.Linq; using System.Net; using System.Net.Http; using System.Threading.Tasks; @@ -576,7 +575,7 @@ namespace Microsoft.AspNet.Mvc.FunctionalTests var path = "/" + version + "/Vouchers?version=" + version; // Act - var message = new HttpRequestMessage(HttpMethod.Get, "http://localhost" + path); + var message = new HttpRequestMessage(HttpMethod.Get, "http://localhost" + path); var response = await client.SendAsync(message); // Assert diff --git a/test/Microsoft.AspNet.Mvc.FunctionalTests/WebApiCompatShimActionResultTest.cs b/test/Microsoft.AspNet.Mvc.FunctionalTests/WebApiCompatShimActionResultTest.cs index 97ca56638a..537834aa27 100644 --- a/test/Microsoft.AspNet.Mvc.FunctionalTests/WebApiCompatShimActionResultTest.cs +++ b/test/Microsoft.AspNet.Mvc.FunctionalTests/WebApiCompatShimActionResultTest.cs @@ -2,16 +2,10 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using System.Collections.Generic; using System.Net; -using System.Net.Http; -using System.Net.Http.Formatting; -using System.Net.Http.Headers; using System.Threading.Tasks; -using System.Web.Http; using Microsoft.AspNet.Builder; using Microsoft.AspNet.TestHost; -using Newtonsoft.Json; using Xunit; namespace Microsoft.AspNet.Mvc.FunctionalTests diff --git a/test/Microsoft.AspNet.Mvc.FunctionalTests/WebApiCompatShimBasicTest.cs b/test/Microsoft.AspNet.Mvc.FunctionalTests/WebApiCompatShimBasicTest.cs index 1bf3c0bade..532fe2de37 100644 --- a/test/Microsoft.AspNet.Mvc.FunctionalTests/WebApiCompatShimBasicTest.cs +++ b/test/Microsoft.AspNet.Mvc.FunctionalTests/WebApiCompatShimBasicTest.cs @@ -112,7 +112,7 @@ namespace Microsoft.AspNet.Mvc.FunctionalTests // Act var response = await client.GetAsync( - "http://localhost/api/Blog/HttpResponseException"+ + "http://localhost/api/Blog/HttpResponseException" + "/ThrowsHttpResponseExceptionWithHttpResponseMessage?message=send some message"); // Assert @@ -148,7 +148,7 @@ namespace Microsoft.AspNet.Mvc.FunctionalTests // Act var response = await client.GetAsync( - "http://localhost/api/Blog/"+ + "http://localhost/api/Blog/" + "HttpResponseException/ThrowsHttpResponseExceptionInjectAFilterToHandleHttpResponseException"); // Assert @@ -490,7 +490,7 @@ namespace Microsoft.AspNet.Mvc.FunctionalTests var client = server.CreateClient(); // Act - var response = await client.GetAsync("http://localhost/api/Blog/HttpRequestMessage/" + action ); + var response = await client.GetAsync("http://localhost/api/Blog/HttpRequestMessage/" + action); // Assert Assert.Equal(HttpStatusCode.OK, response.StatusCode); diff --git a/test/Microsoft.AspNet.Mvc.FunctionalTests/WebApiCompatShimParameterBindingTest.cs b/test/Microsoft.AspNet.Mvc.FunctionalTests/WebApiCompatShimParameterBindingTest.cs index 4982ceb714..9f00d1d6a9 100644 --- a/test/Microsoft.AspNet.Mvc.FunctionalTests/WebApiCompatShimParameterBindingTest.cs +++ b/test/Microsoft.AspNet.Mvc.FunctionalTests/WebApiCompatShimParameterBindingTest.cs @@ -5,10 +5,8 @@ using System; using System.Collections.Generic; using System.Net; using System.Net.Http; -using System.Net.Http.Formatting; using System.Net.Http.Headers; using System.Threading.Tasks; -using System.Web.Http; using Microsoft.AspNet.Builder; using Microsoft.AspNet.TestHost; using Newtonsoft.Json; diff --git a/test/Microsoft.AspNet.Mvc.FunctionalTests/XmlOutputFormatterTests.cs b/test/Microsoft.AspNet.Mvc.FunctionalTests/XmlOutputFormatterTests.cs index 2708fc1b11..d3d2ddb2a2 100644 --- a/test/Microsoft.AspNet.Mvc.FunctionalTests/XmlOutputFormatterTests.cs +++ b/test/Microsoft.AspNet.Mvc.FunctionalTests/XmlOutputFormatterTests.cs @@ -5,7 +5,6 @@ using System; using System.Net; using System.Net.Http; using System.Net.Http.Headers; -using System.Runtime.Serialization; using System.Threading.Tasks; using Microsoft.AspNet.Builder; using Microsoft.AspNet.TestHost; diff --git a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Binders/CollectionModelBinderTest.cs b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Binders/CollectionModelBinderTest.cs index 0204c32d8c..446ab01113 100644 --- a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Binders/CollectionModelBinderTest.cs +++ b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Binders/CollectionModelBinderTest.cs @@ -1,9 +1,11 @@ // 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. +#if ASPNET50 using System.Collections.Generic; using System.Globalization; using System.Linq; +#endif using System.Threading.Tasks; #if ASPNET50 using Moq; diff --git a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Binders/ComplexModelDtoResultTest.cs b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Binders/ComplexModelDtoResultTest.cs index e6902e0335..4380dc5ca9 100644 --- a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Binders/ComplexModelDtoResultTest.cs +++ b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Binders/ComplexModelDtoResultTest.cs @@ -26,6 +26,6 @@ namespace Microsoft.AspNet.Mvc.ModelBinding.Test var provider = new EmptyModelMetadataProvider(); var metadata = provider.GetMetadataForType(null, typeof(object)); return new ModelValidationNode(metadata, "someKey"); + } } } -} diff --git a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Metadata/AssociatedMetadataProviderTest.cs b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Metadata/AssociatedMetadataProviderTest.cs index b4079bf18d..459fc42335 100644 --- a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Metadata/AssociatedMetadataProviderTest.cs +++ b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Metadata/AssociatedMetadataProviderTest.cs @@ -3,7 +3,9 @@ using System; using System.Collections.Generic; +#if ASPNET50 using System.ComponentModel; +#endif using System.ComponentModel.DataAnnotations; using System.Linq; using Microsoft.AspNet.Testing; diff --git a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ModelBindingContextTest.cs b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ModelBindingContextTest.cs index 64ff538c3d..f4e913d2a3 100644 --- a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ModelBindingContextTest.cs +++ b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ModelBindingContextTest.cs @@ -1,12 +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. -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using Xunit; namespace Microsoft.AspNet.Mvc.ModelBinding.Test { diff --git a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Validation/DataAnnotationsModelValidatorTest.cs b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Validation/DataAnnotationsModelValidatorTest.cs index 10980960bc..ade8168826 100644 --- a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Validation/DataAnnotationsModelValidatorTest.cs +++ b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/Validation/DataAnnotationsModelValidatorTest.cs @@ -3,8 +3,8 @@ using System.Collections.Generic; using System.ComponentModel.DataAnnotations; -using System.Linq; #if ASPNET50 +using System.Linq; using Moq; using Moq.Protected; #endif diff --git a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ValueProviders/DictionaryBasedValueProviderTests.cs b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ValueProviders/DictionaryBasedValueProviderTests.cs index e58d3d772b..837587fff8 100644 --- a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ValueProviders/DictionaryBasedValueProviderTests.cs +++ b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ValueProviders/DictionaryBasedValueProviderTests.cs @@ -187,7 +187,7 @@ namespace Microsoft.AspNet.Mvc.ModelBinding { } - private class DerivedValueProviderMetadata :TestValueProviderMetadata + private class DerivedValueProviderMetadata : TestValueProviderMetadata { } } diff --git a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ValueProviders/QueryStringValueProviderFactoryTest.cs b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ValueProviders/QueryStringValueProviderFactoryTest.cs index 304f49edd5..55132645a2 100644 --- a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ValueProviders/QueryStringValueProviderFactoryTest.cs +++ b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ValueProviders/QueryStringValueProviderFactoryTest.cs @@ -1,14 +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. +#if ASPNET50 using System; using System.Collections.Generic; using System.Globalization; using Microsoft.AspNet.Http; -#if ASPNET50 using Moq; -#endif using Xunit; +#endif namespace Microsoft.AspNet.Mvc.ModelBinding.Test { diff --git a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ValueProviders/ReadableStringCollectionValueProviderTests.cs b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ValueProviders/ReadableStringCollectionValueProviderTests.cs index 62c59abdec..1182441e27 100644 --- a/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ValueProviders/ReadableStringCollectionValueProviderTests.cs +++ b/test/Microsoft.AspNet.Mvc.ModelBinding.Test/ValueProviders/ReadableStringCollectionValueProviderTests.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. -using System; using System.Collections.Generic; using System.Globalization; using System.Linq; diff --git a/test/Microsoft.AspNet.Mvc.Razor.Host.Test/Directives/SetBaseTypeChunkMergerTest.cs b/test/Microsoft.AspNet.Mvc.Razor.Host.Test/Directives/SetBaseTypeChunkMergerTest.cs index 62a3dd5b0b..8bda2f406f 100644 --- a/test/Microsoft.AspNet.Mvc.Razor.Host.Test/Directives/SetBaseTypeChunkMergerTest.cs +++ b/test/Microsoft.AspNet.Mvc.Razor.Host.Test/Directives/SetBaseTypeChunkMergerTest.cs @@ -13,7 +13,7 @@ namespace Microsoft.AspNet.Mvc.Razor.Directives public void Visit_ThrowsIfThePassedInChunkIsNotASetBaseTypeChunk() { // Arrange - var expected = "Argument must be an instance of "+ + var expected = "Argument must be an instance of " + "'Microsoft.AspNet.Razor.Generator.Compiler.SetBaseTypeChunk'."; var merger = new SetBaseTypeChunkMerger("dynamic"); diff --git a/test/Microsoft.AspNet.Mvc.Razor.Host.Test/MvcTagHelperAttributeValueCodeRendererTest.cs b/test/Microsoft.AspNet.Mvc.Razor.Host.Test/MvcTagHelperAttributeValueCodeRendererTest.cs index 5086a9eed2..b01972df75 100644 --- a/test/Microsoft.AspNet.Mvc.Razor.Host.Test/MvcTagHelperAttributeValueCodeRendererTest.cs +++ b/test/Microsoft.AspNet.Mvc.Razor.Host.Test/MvcTagHelperAttributeValueCodeRendererTest.cs @@ -1,11 +1,9 @@ // 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. -using System.Reflection; using Microsoft.AspNet.Razor.Generator; using Microsoft.AspNet.Razor.Generator.Compiler.CSharp; using Microsoft.AspNet.Razor.TagHelpers; -using Moq; using Xunit; namespace Microsoft.AspNet.Mvc.Razor @@ -37,7 +35,8 @@ namespace Microsoft.AspNet.Mvc.Razor // Act renderer.RenderAttributeValue(attributeDescriptor, writer, context, - (codeWriter) => { + (codeWriter) => + { codeWriter.Write("MyValue"); }); diff --git a/test/Microsoft.AspNet.Mvc.Razor.Test/DefaultViewLocationCacheTest.cs b/test/Microsoft.AspNet.Mvc.Razor.Test/DefaultViewLocationCacheTest.cs index 4fa3d1d2da..2ada2a3da3 100644 --- a/test/Microsoft.AspNet.Mvc.Razor.Test/DefaultViewLocationCacheTest.cs +++ b/test/Microsoft.AspNet.Mvc.Razor.Test/DefaultViewLocationCacheTest.cs @@ -31,7 +31,7 @@ namespace Microsoft.AspNet.Mvc.Razor Values = values }; - yield return new [] { expanderContext }; + yield return new[] { expanderContext }; } } diff --git a/test/Microsoft.AspNet.Mvc.Razor.Test/RazorPageCreateTagHelperTest.cs b/test/Microsoft.AspNet.Mvc.Razor.Test/RazorPageCreateTagHelperTest.cs index 3ef689bf45..b87ac108b2 100644 --- a/test/Microsoft.AspNet.Mvc.Razor.Test/RazorPageCreateTagHelperTest.cs +++ b/test/Microsoft.AspNet.Mvc.Razor.Test/RazorPageCreateTagHelperTest.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using System.Globalization; using System.IO; using System.Threading.Tasks; using Microsoft.AspNet.Http; diff --git a/test/Microsoft.AspNet.Mvc.Razor.Test/RazorTextWriterTest.cs b/test/Microsoft.AspNet.Mvc.Razor.Test/RazorTextWriterTest.cs index c58dd6fd29..9fef54c481 100644 --- a/test/Microsoft.AspNet.Mvc.Razor.Test/RazorTextWriterTest.cs +++ b/test/Microsoft.AspNet.Mvc.Razor.Test/RazorTextWriterTest.cs @@ -244,7 +244,7 @@ namespace Microsoft.AspNet.Mvc.Razor.Test // Act target.Flush(); source.Write("Hello world"); - source.Write(new [] { 'a', 'b', 'c', 'd' }, 1, 2); + source.Write(new[] { 'a', 'b', 'c', 'd' }, 1, 2); source.CopyTo(target); // Assert @@ -277,7 +277,7 @@ abc"; public async Task CopyAsync_WritesContent_IfTargetTextWriterIsARazorTextWriterAndBuffering() { // Arrange - var source = new RazorTextWriter(TextWriter.Null,Encoding.UTF8); + var source = new RazorTextWriter(TextWriter.Null, Encoding.UTF8); var target = new RazorTextWriter(TextWriter.Null, Encoding.UTF8); // Act @@ -302,7 +302,7 @@ abc"; // Act await target.FlushAsync(); source.WriteLine("Hello from Asp.Net"); - await source.WriteAsync(new [] { 'x', 'y', 'z', 'u' }, 0, 3); + await source.WriteAsync(new[] { 'x', 'y', 'z', 'u' }, 0, 3); await source.CopyToAsync(target); // Assert diff --git a/test/Microsoft.AspNet.Mvc.TagHelpers.Test/OptionTagHelperTest.cs b/test/Microsoft.AspNet.Mvc.TagHelpers.Test/OptionTagHelperTest.cs index 00c31f95b0..24a06d3e8e 100644 --- a/test/Microsoft.AspNet.Mvc.TagHelpers.Test/OptionTagHelperTest.cs +++ b/test/Microsoft.AspNet.Mvc.TagHelpers.Test/OptionTagHelperTest.cs @@ -94,7 +94,7 @@ namespace Microsoft.AspNet.Mvc.TagHelpers // Original content, selected attribute, value attribute, selected values (to place in FormContext.FormData) // and expected output (concatenation of TagHelperOutput generations). Excludes non-null selected attribute, // null selected values, and empty selected values cases. - public static IEnumerable DoesNotUseGeneratorDataSet + public static IEnumerable DoesNotUseGeneratorDataSet { get { diff --git a/test/Microsoft.AspNet.Mvc.TagHelpers.Test/TagHelperOutputExtensionsTest.cs b/test/Microsoft.AspNet.Mvc.TagHelpers.Test/TagHelperOutputExtensionsTest.cs index 09930340b9..49dd211966 100644 --- a/test/Microsoft.AspNet.Mvc.TagHelpers.Test/TagHelperOutputExtensionsTest.cs +++ b/test/Microsoft.AspNet.Mvc.TagHelpers.Test/TagHelperOutputExtensionsTest.cs @@ -3,7 +3,6 @@ using System; using System.Collections.Generic; -using System.Linq; using Microsoft.AspNet.Mvc.Rendering; using Microsoft.AspNet.Razor.Runtime.TagHelpers; using Xunit; diff --git a/test/Microsoft.AspNet.Mvc.Test/MvcOptionSetupTest.cs b/test/Microsoft.AspNet.Mvc.Test/MvcOptionSetupTest.cs index 3d0d4a523d..714ecdcf17 100644 --- a/test/Microsoft.AspNet.Mvc.Test/MvcOptionSetupTest.cs +++ b/test/Microsoft.AspNet.Mvc.Test/MvcOptionSetupTest.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using System.Xml; using System.Xml.Linq; using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.AspNet.Mvc.Razor; diff --git a/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/ActionResults/InvalidModelStateResultTest.cs b/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/ActionResults/InvalidModelStateResultTest.cs index ed49124d5f..93ad48239b 100644 --- a/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/ActionResults/InvalidModelStateResultTest.cs +++ b/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/ActionResults/InvalidModelStateResultTest.cs @@ -6,11 +6,11 @@ using System.Collections.Generic; using System.IO; using System.Threading.Tasks; using Microsoft.AspNet.Mvc; +using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.AspNet.PipelineCore; using Microsoft.AspNet.Routing; using Moq; using Xunit; -using Microsoft.AspNet.Mvc.ModelBinding; namespace System.Web.Http { diff --git a/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/DefaultContentNegotiatorTest.cs b/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/DefaultContentNegotiatorTest.cs index d2539deeaa..4283e95c25 100644 --- a/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/DefaultContentNegotiatorTest.cs +++ b/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/DefaultContentNegotiatorTest.cs @@ -6,9 +6,9 @@ using System.Linq; using System.Net.Http.Formatting.Mocks; using System.Net.Http.Headers; using System.Text; +using Microsoft.TestCommon; using Newtonsoft.Json.Linq; using Xunit; -using Microsoft.TestCommon; namespace System.Net.Http.Formatting { diff --git a/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/HttpErrorTest.cs b/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/HttpErrorTest.cs index 74a25ead29..0ce21b0dc3 100644 --- a/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/HttpErrorTest.cs +++ b/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/HttpErrorTest.cs @@ -3,9 +3,9 @@ using System.Collections.Generic; using System.IO; using System.Net.Http.Formatting; +using Microsoft.AspNet.Mvc.ModelBinding; using Newtonsoft.Json.Linq; using Xunit; -using Microsoft.AspNet.Mvc.ModelBinding; namespace System.Web.Http.Dispatcher { diff --git a/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/HttpResponseExceptionTest.cs b/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/HttpResponseExceptionTest.cs index 6c2a68a779..916f19d815 100644 --- a/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/HttpResponseExceptionTest.cs +++ b/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/HttpResponseExceptionTest.cs @@ -21,8 +21,8 @@ namespace Microsoft.AspNet.Mvc.WebApiCompatShim // Assert Assert.Same(response, exception.Response); - Assert.Equal("Processing of the HTTP request resulted in an exception."+ - " Please see the HTTP response returned by the 'Response' "+ + Assert.Equal("Processing of the HTTP request resulted in an exception." + + " Please see the HTTP response returned by the 'Response' " + "property of this exception for details.", exception.Message); } @@ -36,8 +36,8 @@ namespace Microsoft.AspNet.Mvc.WebApiCompatShim // Assert Assert.Equal(HttpStatusCode.BadGateway, exception.Response.StatusCode); - Assert.Equal("Processing of the HTTP request resulted in an exception."+ - " Please see the HTTP response returned by the 'Response' "+ + Assert.Equal("Processing of the HTTP request resulted in an exception." + + " Please see the HTTP response returned by the 'Response' " + "property of this exception for details.", exception.Message); } diff --git a/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/OverloadActionConstraintTest.cs b/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/OverloadActionConstraintTest.cs index 1f520c3c36..3be2ad1b66 100644 --- a/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/OverloadActionConstraintTest.cs +++ b/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/OverloadActionConstraintTest.cs @@ -4,7 +4,6 @@ using System.Collections.Generic; using System.Web.Http; using Microsoft.AspNet.Http; -using Microsoft.AspNet.Mvc.ModelBinding; using Microsoft.AspNet.PipelineCore; using Microsoft.AspNet.Routing; using Xunit; diff --git a/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/TestUtils/MediaTypeAssert.cs b/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/TestUtils/MediaTypeAssert.cs index 1e414e57e1..4d3a746835 100644 --- a/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/TestUtils/MediaTypeAssert.cs +++ b/test/Microsoft.AspNet.Mvc.WebApiCompatShimTest/TestUtils/MediaTypeAssert.cs @@ -4,7 +4,6 @@ using System; using System.Net.Http.Headers; using Xunit; -using Microsoft.AspNet.Mvc; namespace Microsoft.TestCommon { diff --git a/test/WebSites/ActivatorWebSite/Components/ValueComponent.cs b/test/WebSites/ActivatorWebSite/Components/ValueComponent.cs index 0aa2c55810..24ed43c59e 100644 --- a/test/WebSites/ActivatorWebSite/Components/ValueComponent.cs +++ b/test/WebSites/ActivatorWebSite/Components/ValueComponent.cs @@ -5,7 +5,7 @@ using Microsoft.AspNet.Mvc; namespace ActivatorWebSite { - [ViewComponent(Name ="Value")] + [ViewComponent(Name = "Value")] public class ValueComponent : ViewComponent { [Activate] diff --git a/test/WebSites/AntiForgeryWebSite/Controllers/AccountController.cs b/test/WebSites/AntiForgeryWebSite/Controllers/AccountController.cs index 73e52877be..701b421a39 100644 --- a/test/WebSites/AntiForgeryWebSite/Controllers/AccountController.cs +++ b/test/WebSites/AntiForgeryWebSite/Controllers/AccountController.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. -using System.Threading.Tasks; using Microsoft.AspNet.Mvc; namespace AntiForgeryWebSite diff --git a/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerHttpMethodController.cs b/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerHttpMethodController.cs index 9f3230e8fb..58ab40f6ff 100644 --- a/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerHttpMethodController.cs +++ b/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerHttpMethodController.cs @@ -1,5 +1,4 @@ using Microsoft.AspNet.Mvc; -using System; namespace ApiExplorer { diff --git a/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseContentTypeController.cs b/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseContentTypeController.cs index 60c36bbdd6..b1d6771c30 100644 --- a/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseContentTypeController.cs +++ b/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseContentTypeController.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using Microsoft.AspNet.Mvc; -using System.Threading.Tasks; namespace ApiExplorer { diff --git a/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseContentTypeOverrideOnActionController.cs b/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseContentTypeOverrideOnActionController.cs index d86b429cd6..6e6bd35728 100644 --- a/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseContentTypeOverrideOnActionController.cs +++ b/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseContentTypeOverrideOnActionController.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using Microsoft.AspNet.Mvc; -using System.Threading.Tasks; namespace ApiExplorer { diff --git a/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseTypeOverrideOnActionController.cs b/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseTypeOverrideOnActionController.cs index 47bc73506f..3b7c178cfe 100644 --- a/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseTypeOverrideOnActionController.cs +++ b/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseTypeOverrideOnActionController.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using Microsoft.AspNet.Mvc; -using System.Threading.Tasks; namespace ApiExplorer { diff --git a/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseTypeWithAttributeController.cs b/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseTypeWithAttributeController.cs index 24a54a0942..59589cb578 100644 --- a/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseTypeWithAttributeController.cs +++ b/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseTypeWithAttributeController.cs @@ -1,8 +1,8 @@ // 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. -using Microsoft.AspNet.Mvc; using System.Threading.Tasks; +using Microsoft.AspNet.Mvc; namespace ApiExplorer { diff --git a/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseTypeWithoutAttributeController.cs b/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseTypeWithoutAttributeController.cs index acc6df04f3..4bbd53da60 100644 --- a/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseTypeWithoutAttributeController.cs +++ b/test/WebSites/ApiExplorerWebSite/Controllers/ApiExplorerResponseTypeWithoutAttributeController.cs @@ -1,8 +1,8 @@ // 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. -using Microsoft.AspNet.Mvc; using System.Threading.Tasks; +using Microsoft.AspNet.Mvc; namespace ApiExplorer { diff --git a/test/WebSites/AutofacWebSite/Startup.cs b/test/WebSites/AutofacWebSite/Startup.cs index 48f6af4464..7d0a061a33 100644 --- a/test/WebSites/AutofacWebSite/Startup.cs +++ b/test/WebSites/AutofacWebSite/Startup.cs @@ -13,12 +13,13 @@ namespace AutofacWebSite { var configuration = app.GetTestConfiguration(); - app.UseServices(services => { + app.UseServices(services => + { services.AddMvc(configuration); services.AddTransient(); var builder = new ContainerBuilder(); - AutofacRegistration.Populate(builder, + AutofacRegistration.Populate(builder, services); var container = builder.Build(); diff --git a/test/WebSites/BasicWebSite/Controllers/HomeController.cs b/test/WebSites/BasicWebSite/Controllers/HomeController.cs index 13464b6ec2..53b082bbcf 100644 --- a/test/WebSites/BasicWebSite/Controllers/HomeController.cs +++ b/test/WebSites/BasicWebSite/Controllers/HomeController.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System.Threading.Tasks; -using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc; namespace BasicWebSite.Controllers diff --git a/test/WebSites/BasicWebSite/Controllers/MonitorController.cs b/test/WebSites/BasicWebSite/Controllers/MonitorController.cs index 7e6e7c2f02..512891f777 100644 --- a/test/WebSites/BasicWebSite/Controllers/MonitorController.cs +++ b/test/WebSites/BasicWebSite/Controllers/MonitorController.cs @@ -9,7 +9,7 @@ namespace BasicWebSite private readonly ActionDescriptorCreationCounter _counterService; public MonitorController(INestedProvider counterService) - { + { _counterService = (ActionDescriptorCreationCounter)counterService; } diff --git a/test/WebSites/BasicWebSite/Models/Person.cs b/test/WebSites/BasicWebSite/Models/Person.cs index b86f0bd513..7599131700 100644 --- a/test/WebSites/BasicWebSite/Models/Person.cs +++ b/test/WebSites/BasicWebSite/Models/Person.cs @@ -1,6 +1,4 @@ -using System; - -namespace BasicWebSite.Models +namespace BasicWebSite.Models { public class Person { diff --git a/test/WebSites/BasicWebSite/Startup.cs b/test/WebSites/BasicWebSite/Startup.cs index 955d4378ec..0078e2f275 100644 --- a/test/WebSites/BasicWebSite/Startup.cs +++ b/test/WebSites/BasicWebSite/Startup.cs @@ -1,7 +1,6 @@ using Microsoft.AspNet.Builder; using Microsoft.AspNet.Mvc; using Microsoft.AspNet.Routing; -using Microsoft.Framework.ConfigurationModel; using Microsoft.Framework.DependencyInjection; namespace BasicWebSite diff --git a/test/WebSites/ConnegWebSite/Controllers/FallbackOnTypeBasedMatchController.cs b/test/WebSites/ConnegWebSite/Controllers/FallbackOnTypeBasedMatchController.cs index f21bc7b610..d49d693d53 100644 --- a/test/WebSites/ConnegWebSite/Controllers/FallbackOnTypeBasedMatchController.cs +++ b/test/WebSites/ConnegWebSite/Controllers/FallbackOnTypeBasedMatchController.cs @@ -1,14 +1,7 @@ // 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. -using System; -using System.Collections.Generic; -using System.IO; -using System.Text; -using System.Threading.Tasks; -using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc; -using Microsoft.AspNet.Mvc.HeaderValueAbstractions; using Microsoft.Framework.DependencyInjection; namespace ConnegWebsite { diff --git a/test/WebSites/ConnegWebSite/Controllers/NoContentDoNotTreatNullValueAsNoContentController.cs b/test/WebSites/ConnegWebSite/Controllers/NoContentDoNotTreatNullValueAsNoContentController.cs index a218236535..ed7bd468e9 100644 --- a/test/WebSites/ConnegWebSite/Controllers/NoContentDoNotTreatNullValueAsNoContentController.cs +++ b/test/WebSites/ConnegWebSite/Controllers/NoContentDoNotTreatNullValueAsNoContentController.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. -using System.Linq; using System.Threading.Tasks; using Microsoft.AspNet.Mvc; diff --git a/test/WebSites/ConnegWebSite/Controllers/NormalController.cs b/test/WebSites/ConnegWebSite/Controllers/NormalController.cs index 69931916cd..0979c844b0 100644 --- a/test/WebSites/ConnegWebSite/Controllers/NormalController.cs +++ b/test/WebSites/ConnegWebSite/Controllers/NormalController.cs @@ -2,9 +2,7 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using Microsoft.AspNet.Mvc; -using Microsoft.AspNet.Mvc.HeaderValueAbstractions; using Newtonsoft.Json; -using Newtonsoft.Json.Serialization; namespace ConnegWebsite { diff --git a/test/WebSites/ConnegWebSite/Controllers/ProducesContentBaseController.cs b/test/WebSites/ConnegWebSite/Controllers/ProducesContentBaseController.cs index f6cfa2db11..877666026a 100644 --- a/test/WebSites/ConnegWebSite/Controllers/ProducesContentBaseController.cs +++ b/test/WebSites/ConnegWebSite/Controllers/ProducesContentBaseController.cs @@ -11,7 +11,7 @@ namespace ConnegWebsite public override void OnActionExecuted(ActionExecutedContext context) { var result = context.Result as ObjectResult; - if(result != null) + if (result != null) { result.Formatters.Add(new PlainTextFormatter()); result.Formatters.Add(new CustomFormatter("application/custom_ProducesContentBaseController")); diff --git a/test/WebSites/ConnegWebSite/CustomFormatter.cs b/test/WebSites/ConnegWebSite/CustomFormatter.cs index e44168fc11..b33cb21742 100644 --- a/test/WebSites/ConnegWebSite/CustomFormatter.cs +++ b/test/WebSites/ConnegWebSite/CustomFormatter.cs @@ -1,9 +1,7 @@ // 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. -using System; using System.Text; -using System.Threading; using System.Threading.Tasks; using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc; diff --git a/test/WebSites/ConnegWebSite/Models/User.cs b/test/WebSites/ConnegWebSite/Models/User.cs index 863985f8e3..cb32ddbcfc 100644 --- a/test/WebSites/ConnegWebSite/Models/User.cs +++ b/test/WebSites/ConnegWebSite/Models/User.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. -using System.Collections.Generic; using System.ComponentModel.DataAnnotations; namespace ConnegWebsite diff --git a/test/WebSites/ConnegWebSite/PlainTextFormatter.cs b/test/WebSites/ConnegWebSite/PlainTextFormatter.cs index 4270086a7e..c812bdb979 100644 --- a/test/WebSites/ConnegWebSite/PlainTextFormatter.cs +++ b/test/WebSites/ConnegWebSite/PlainTextFormatter.cs @@ -1,9 +1,7 @@ // 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. -using System; using System.Text; -using System.Threading; using System.Threading.Tasks; using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc; diff --git a/test/WebSites/FilesWebSite/SendFileMiddleware.cs b/test/WebSites/FilesWebSite/SendFileMiddleware.cs index 62e6beb295..596eb250ba 100644 --- a/test/WebSites/FilesWebSite/SendFileMiddleware.cs +++ b/test/WebSites/FilesWebSite/SendFileMiddleware.cs @@ -4,10 +4,10 @@ using System.IO; using System.Threading; using System.Threading.Tasks; -using Microsoft.Framework.Runtime; using Microsoft.AspNet.Builder; using Microsoft.AspNet.Http; using Microsoft.AspNet.HttpFeature; +using Microsoft.Framework.Runtime; namespace FilesWebSite { diff --git a/test/WebSites/FiltersWebSite/Filters/AddHeaderAttribute.cs b/test/WebSites/FiltersWebSite/Filters/AddHeaderAttribute.cs index 8032f57565..466b0a927a 100644 --- a/test/WebSites/FiltersWebSite/Filters/AddHeaderAttribute.cs +++ b/test/WebSites/FiltersWebSite/Filters/AddHeaderAttribute.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. -using System.Text; using Microsoft.AspNet.Mvc; namespace FiltersWebSite diff --git a/test/WebSites/FiltersWebSite/Filters/AuthorizeUserAttribute.cs b/test/WebSites/FiltersWebSite/Filters/AuthorizeUserAttribute.cs index 3eaccefc5f..f8fb7bf7a0 100644 --- a/test/WebSites/FiltersWebSite/Filters/AuthorizeUserAttribute.cs +++ b/test/WebSites/FiltersWebSite/Filters/AuthorizeUserAttribute.cs @@ -1,8 +1,8 @@ // 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. -using Microsoft.AspNet.Mvc; using System.Security.Claims; +using Microsoft.AspNet.Mvc; namespace FiltersWebSite { diff --git a/test/WebSites/FiltersWebSite/Filters/GlobalActionFilter.cs b/test/WebSites/FiltersWebSite/Filters/GlobalActionFilter.cs index 37d5fc3737..97110e893a 100644 --- a/test/WebSites/FiltersWebSite/Filters/GlobalActionFilter.cs +++ b/test/WebSites/FiltersWebSite/Filters/GlobalActionFilter.cs @@ -24,7 +24,7 @@ namespace FiltersWebSite public void OnActionExecuting(ActionExecutingContext context) { - if(context.ActionDescriptor.DisplayName == "FiltersWebSite.ActionFilterController.GetHelloWorld") + if (context.ActionDescriptor.DisplayName == "FiltersWebSite.ActionFilterController.GetHelloWorld") { (context.ActionArguments["fromGlobalActionFilter"] as List) .Add(Helpers.GetContentResult(null, "GlobalActionFilter.OnActionExecuting")); diff --git a/test/WebSites/FiltersWebSite/Filters/HandleExceptionActionFilter.cs b/test/WebSites/FiltersWebSite/Filters/HandleExceptionActionFilter.cs index 6bc0e2ce34..520ef9ba9f 100644 --- a/test/WebSites/FiltersWebSite/Filters/HandleExceptionActionFilter.cs +++ b/test/WebSites/FiltersWebSite/Filters/HandleExceptionActionFilter.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. -using System; using Microsoft.AspNet.Mvc; namespace FiltersWebSite diff --git a/test/WebSites/FormatterWebSite/Controllers/InputFormatterController.cs b/test/WebSites/FormatterWebSite/Controllers/InputFormatterController.cs index 11f80e5fa8..e84973e242 100644 --- a/test/WebSites/FormatterWebSite/Controllers/InputFormatterController.cs +++ b/test/WebSites/FormatterWebSite/Controllers/InputFormatterController.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. -using System.Collections.Generic; using System.Linq; using Microsoft.AspNet.Mvc; @@ -18,12 +17,12 @@ namespace FormatterWebSite.Controllers if (parameterBindingErrors.Count != 0) { return new ErrorInfo - { - ActionName = "ActionHandlesError", - ParameterName = "dummy", - Errors = parameterBindingErrors.Select(x => x.ErrorMessage).ToList(), - Source = "action" - }; + { + ActionName = "ActionHandlesError", + ParameterName = "dummy", + Errors = parameterBindingErrors.Select(x => x.ErrorMessage).ToList(), + Source = "action" + }; } } diff --git a/test/WebSites/FormatterWebSite/Controllers/JsonFormatterController.cs b/test/WebSites/FormatterWebSite/Controllers/JsonFormatterController.cs index bd01d516d6..8359af77e3 100644 --- a/test/WebSites/FormatterWebSite/Controllers/JsonFormatterController.cs +++ b/test/WebSites/FormatterWebSite/Controllers/JsonFormatterController.cs @@ -1,5 +1,4 @@ -using System; -using Microsoft.AspNet.Mvc; +using Microsoft.AspNet.Mvc; using Newtonsoft.Json; namespace FormatterWebSite.Controllers diff --git a/test/WebSites/FormatterWebSite/Controllers/ValidationController.cs b/test/WebSites/FormatterWebSite/Controllers/ValidationController.cs index 1ad8e0e0e2..db3ffabd21 100644 --- a/test/WebSites/FormatterWebSite/Controllers/ValidationController.cs +++ b/test/WebSites/FormatterWebSite/Controllers/ValidationController.cs @@ -51,7 +51,7 @@ namespace FormatterWebSite } else { - return ModelState["Name"].Errors[0].ErrorMessage; + return ModelState["Name"].Errors[0].ErrorMessage; } } } diff --git a/test/WebSites/FormatterWebSite/Models/Developer.cs b/test/WebSites/FormatterWebSite/Models/Developer.cs index c26dfce70d..734cbc5dcd 100644 --- a/test/WebSites/FormatterWebSite/Models/Developer.cs +++ b/test/WebSites/FormatterWebSite/Models/Developer.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. -using System; using System.ComponentModel.DataAnnotations; namespace FormatterWebSite diff --git a/test/WebSites/InlineConstraintsWebSite/DefaultCommandLineArgumentBuilder.cs b/test/WebSites/InlineConstraintsWebSite/DefaultCommandLineArgumentBuilder.cs index 5d1badf786..32efeaa454 100644 --- a/test/WebSites/InlineConstraintsWebSite/DefaultCommandLineArgumentBuilder.cs +++ b/test/WebSites/InlineConstraintsWebSite/DefaultCommandLineArgumentBuilder.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. -using System; using System.Collections.Generic; namespace InlineConstraints diff --git a/test/WebSites/ModelBindingWebSite/Model/Employee.cs b/test/WebSites/ModelBindingWebSite/Model/Employee.cs index 7a07710a64..8da623a504 100644 --- a/test/WebSites/ModelBindingWebSite/Model/Employee.cs +++ b/test/WebSites/ModelBindingWebSite/Model/Employee.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. -using Microsoft.AspNet.Mvc; namespace ModelBindingWebSite { diff --git a/test/WebSites/ModelBindingWebSite/Model/EmployeeWithBinderMetadata.cs b/test/WebSites/ModelBindingWebSite/Model/EmployeeWithBinderMetadata.cs index b1674fab0d..d56c1f6be8 100644 --- a/test/WebSites/ModelBindingWebSite/Model/EmployeeWithBinderMetadata.cs +++ b/test/WebSites/ModelBindingWebSite/Model/EmployeeWithBinderMetadata.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. -using Microsoft.AspNet.Mvc; namespace ModelBindingWebSite { diff --git a/test/WebSites/ModelBindingWebSite/Model/ExternalType.cs b/test/WebSites/ModelBindingWebSite/Model/ExternalType.cs index adc3434bc8..3762870cfe 100644 --- a/test/WebSites/ModelBindingWebSite/Model/ExternalType.cs +++ b/test/WebSites/ModelBindingWebSite/Model/ExternalType.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. -using Microsoft.AspNet.Mvc; namespace ModelBindingWebSite { diff --git a/test/WebSites/ModelBindingWebSite/Model/Person.cs b/test/WebSites/ModelBindingWebSite/Model/Person.cs index cfbeb02dcc..667e7402e2 100644 --- a/test/WebSites/ModelBindingWebSite/Model/Person.cs +++ b/test/WebSites/ModelBindingWebSite/Model/Person.cs @@ -11,7 +11,7 @@ namespace ModelBindingWebSite public int Age { get; set; } - public Person Parent { get; set; } + public Person Parent { get; set; } public List Dependents { get; set; } diff --git a/test/WebSites/ModelBindingWebSite/Startup.cs b/test/WebSites/ModelBindingWebSite/Startup.cs index 79f61f9889..61940ae87e 100644 --- a/test/WebSites/ModelBindingWebSite/Startup.cs +++ b/test/WebSites/ModelBindingWebSite/Startup.cs @@ -1,8 +1,8 @@ // 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. -using Microsoft.AspNet.Mvc; using Microsoft.AspNet.Builder; +using Microsoft.AspNet.Mvc; using Microsoft.AspNet.Routing; using Microsoft.Framework.DependencyInjection; diff --git a/test/WebSites/PrecompilationWebSite/Startup.cs b/test/WebSites/PrecompilationWebSite/Startup.cs index 0d99e31a5a..eb9a98053d 100644 --- a/test/WebSites/PrecompilationWebSite/Startup.cs +++ b/test/WebSites/PrecompilationWebSite/Startup.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using Microsoft.AspNet.Builder; -using Microsoft.AspNet.Routing; using Microsoft.Framework.DependencyInjection; namespace PrecompilationWebSite diff --git a/test/WebSites/RazorInstrumentationWebsite/HomeController.cs b/test/WebSites/RazorInstrumentationWebsite/HomeController.cs index a945842683..e005904e9c 100644 --- a/test/WebSites/RazorInstrumentationWebsite/HomeController.cs +++ b/test/WebSites/RazorInstrumentationWebsite/HomeController.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. -using System; using Microsoft.AspNet.Mvc; namespace RazorInstrumentationWebSite diff --git a/test/WebSites/RazorWebSite/Controllers/DirectivesController.cs b/test/WebSites/RazorWebSite/Controllers/DirectivesController.cs index d8371144d0..09327b37ad 100644 --- a/test/WebSites/RazorWebSite/Controllers/DirectivesController.cs +++ b/test/WebSites/RazorWebSite/Controllers/DirectivesController.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. -using System.Diagnostics; using Microsoft.AspNet.Mvc; namespace RazorWebSite diff --git a/test/WebSites/RazorWebSite/Controllers/PartialViewEngineController.cs b/test/WebSites/RazorWebSite/Controllers/PartialViewEngineController.cs index 89f222ea46..992b67ca4a 100644 --- a/test/WebSites/RazorWebSite/Controllers/PartialViewEngineController.cs +++ b/test/WebSites/RazorWebSite/Controllers/PartialViewEngineController.cs @@ -38,7 +38,7 @@ namespace RazorWebSite.Controllers var model = new Person { Name = "my name is judge", - Address = new Address { ZipCode = "98052"} + Address = new Address { ZipCode = "98052" } }; return PartialView(model); } diff --git a/test/WebSites/RazorWebSite/Controllers/TemplateExpander.cs b/test/WebSites/RazorWebSite/Controllers/TemplateExpander.cs index 5695bb9bd9..267e7998b3 100644 --- a/test/WebSites/RazorWebSite/Controllers/TemplateExpander.cs +++ b/test/WebSites/RazorWebSite/Controllers/TemplateExpander.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. -using System; using Microsoft.AspNet.Mvc; namespace RazorWebSite.Controllers diff --git a/test/WebSites/RazorWebSite/Models/Address.cs b/test/WebSites/RazorWebSite/Models/Address.cs index ee7332a878..1f68fe57af 100644 --- a/test/WebSites/RazorWebSite/Models/Address.cs +++ b/test/WebSites/RazorWebSite/Models/Address.cs @@ -5,6 +5,6 @@ namespace RazorWebSite { public class Address { - public string ZipCode { get; set; } + public string ZipCode { get; set; } } } \ No newline at end of file diff --git a/test/WebSites/RazorWebSite/MyBasePage.cs b/test/WebSites/RazorWebSite/MyBasePage.cs index 07039b6caa..cd8451a374 100644 --- a/test/WebSites/RazorWebSite/MyBasePage.cs +++ b/test/WebSites/RazorWebSite/MyBasePage.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. -using System.IO; using Microsoft.AspNet.Mvc.Razor; namespace RazorWebSite diff --git a/test/WebSites/RoutingWebSite/Controllers/BanksController.cs b/test/WebSites/RoutingWebSite/Controllers/BanksController.cs index d41e418abb..925aeda74d 100644 --- a/test/WebSites/RoutingWebSite/Controllers/BanksController.cs +++ b/test/WebSites/RoutingWebSite/Controllers/BanksController.cs @@ -10,9 +10,9 @@ namespace RoutingWebSite private readonly TestResponseGenerator _generator; public BanksController(TestResponseGenerator generator) - { + { _generator = generator; - } + } [HttpGet("Banks/[action]/{id}")] [HttpGet("Bank/[action]/{id}")] @@ -23,9 +23,9 @@ namespace RoutingWebSite Url.RouteUrl(new { })); } - [AcceptVerbs("PUT", Route ="Bank")] + [AcceptVerbs("PUT", Route = "Bank")] [HttpPatch("Bank")] - [AcceptVerbs("PUT", Route ="Bank/Update")] + [AcceptVerbs("PUT", Route = "Bank/Update")] [HttpPatch("Bank/Update")] public ActionResult UpdateBank() { diff --git a/test/WebSites/RoutingWebSite/Controllers/DuplicateController.cs b/test/WebSites/RoutingWebSite/Controllers/DuplicateController.cs index d0e5ded0e2..85e1a3d4f3 100644 --- a/test/WebSites/RoutingWebSite/Controllers/DuplicateController.cs +++ b/test/WebSites/RoutingWebSite/Controllers/DuplicateController.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using Microsoft.AspNet.Mvc; -using System; namespace RoutingWebSite { diff --git a/test/WebSites/RoutingWebSite/Controllers/EmployeeController.cs b/test/WebSites/RoutingWebSite/Controllers/EmployeeController.cs index 3385c118dd..3857096cda 100644 --- a/test/WebSites/RoutingWebSite/Controllers/EmployeeController.cs +++ b/test/WebSites/RoutingWebSite/Controllers/EmployeeController.cs @@ -1,5 +1,4 @@ -using System; -using Microsoft.AspNet.Mvc; +using Microsoft.AspNet.Mvc; namespace RoutingWebSite { diff --git a/test/WebSites/RoutingWebSite/Controllers/MapsController.cs b/test/WebSites/RoutingWebSite/Controllers/MapsController.cs index 0a44ba2374..57c8e16a2b 100644 --- a/test/WebSites/RoutingWebSite/Controllers/MapsController.cs +++ b/test/WebSites/RoutingWebSite/Controllers/MapsController.cs @@ -1,5 +1,4 @@ using Microsoft.AspNet.Mvc; -using System; namespace RoutingWebSite { @@ -10,9 +9,9 @@ namespace RoutingWebSite private readonly TestResponseGenerator _generator; public MapsController(TestResponseGenerator generator) - { + { _generator = generator; - } + } [HttpGet] public ActionResult Get() diff --git a/test/WebSites/RoutingWebSite/Controllers/StoreController.cs b/test/WebSites/RoutingWebSite/Controllers/StoreController.cs index 1e12fdaee1..f0ebd372ee 100644 --- a/test/WebSites/RoutingWebSite/Controllers/StoreController.cs +++ b/test/WebSites/RoutingWebSite/Controllers/StoreController.cs @@ -17,9 +17,9 @@ namespace RoutingWebSite [HttpGet("Store/Shop/Products")] public IActionResult ListProducts() - { + { return _generator.Generate("/Store/Shop/Products"); - } + } // Intentionally designed to conflict with HomeController#About. [HttpGet("Home/About")] diff --git a/test/WebSites/RoutingWebSite/Controllers/TeamController.cs b/test/WebSites/RoutingWebSite/Controllers/TeamController.cs index 85989830c8..558c401d47 100644 --- a/test/WebSites/RoutingWebSite/Controllers/TeamController.cs +++ b/test/WebSites/RoutingWebSite/Controllers/TeamController.cs @@ -1,5 +1,4 @@ using Microsoft.AspNet.Mvc; -using System; namespace RoutingWebSite { @@ -40,7 +39,7 @@ namespace RoutingWebSite [HttpGet("/Club/{clubId?}")] public ActionResult GetClub() { - return Content(Url.Action(),"text/plain"); + return Content(Url.Action(), "text/plain"); } [HttpGet("/Organization/{clubId?}", Order = 1)] diff --git a/test/WebSites/RoutingWebSite/HttpMergeAttribute.cs b/test/WebSites/RoutingWebSite/HttpMergeAttribute.cs index d538dd4898..e7dab076fb 100644 --- a/test/WebSites/RoutingWebSite/HttpMergeAttribute.cs +++ b/test/WebSites/RoutingWebSite/HttpMergeAttribute.cs @@ -5,7 +5,6 @@ using System; using System.Collections.Generic; using Microsoft.AspNet.Mvc; using Microsoft.AspNet.Mvc.Routing; -using Microsoft.AspNet.Routing; namespace RoutingWebSite { diff --git a/test/WebSites/TagHelpersWebSite/TagHelpers/ATagHelper.cs b/test/WebSites/TagHelpersWebSite/TagHelpers/ATagHelper.cs index 13f807bbd1..65a0afb35a 100644 --- a/test/WebSites/TagHelpersWebSite/TagHelpers/ATagHelper.cs +++ b/test/WebSites/TagHelpersWebSite/TagHelpers/ATagHelper.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. -using System; using System.Linq; using Microsoft.AspNet.Mvc; using Microsoft.AspNet.Razor.Runtime.TagHelpers; diff --git a/test/WebSites/TagHelpersWebSite/TagHelpers/PrettyTagHelper.cs b/test/WebSites/TagHelpersWebSite/TagHelpers/PrettyTagHelper.cs index b521b8d2d4..c2076e445c 100644 --- a/test/WebSites/TagHelpersWebSite/TagHelpers/PrettyTagHelper.cs +++ b/test/WebSites/TagHelpersWebSite/TagHelpers/PrettyTagHelper.cs @@ -4,7 +4,6 @@ using System; using System.Collections.Generic; using Microsoft.AspNet.Mvc; -using Microsoft.AspNet.Mvc.Rendering; using Microsoft.AspNet.Razor.Runtime.TagHelpers; namespace TagHelpersWebSite.TagHelpers diff --git a/test/WebSites/TagHelpersWebSite/TagHelpers/TagCloudViewComponentTagHelper.cs b/test/WebSites/TagHelpersWebSite/TagHelpers/TagCloudViewComponentTagHelper.cs index 20fdd79662..0cf0de6cf7 100644 --- a/test/WebSites/TagHelpersWebSite/TagHelpers/TagCloudViewComponentTagHelper.cs +++ b/test/WebSites/TagHelpersWebSite/TagHelpers/TagCloudViewComponentTagHelper.cs @@ -7,7 +7,6 @@ using System.Linq; using System.Reflection; using System.Threading.Tasks; using Microsoft.AspNet.Mvc; -using Microsoft.AspNet.Mvc.Rendering; using Microsoft.AspNet.Razor.Runtime.TagHelpers; using Microsoft.AspNet.Razor.TagHelpers; diff --git a/test/WebSites/UrlHelperWebSite/AppOptions.cs b/test/WebSites/UrlHelperWebSite/AppOptions.cs index 62e6179f75..f6e44b19e8 100644 --- a/test/WebSites/UrlHelperWebSite/AppOptions.cs +++ b/test/WebSites/UrlHelperWebSite/AppOptions.cs @@ -1,6 +1,4 @@ -using System; - -namespace UrlHelperWebSite +namespace UrlHelperWebSite { public class AppOptions { diff --git a/test/WebSites/UrlHelperWebSite/Controllers/SimplePocoController.cs b/test/WebSites/UrlHelperWebSite/Controllers/SimplePocoController.cs index e3dedded24..276715439b 100644 --- a/test/WebSites/UrlHelperWebSite/Controllers/SimplePocoController.cs +++ b/test/WebSites/UrlHelperWebSite/Controllers/SimplePocoController.cs @@ -1,5 +1,4 @@ -using System; -using Microsoft.AspNet.Mvc; +using Microsoft.AspNet.Mvc; namespace UrlHelperWebSite.Controllers { diff --git a/test/WebSites/UrlHelperWebSite/CustomUrlHelper.cs b/test/WebSites/UrlHelperWebSite/CustomUrlHelper.cs index c0155e201b..c0ea23970a 100644 --- a/test/WebSites/UrlHelperWebSite/CustomUrlHelper.cs +++ b/test/WebSites/UrlHelperWebSite/CustomUrlHelper.cs @@ -1,5 +1,4 @@ using System; -using System.Collections.Generic; using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc; using Microsoft.Framework.DependencyInjection; diff --git a/test/WebSites/UrlHelperWebSite/Startup.cs b/test/WebSites/UrlHelperWebSite/Startup.cs index bc55f639dc..1d09623cf1 100644 --- a/test/WebSites/UrlHelperWebSite/Startup.cs +++ b/test/WebSites/UrlHelperWebSite/Startup.cs @@ -1,8 +1,6 @@ -using System; -using Microsoft.AspNet.Builder; +using Microsoft.AspNet.Builder; using Microsoft.AspNet.Mvc; using Microsoft.AspNet.Routing; -using Microsoft.Framework.ConfigurationModel; using Microsoft.Framework.DependencyInjection; namespace UrlHelperWebSite diff --git a/test/WebSites/VersioningWebSite/Controllers/VouchersController.cs b/test/WebSites/VersioningWebSite/Controllers/VouchersController.cs index 73b2c75d0d..385edd454a 100644 --- a/test/WebSites/VersioningWebSite/Controllers/VouchersController.cs +++ b/test/WebSites/VersioningWebSite/Controllers/VouchersController.cs @@ -1,5 +1,4 @@ using Microsoft.AspNet.Mvc; -using System; namespace VersioningWebSite { diff --git a/test/WebSites/VersioningWebSite/VersionRangeValidator.cs b/test/WebSites/VersioningWebSite/VersionRangeValidator.cs index 954dd9ab5c..41c3b4c63b 100644 --- a/test/WebSites/VersioningWebSite/VersionRangeValidator.cs +++ b/test/WebSites/VersioningWebSite/VersionRangeValidator.cs @@ -3,7 +3,6 @@ using Microsoft.AspNet.Http; using Microsoft.AspNet.Mvc; -using Microsoft.AspNet.Routing; namespace VersioningWebSite { diff --git a/test/WebSites/VersioningWebSite/VersionRoute.cs b/test/WebSites/VersioningWebSite/VersionRoute.cs index 959d3e7589..117072cdde 100644 --- a/test/WebSites/VersioningWebSite/VersionRoute.cs +++ b/test/WebSites/VersioningWebSite/VersionRoute.cs @@ -2,8 +2,8 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using Microsoft.AspNet.Mvc; using System.Text.RegularExpressions; +using Microsoft.AspNet.Mvc; namespace VersioningWebSite { diff --git a/test/WebSites/WebApiCompatShimWebSite/Controllers/ActionResults/ActionResultController.cs b/test/WebSites/WebApiCompatShimWebSite/Controllers/ActionResults/ActionResultController.cs index cfdd166691..9fbf040776 100644 --- a/test/WebSites/WebApiCompatShimWebSite/Controllers/ActionResults/ActionResultController.cs +++ b/test/WebSites/WebApiCompatShimWebSite/Controllers/ActionResults/ActionResultController.cs @@ -2,15 +2,12 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using System.Net.Http; -using System.Threading.Tasks; -using System.Web.Http; -using Microsoft.AspNet.Http; -using Microsoft.AspNet.Mvc; using System.Net; -using System.Net.Http.Formatting; -using Newtonsoft.Json; +using System.Net.Http; using System.Text; +using System.Web.Http; +using Microsoft.AspNet.Mvc; +using Newtonsoft.Json; namespace WebApiCompatShimWebSite { diff --git a/test/WebSites/WebApiCompatShimWebSite/Controllers/ActionSelection/Legacy/EnumParameterOverloadsController.cs b/test/WebSites/WebApiCompatShimWebSite/Controllers/ActionSelection/Legacy/EnumParameterOverloadsController.cs index 8ffcc07054..c98747435e 100644 --- a/test/WebSites/WebApiCompatShimWebSite/Controllers/ActionSelection/Legacy/EnumParameterOverloadsController.cs +++ b/test/WebSites/WebApiCompatShimWebSite/Controllers/ActionSelection/Legacy/EnumParameterOverloadsController.cs @@ -4,7 +4,6 @@ using System.Collections.Generic; using System.Diagnostics; using System.Web.Http; -using Microsoft.AspNet.Mvc.WebApiCompatShim; namespace WebApiCompatShimWebSite { diff --git a/test/WebSites/WebApiCompatShimWebSite/Controllers/ActionSelection/Legacy/ParameterAttributeController.cs b/test/WebSites/WebApiCompatShimWebSite/Controllers/ActionSelection/Legacy/ParameterAttributeController.cs index 22b6834a82..ddb151cc8e 100644 --- a/test/WebSites/WebApiCompatShimWebSite/Controllers/ActionSelection/Legacy/ParameterAttributeController.cs +++ b/test/WebSites/WebApiCompatShimWebSite/Controllers/ActionSelection/Legacy/ParameterAttributeController.cs @@ -4,7 +4,6 @@ using System.Collections.Generic; using System.Web.Http; using Microsoft.AspNet.Mvc; -using Microsoft.AspNet.Mvc.WebApiCompatShim; namespace WebApiCompatShimWebSite { diff --git a/test/WebSites/WebApiCompatShimWebSite/Controllers/HttpResponseExceptionController.cs b/test/WebSites/WebApiCompatShimWebSite/Controllers/HttpResponseExceptionController.cs index 946c8a068c..d14b1ee260 100644 --- a/test/WebSites/WebApiCompatShimWebSite/Controllers/HttpResponseExceptionController.cs +++ b/test/WebSites/WebApiCompatShimWebSite/Controllers/HttpResponseExceptionController.cs @@ -5,7 +5,6 @@ using System.Net; using System.Net.Http; using System.Web.Http; using Microsoft.AspNet.Mvc; -using Microsoft.AspNet.Mvc.WebApiCompatShim; namespace WebApiCompatShimWebSite { diff --git a/test/WebSites/WebApiCompatShimWebSite/Models/User.cs b/test/WebSites/WebApiCompatShimWebSite/Models/User.cs index 7e6db5217d..32b5a65cbf 100644 --- a/test/WebSites/WebApiCompatShimWebSite/Models/User.cs +++ b/test/WebSites/WebApiCompatShimWebSite/Models/User.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. -using System; namespace WebApiCompatShimWebSite { diff --git a/test/WebSites/WebApiCompatShimWebSite/Models/UserAddress.cs b/test/WebSites/WebApiCompatShimWebSite/Models/UserAddress.cs index 6c79945ee2..bec284341b 100644 --- a/test/WebSites/WebApiCompatShimWebSite/Models/UserAddress.cs +++ b/test/WebSites/WebApiCompatShimWebSite/Models/UserAddress.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. -using System; namespace WebApiCompatShimWebSite { diff --git a/test/WebSites/WebApiCompatShimWebSite/Startup.cs b/test/WebSites/WebApiCompatShimWebSite/Startup.cs index 8be05a3231..7b912327ec 100644 --- a/test/WebSites/WebApiCompatShimWebSite/Startup.cs +++ b/test/WebSites/WebApiCompatShimWebSite/Startup.cs @@ -2,7 +2,6 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using Microsoft.AspNet.Builder; -using Microsoft.AspNet.Mvc; using Microsoft.AspNet.Routing; using Microsoft.Framework.DependencyInjection;