I've recently updated structuremap and discovered that you can't inject concrete instances to properties anymore using old syntax. For example the code is no longer valid:
public class IdentityRegistry : Registry
{
public IdentityRegistry()
{
For<IAuthenticationManager>().Use(manager => HttpContext.Current.GetOwinContext().Authentication);
Policies
.FillAllPropertiesOfType<IAuthenticationManager>()
.Use(manager => HttpContext.Current.GetOwinContext().Authentication);
}
}
How to make the code work with previous effect?