Updated cache refresher factory to use PluginTypeResolver and added unit tests to show that it

resolves the objects, fixes up the GetAll() call since I'm not sure if that actually ever worked.
This commit is contained in:
shannon@ShandemVaio
2012-07-31 03:08:46 +06:00
parent c9a4b708aa
commit 5b8057f063
4 changed files with 148 additions and 22 deletions

View File

@@ -44,5 +44,15 @@ namespace Umbraco.Web
{
return resolver.ResolveAttributedTypes<XsltExtensionAttribute>();
}
/// <summary>
/// Returns all classes attributed with XsltExtensionAttribute attribute
/// </summary>
/// <param name="resolver"></param>
/// <returns></returns>
internal static IEnumerable<Type> ResolveCacheRefreshers(this PluginTypeResolver resolver)
{
return resolver.ResolveTypes<ICacheRefresher>();
}
}
}