One of the most significant changes is the dependency of APS.net 5 on the System.Web DLL. This DLL, that pretty much underpinned all that was web development, has been broken up into independent granular nuget packages that allow you to ship your application with exactly what you need.
Applications that we've used in the past have relied heavily on the HttpContext class allowing us to access the current context by the static property HttpContext.Current.
In ASP.net 5 large parts of the framework are now Dependency Inject-able. In order to access the current context you can simply inject the IHttpContextAccessor into your class in order to access the current context.
The beauty of this is we can then create our mocked HttpContext using the DefaultHttpContext object that can be found in Microsoft.AspNet.Http.Core.dll
Don't forget all .net code is now open sourced and this particular interface can be found at:
The interface has also been moved to:
As of RC2 some changes have been made to the IHttpContextAccessor and it's availability. The announcement on this change can be found here: