Avoid adding an InternalResourceViewResolver when ViewResolverRegistry is empty

Issue: SPR-12013