Recently we have updated all Ninject Nuget packages to Nuget 1.3. In order to use them you have to update your client to 1.3 as well. This update brought a few improvements:
- All packages support client profile projects for .NET 4.0 and -NET 3.5
- Support for WP7 has been added
- New packages have been added for Ninject.Extensions.Logging, Ninject.Extensions.Interception, Ninject.MockingKernel and Ninject.Web.FluentAssertions
- Ninject.MVC3 supports injection of HttpApplication (See below)
Notes about the new packages
The packages for Ninject.Extensions.Logging, Ninject.Extensions.Interception and Ninject.MockingKernel shouldn be installed directly. They are base packages for the specific packages. E.g. if you want to use Ninject.Extensions.Logging you have to decide which logging framework you want to use. If you want to use log4net you have to install Ninject.Extensions.Logging.Log4Net which will install the Ninject.Extensions.Logging as depecy.
Changes in Ninject.MVC3
A bug that was introduced with the first nuget package as been fixed. The HttpApplication itself will now be injected again. But as before it only supports property injection. If you update your project from a previous version of Ninject.MVC3 your App_Start\NinjectMVC3.cs might not get updated correctly. Make sure that the Start method looks like the one below after the update:
public static void Start() { DynamicModuleUtility.RegisterModule(typeof(OnePerRequestModule)); DynamicModuleUtility.RegisterModule(typeof(HttpApplicationInitializationModule)); bootstrapper.Initialize(CreateKernel); }