From 8ad7c19379d9b0a5b787b1968369714aef64fb48 Mon Sep 17 00:00:00 2001 From: Pranav K Date: Thu, 3 Nov 2016 10:42:20 -0700 Subject: [PATCH] Remove references to Iddentity --- test/WebSites/SecurityWebSite/Startup.cs | 26 +--------------------- test/WebSites/SecurityWebSite/project.json | 17 +++----------- 2 files changed, 4 insertions(+), 39 deletions(-) diff --git a/test/WebSites/SecurityWebSite/Startup.cs b/test/WebSites/SecurityWebSite/Startup.cs index fe7fa7b9f2..c96227b635 100644 --- a/test/WebSites/SecurityWebSite/Startup.cs +++ b/test/WebSites/SecurityWebSite/Startup.cs @@ -2,27 +2,12 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using Microsoft.AspNetCore.Builder; -using Microsoft.AspNetCore.Hosting; -using Microsoft.Extensions.Configuration; using Microsoft.Extensions.DependencyInjection; -using Microsoft.Extensions.Logging; namespace SecurityWebSite { public class Startup { - public Startup(IHostingEnvironment env) - { - var builder = new ConfigurationBuilder() - .SetBasePath(env.ContentRootPath) - .AddJsonFile("appsettings.json", optional: true, reloadOnChange: true) - .AddJsonFile($"appsettings.{env.EnvironmentName}.json", optional: true) - .AddEnvironmentVariables(); - Configuration = builder.Build(); - } - - public IConfigurationRoot Configuration { get; } - // This method gets called by the runtime. Use this method to add services to the container. public void ConfigureServices(IServiceCollection services) { @@ -33,17 +18,8 @@ namespace SecurityWebSite } // This method gets called by the runtime. Use this method to configure the HTTP request pipeline. - public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory) + public void Configure(IApplicationBuilder app) { - loggerFactory.AddConsole(Configuration.GetSection("Logging")); - loggerFactory.AddDebug(); - - if (env.IsDevelopment()) - { - app.UseDeveloperExceptionPage(); - } - - app.UseStaticFiles(); app.UseCookieAuthentication(new CookieAuthenticationOptions { LoginPath = "/Home/Login", diff --git a/test/WebSites/SecurityWebSite/project.json b/test/WebSites/SecurityWebSite/project.json index a1bfa558d5..b5f728da4e 100644 --- a/test/WebSites/SecurityWebSite/project.json +++ b/test/WebSites/SecurityWebSite/project.json @@ -4,20 +4,10 @@ "preserveCompilationContext": true }, "dependencies": { - "Microsoft.Extensions.Logging.Debug": "1.1.0-*", - "Microsoft.Extensions.Logging.Console": "1.1.0-*", - "Microsoft.Extensions.Configuration.Json": "1.1.0-*", - "Microsoft.Extensions.Configuration.FileExtensions": "1.1.0-*", - "Microsoft.Extensions.Configuration.EnvironmentVariables": "1.1.0-*", - "Microsoft.Extensions.Configuration": "1.1.0-*", - "Microsoft.AspNetCore.StaticFiles": "1.1.0-*", + "Microsoft.AspNetCore.Authentication.Cookies": "1.1.0-*", "Microsoft.AspNetCore.Server.Kestrel": "1.1.0-*", "Microsoft.AspNetCore.Mvc": "1.1.0-*", - "Microsoft.AspNetCore.Mvc.ViewFeatures": "1.1.0-*", - "Microsoft.AspNetCore.Identity.EntityFrameworkCore": "1.1.0-*", - "Microsoft.AspNetCore.Identity": "1.1.0-*", - "Microsoft.AspNetCore.Hosting": "1.1.0-*", - "Microsoft.AspNetCore.Diagnostics": "1.1.0-*" + "Microsoft.AspNetCore.Hosting": "1.1.0-*" }, "frameworks": { "netcoreapp1.1": { @@ -26,8 +16,7 @@ "version": "1.1.0-*", "type": "platform" } - }, - "imports": "portable-net451+win8" + } }, "net451": {} },