Five New Optimizely Certifications are Here! Validate your expertise and advance your career with our latest certification exams. Click here to find out more
AI OnAI Off
Five New Optimizely Certifications are Here! Validate your expertise and advance your career with our latest certification exams. Click here to find out more
protected UIDescriptor(Type forType, string iconClass, IEnumerable<string> dndTypes)
: this(forType, iconClass, dndTypes, ServiceProviderExtensions.GetAllInstances<ViewConfiguration>(ServiceLocator.Current), LocalizationService.Current, ServiceProviderExtensions.GetInstance<IContentTypeRepository>(ServiceLocator.Current))
{
}
Imho very bad design descision to add that internal construction paramater here ...
ServiceProviderExtensions.GetInstance<IContentTypeRepository>(ServiceLocator.Current)
Yes I can mock the serviceprovider ... but I thought you (Optimizely) would get rid of all those bad anti pattern stuff and only use proper injection. (hands up for those of you who loves doing unit tests for Episerver Commerce ... <being sarcastic>)