Files
Umbraco-CMS/src/Umbraco.Tests/DynamicDocument/DynamicDocumentCustomExtensionMethods.cs
Shannon Deminick 92602e3480 Added unit tests for legacy DynamicNode which now just runs tests on the abstract class so we share tests between
DynamicDocument and DynamicNode.
Fixes: #U4-691
Fixes: #U4-690
2012-08-25 07:07:00 +07:00

35 lines
947 B
C#

using System.Collections.Generic;
using Umbraco.Core.Dynamics;
namespace Umbraco.Tests.DynamicDocument
{
public static class DynamicDocumentCustomExtensionMethods
{
public static string DynamicDocumentNoParameters(this Core.Dynamics.DynamicDocument doc)
{
return "Hello world";
}
public static string DynamicDocumentCustomString(this Core.Dynamics.DynamicDocument doc, string custom)
{
return custom;
}
public static string DynamicDocumentMultiParam(this Core.Dynamics.DynamicDocument doc, string custom, int i, bool b)
{
return custom + i + b;
}
public static string DynamicDocumentListMultiParam(this DynamicDocumentList doc, string custom, int i, bool b)
{
return custom + i + b;
}
public static string DynamicDocumentEnumerableMultiParam(this IEnumerable<Core.Dynamics.DynamicDocument> doc, string custom, int i, bool b)
{
return custom + i + b;
}
}
}