diff --git a/src/Umbraco.Tests.Benchmarks/App.config b/src/Umbraco.Tests.Benchmarks/App.config deleted file mode 100644 index e29f2348e4..0000000000 --- a/src/Umbraco.Tests.Benchmarks/App.config +++ /dev/null @@ -1,80 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/src/Umbraco.Tests.Benchmarks/BulkInsertBenchmarks.cs b/src/Umbraco.Tests.Benchmarks/BulkInsertBenchmarks.cs index 4896a6570a..2503931600 100644 --- a/src/Umbraco.Tests.Benchmarks/BulkInsertBenchmarks.cs +++ b/src/Umbraco.Tests.Benchmarks/BulkInsertBenchmarks.cs @@ -3,43 +3,24 @@ using System.Collections.Generic; using System.Data.SqlServerCe; using System.IO; using BenchmarkDotNet.Attributes; -using BenchmarkDotNet.Configs; -using BenchmarkDotNet.Diagnostics.Windows; -using BenchmarkDotNet.Jobs; using Umbraco.Core; using Umbraco.Core.Logging; using Umbraco.Core.Models.Rdbms; using Umbraco.Core.Persistence; using Umbraco.Core.Persistence.Migrations.Initial; using Umbraco.Core.Persistence.SqlSyntax; +using Umbraco.Tests.Benchmarks.Config; using Umbraco.Tests.TestHelpers; using ILogger = Umbraco.Core.Logging.ILogger; namespace Umbraco.Tests.Benchmarks { - [Config(typeof(Config))] + [QuickRunWithMemoryDiagnoser] public class BulkInsertBenchmarks { - private class Config : ManualConfig - { - public Config() - { - Add(new MemoryDiagnoser()); - //Add(ExecutionValidator.FailOnError); - - //The 'quick and dirty' settings, so it runs a little quicker - // see benchmarkdotnet FAQ - Add(Job.Default - .WithLaunchCount(1) // benchmark process will be launched only once - .WithIterationTime(100) // 100ms per iteration - .WithWarmupCount(3) // 3 warmup iteration - .WithTargetCount(3)); // 3 target iteration - } - } - private static byte[] _initDbBytes = null; - [Setup] + [GlobalSetup] public void Setup() { var logger = new DebugDiagnosticsLogger(); @@ -51,8 +32,8 @@ namespace Umbraco.Tests.Benchmarks SetupSqlCe(path, logger); SetupSqlServer(logger); - - } + + } private void SetupSqlServer(ILogger logger) { @@ -75,7 +56,7 @@ namespace Umbraco.Tests.Benchmarks [lastNotifiedDate] [datetime] NOT NULL, [isActive] [bit] NOT NULL, [isMaster] [bit] NOT NULL, - CONSTRAINT [PK_umbracoServer] PRIMARY KEY CLUSTERED + CONSTRAINT [PK_umbracoServer] PRIMARY KEY CLUSTERED ( [id] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY] @@ -87,7 +68,7 @@ namespace Umbraco.Tests.Benchmarks var dbName = string.Concat("Umb", Guid.NewGuid(), ".sdf"); AppDomain.CurrentDomain.SetData("DataDirectory", path); var sqlCeConnectionString = $"Datasource=|DataDirectory|\\{dbName};Flush Interval=1;"; - + _dbFile = Path.Combine(path, dbName); //only create the db one time @@ -107,12 +88,12 @@ namespace Umbraco.Tests.Benchmarks var creation = new DatabaseSchemaCreation(_dbSqlCe, logger, _sqlCeSyntax); creation.InitializeDatabaseSchema(); } - _initDbBytes = File.ReadAllBytes(_dbFile); + _initDbBytes = File.ReadAllBytes(_dbFile); } else { File.WriteAllBytes(_dbFile, _initDbBytes); - } + } //create the db _dbSqlCe = new UmbracoDatabase( @@ -138,7 +119,7 @@ namespace Umbraco.Tests.Benchmarks return data; } - [Cleanup] + [GlobalCleanup] public void Cleanup() { _dbSqlCe.Dispose(); diff --git a/src/Umbraco.Tests.Benchmarks/Config/QuickRunAttribute.cs b/src/Umbraco.Tests.Benchmarks/Config/QuickRunAttribute.cs new file mode 100644 index 0000000000..c06932aa2e --- /dev/null +++ b/src/Umbraco.Tests.Benchmarks/Config/QuickRunAttribute.cs @@ -0,0 +1,25 @@ +using BenchmarkDotNet.Configs; +using BenchmarkDotNet.Horology; +using BenchmarkDotNet.Jobs; +using System; + +namespace Umbraco.Tests.Benchmarks.Config +{ + /// + /// Configures the benchmark to run with less warmup and a shorter iteration time than the standard benchmark. + /// + public class QuickRunAttribute : Attribute, IConfigSource + { + public QuickRunAttribute() + { + Config = ManualConfig.CreateEmpty() + .With(Job.Default.WithLaunchCount(1) // benchmark process will be launched only once + .WithIterationTime(new TimeInterval(100, TimeUnit.Millisecond)) // 100ms per iteration + .WithWarmupCount(3) // 3 warmup iteration + .WithTargetCount(3)); // 3 target iteration + } + + /// + public IConfig Config { get; } + } +} \ No newline at end of file diff --git a/src/Umbraco.Tests.Benchmarks/Config/QuickRunWithMemoryDiagnoserAttribute.cs b/src/Umbraco.Tests.Benchmarks/Config/QuickRunWithMemoryDiagnoserAttribute.cs new file mode 100644 index 0000000000..12e3c9164e --- /dev/null +++ b/src/Umbraco.Tests.Benchmarks/Config/QuickRunWithMemoryDiagnoserAttribute.cs @@ -0,0 +1,17 @@ +using BenchmarkDotNet.Configs; +using BenchmarkDotNet.Diagnosers; + +namespace Umbraco.Tests.Benchmarks.Config +{ + /// + /// Configures the benchmark to run with less warmup and a shorter iteration time than the standard benchmark. + /// Memory usage diagnosis is included in the benchmark + /// + public class QuickRunWithMemoryDiagnoserAttribute : QuickRunAttribute + { + public QuickRunWithMemoryDiagnoserAttribute() + { + ((ManualConfig)this.Config).Add(new MemoryDiagnoser()); + } + } +} \ No newline at end of file diff --git a/src/Umbraco.Tests.Benchmarks/LinqCastBenchmarks.cs b/src/Umbraco.Tests.Benchmarks/LinqCastBenchmarks.cs index 4118620515..0c5b3ccd61 100644 --- a/src/Umbraco.Tests.Benchmarks/LinqCastBenchmarks.cs +++ b/src/Umbraco.Tests.Benchmarks/LinqCastBenchmarks.cs @@ -1,25 +1,16 @@ using System.Collections.Generic; using System.Linq; using BenchmarkDotNet.Attributes; -using BenchmarkDotNet.Configs; -using BenchmarkDotNet.Diagnostics.Windows; +using BenchmarkDotNet.Diagnosers; namespace Umbraco.Tests.Benchmarks { /// /// Want to check what is faster OfType or Cast when a enurable all has the same items /// - [Config(typeof(Config))] + [MemoryDiagnoser] public class LinqCastBenchmarks { - private class Config : ManualConfig - { - public Config() - { - Add(new MemoryDiagnoser()); - } - } - public LinqCastBenchmarks() { _array = new List(); diff --git a/src/Umbraco.Tests.Benchmarks/ModelToSqlExpressionHelperBenchmarks.cs b/src/Umbraco.Tests.Benchmarks/ModelToSqlExpressionHelperBenchmarks.cs index 5fa395d2f1..ce6db4c3e2 100644 --- a/src/Umbraco.Tests.Benchmarks/ModelToSqlExpressionHelperBenchmarks.cs +++ b/src/Umbraco.Tests.Benchmarks/ModelToSqlExpressionHelperBenchmarks.cs @@ -1,47 +1,19 @@ using System; -using System.Collections.Generic; -using System.Data.SqlServerCe; -using System.Diagnostics; -using System.IO; using System.Linq.Expressions; -using System.Threading; -using System.Xml; using BenchmarkDotNet.Attributes; -using BenchmarkDotNet.Columns; -using BenchmarkDotNet.Configs; using BenchmarkDotNet.Diagnosers; -using BenchmarkDotNet.Diagnostics.Windows; -using BenchmarkDotNet.Jobs; -using BenchmarkDotNet.Loggers; -using BenchmarkDotNet.Reports; using BenchmarkDotNet.Running; -using BenchmarkDotNet.Validators; using Moq; -using Umbraco.Core; -using Umbraco.Core.Logging; using Umbraco.Core.Models; -using Umbraco.Core.Models.Rdbms; -using Umbraco.Core.Persistence; using Umbraco.Core.Persistence.Mappers; -using Umbraco.Core.Persistence.Migrations.Initial; using Umbraco.Core.Persistence.Querying; using Umbraco.Core.Persistence.SqlSyntax; -using Umbraco.Tests.TestHelpers; -using ILogger = Umbraco.Core.Logging.ILogger; namespace Umbraco.Tests.Benchmarks { - [Config(typeof(Config))] + [MemoryDiagnoser] public class ModelToSqlExpressionHelperBenchmarks { - private class Config : ManualConfig - { - public Config() - { - Add(new MemoryDiagnoser()); - } - } - public ModelToSqlExpressionHelperBenchmarks() { var contentMapper = new ContentMapper(_syntaxProvider); @@ -51,7 +23,7 @@ namespace Umbraco.Tests.Benchmarks mappingResolver.Setup(resolver => resolver.ResolveMapperByType(It.IsAny())).Returns(contentMapper); _mappingResolver = mappingResolver.Object; } - + private readonly ISqlSyntaxProvider _syntaxProvider = new SqlCeSyntaxProvider(); private readonly CachedExpression _cachedExpression; private readonly MappingResolver _mappingResolver; @@ -62,18 +34,15 @@ namespace Umbraco.Tests.Benchmarks for (int i = 0; i < 100; i++) { var a = i; - var b = i*10; + var b = i * 10; Expression> predicate = content => content.Path.StartsWith("-1") && content.Published && (content.ContentTypeId == a || content.ContentTypeId == b); var modelToSqlExpressionHelper = new ModelToSqlExpressionVisitor(_syntaxProvider, _mappingResolver); var result = modelToSqlExpressionHelper.Visit(predicate); } - } - - [Benchmark()] public void WithCachedExpression() { @@ -83,7 +52,7 @@ namespace Umbraco.Tests.Benchmarks var b = i * 10; Expression> predicate = content => content.Path.StartsWith("-1") && content.Published && (content.ContentTypeId == a || content.ContentTypeId == b); - + var modelToSqlExpressionHelper = new ModelToSqlExpressionVisitor(_syntaxProvider, _mappingResolver); //wrap it! @@ -92,6 +61,5 @@ namespace Umbraco.Tests.Benchmarks var result = modelToSqlExpressionHelper.Visit(_cachedExpression); } } - } } \ No newline at end of file diff --git a/src/Umbraco.Tests.Benchmarks/Program.cs b/src/Umbraco.Tests.Benchmarks/Program.cs index 2f41642bbf..c9332e7fa3 100644 --- a/src/Umbraco.Tests.Benchmarks/Program.cs +++ b/src/Umbraco.Tests.Benchmarks/Program.cs @@ -6,17 +6,7 @@ namespace Umbraco.Tests.Benchmarks { public static void Main(string[] args) { - var switcher = new BenchmarkSwitcher(new[] - { - typeof(BulkInsertBenchmarks), - typeof(ModelToSqlExpressionHelperBenchmarks), - typeof(XmlBenchmarks), - typeof(LinqCastBenchmarks), - //typeof(DeepCloneBenchmarks), - typeof(XmlPublishedContentInitBenchmarks), - - }); - switcher.Run(args); + new BenchmarkSwitcher(typeof(Program).Assembly).Run(args); } } } diff --git a/src/Umbraco.Tests.Benchmarks/TryConvertToBenchmarks.cs b/src/Umbraco.Tests.Benchmarks/TryConvertToBenchmarks.cs new file mode 100644 index 0000000000..57b47dc1d0 --- /dev/null +++ b/src/Umbraco.Tests.Benchmarks/TryConvertToBenchmarks.cs @@ -0,0 +1,44 @@ +using System; +using System.Collections.Generic; +using BenchmarkDotNet.Attributes; +using Umbraco.Core; + +namespace Umbraco.Tests.Benchmarks +{ + [MemoryDiagnoser] + public class TryConvertToBenchmarks + { + private static readonly List List = new List() { "hello", "world", "awesome" }; + private static readonly string Date = "Saturday 10, November 2012"; + + [Benchmark(Description = "List to IEnumerable")] + public IEnumerable TryConvertToEnumerable() + { + return List.TryConvertTo>().Result; + } + + [Benchmark(Description = "Int to Double")] + public double TryConvertToDouble() + { + return 1.TryConvertTo().Result; + } + + [Benchmark(Description = "Float to Decimal")] + public decimal TryConvertToDecimal() + { + return 1F.TryConvertTo().Result; + } + + [Benchmark(Description = "String to Boolean")] + public bool TryConvertToBoolean() + { + return "1".TryConvertTo().Result; + } + + [Benchmark(Description = "String to DateTime")] + public DateTime TryConvertToDateTime() + { + return Date.TryConvertTo().Result; + } + } +} \ No newline at end of file diff --git a/src/Umbraco.Tests.Benchmarks/Umbraco.Tests.Benchmarks.csproj b/src/Umbraco.Tests.Benchmarks/Umbraco.Tests.Benchmarks.csproj index 6cad6893f5..2956003ce5 100644 --- a/src/Umbraco.Tests.Benchmarks/Umbraco.Tests.Benchmarks.csproj +++ b/src/Umbraco.Tests.Benchmarks/Umbraco.Tests.Benchmarks.csproj @@ -9,11 +9,12 @@ Properties Umbraco.Tests.Benchmarks Umbraco.Tests.Benchmarks - v4.5 + v4.6 512 + true AnyCPU @@ -38,38 +39,55 @@ Always - - ..\packages\BenchmarkDotNet.0.9.9\lib\net45\BenchmarkDotNet.dll + + ..\packages\BenchmarkDotNet.0.10.12\lib\net46\BenchmarkDotNet.dll - - ..\packages\BenchmarkDotNet.Core.0.9.9\lib\net45\BenchmarkDotNet.Core.dll + + ..\packages\BenchmarkDotNet.Core.0.10.12\lib\net46\BenchmarkDotNet.Core.dll ..\packages\BenchmarkDotNet.Diagnostics.Windows.0.9.9\lib\net45\BenchmarkDotNet.Diagnostics.Windows.dll - - ..\packages\BenchmarkDotNet.Toolchains.Roslyn.0.9.9\lib\net45\BenchmarkDotNet.Toolchains.Roslyn.dll + + ..\packages\BenchmarkDotNet.Toolchains.Roslyn.0.10.12\lib\net46\BenchmarkDotNet.Toolchains.Roslyn.dll ..\packages\Castle.Core.4.0.0\lib\net45\Castle.Core.dll - - ..\packages\Microsoft.CodeAnalysis.Common.1.3.2\lib\net45\Microsoft.CodeAnalysis.dll + + ..\packages\Microsoft.CodeAnalysis.Common.2.4.0\lib\netstandard1.3\Microsoft.CodeAnalysis.dll - - ..\packages\Microsoft.CodeAnalysis.CSharp.1.3.2\lib\net45\Microsoft.CodeAnalysis.CSharp.dll + + ..\packages\Microsoft.CodeAnalysis.CSharp.2.4.0\lib\netstandard1.3\Microsoft.CodeAnalysis.CSharp.dll ..\packages\Microsoft.Diagnostics.Tracing.TraceEvent.1.0.41\lib\net40\Microsoft.Diagnostics.Tracing.TraceEvent.dll + + ..\packages\Microsoft.DotNet.InternalAbstractions.1.0.0\lib\net451\Microsoft.DotNet.InternalAbstractions.dll + + + ..\packages\Microsoft.DotNet.PlatformAbstractions.1.1.1\lib\net451\Microsoft.DotNet.PlatformAbstractions.dll + + + ..\packages\Microsoft.Win32.Registry.4.3.0\lib\net46\Microsoft.Win32.Registry.dll + ..\packages\Moq.4.1.1309.0919\lib\net40\Moq.dll - - ..\packages\System.Collections.Immutable.1.2.0\lib\portable-net45+win8+wp8+wpa81\System.Collections.Immutable.dll + + ..\packages\System.AppContext.4.3.0\lib\net46\System.AppContext.dll + True + + + ..\packages\System.Collections.Immutable.1.3.1\lib\portable-net45+win8+wp8+wpa81\System.Collections.Immutable.dll + True + + ..\packages\System.Console.4.3.0\lib\net46\System.Console.dll + ..\packages\SqlServerCE.4.0.0.1\lib\System.Data.SqlServerCe.dll @@ -77,13 +95,52 @@ ..\packages\SqlServerCE.4.0.0.1\lib\System.Data.SqlServerCe.Entity.dll + + ..\packages\System.Diagnostics.FileVersionInfo.4.3.0\lib\net46\System.Diagnostics.FileVersionInfo.dll + + + ..\packages\System.Diagnostics.StackTrace.4.3.0\lib\net46\System.Diagnostics.StackTrace.dll + + + ..\packages\System.IO.Compression.4.3.0\lib\net46\System.IO.Compression.dll + True + + + ..\packages\System.IO.FileSystem.4.3.0\lib\net46\System.IO.FileSystem.dll + + + ..\packages\System.IO.FileSystem.Primitives.4.3.0\lib\net46\System.IO.FileSystem.Primitives.dll + - - ..\packages\System.Reflection.Metadata.1.3.0\lib\portable-net45+win8\System.Reflection.Metadata.dll + + ..\packages\System.Reflection.Metadata.1.4.2\lib\portable-net45+win8\System.Reflection.Metadata.dll - - ..\packages\System.Threading.Tasks.Extensions.4.0.0\lib\portable-net45+win8+wp8+wpa81\System.Threading.Tasks.Extensions.dll + + ..\packages\System.Security.Cryptography.Algorithms.4.3.0\lib\net46\System.Security.Cryptography.Algorithms.dll + True + + + ..\packages\System.Security.Cryptography.Encoding.4.3.0\lib\net46\System.Security.Cryptography.Encoding.dll + + + ..\packages\System.Security.Cryptography.Primitives.4.3.0\lib\net46\System.Security.Cryptography.Primitives.dll + + + ..\packages\System.Security.Cryptography.X509Certificates.4.3.0\lib\net46\System.Security.Cryptography.X509Certificates.dll + True + + + ..\packages\System.Text.Encoding.CodePages.4.3.0\lib\net46\System.Text.Encoding.CodePages.dll + + + ..\packages\System.Threading.Tasks.Extensions.4.3.0\lib\portable-net45+win8+wp8+wpa81\System.Threading.Tasks.Extensions.dll + + + ..\packages\System.Threading.Thread.4.3.0\lib\net46\System.Threading.Thread.dll + + + ..\packages\System.ValueTuple.4.3.0\lib\netstandard1.0\System.ValueTuple.dll @@ -91,20 +148,33 @@ + + ..\packages\System.Xml.ReaderWriter.4.3.0\lib\net46\System.Xml.ReaderWriter.dll + + + ..\packages\System.Xml.XmlDocument.4.3.0\lib\net46\System.Xml.XmlDocument.dll + + + ..\packages\System.Xml.XPath.4.3.0\lib\net46\System.Xml.XPath.dll + + + ..\packages\System.Xml.XPath.XDocument.4.3.0\lib\net46\System.Xml.XPath.XDocument.dll + + + + - - @@ -120,10 +190,6 @@ Umbraco.Web - - - - diff --git a/src/Umbraco.Tests.Benchmarks/XmlBenchmarks.cs b/src/Umbraco.Tests.Benchmarks/XmlBenchmarks.cs index c12545ec94..c95af1d64a 100644 --- a/src/Umbraco.Tests.Benchmarks/XmlBenchmarks.cs +++ b/src/Umbraco.Tests.Benchmarks/XmlBenchmarks.cs @@ -1,42 +1,19 @@ using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; using System.Xml; using BenchmarkDotNet.Attributes; -using BenchmarkDotNet.Configs; -using BenchmarkDotNet.Diagnostics.Windows; -using BenchmarkDotNet.Jobs; +using Umbraco.Tests.Benchmarks.Config; namespace Umbraco.Tests.Benchmarks { - [Config(typeof(Config))] + [QuickRunWithMemoryDiagnoser] public class XmlBenchmarks { - private class Config : ManualConfig - { - public Config() - { - Add(new MemoryDiagnoser()); - //Add(ExecutionValidator.FailOnError); - - //The 'quick and dirty' settings, so it runs a little quicker - // see benchmarkdotnet FAQ - Add(Job.Default - .WithLaunchCount(1) // benchmark process will be launched only once - .WithIterationTime(100) // 100ms per iteration - .WithWarmupCount(3) // 3 warmup iteration - .WithTargetCount(3)); // 3 target iteration - } - } - - [Setup] + [GlobalSetup] public void Setup() { var templateId = 0; var xmlText = @" - @@ -49,7 +26,7 @@ namespace Umbraco.Tests.Benchmarks 1 This is some content]]> - + @@ -70,7 +47,7 @@ namespace Umbraco.Tests.Benchmarks _xml.LoadXml(xmlText); } - [Cleanup] + [GlobalCleanup] public void Cleanup() { _xml = null; @@ -90,7 +67,7 @@ namespace Umbraco.Tests.Benchmarks public void XmlWithNavigation() { var elt = _xml.DocumentElement; - var id = NavigateElementRoute(elt, new[] {"home", "sub1", "sub2"}); + var id = NavigateElementRoute(elt, new[] { "home", "sub1", "sub2" }); if (id <= 0) Console.WriteLine("ERR"); } @@ -120,4 +97,4 @@ namespace Umbraco.Tests.Benchmarks return found ? int.Parse(elt.GetAttribute("id")) : -1; } } -} +} \ No newline at end of file diff --git a/src/Umbraco.Tests.Benchmarks/XmlPublishedContentInitBenchmarks.cs b/src/Umbraco.Tests.Benchmarks/XmlPublishedContentInitBenchmarks.cs index e26022d8e7..9113c6e6f4 100644 --- a/src/Umbraco.Tests.Benchmarks/XmlPublishedContentInitBenchmarks.cs +++ b/src/Umbraco.Tests.Benchmarks/XmlPublishedContentInitBenchmarks.cs @@ -3,37 +3,17 @@ using System.Collections.Generic; using System.Linq; using System.Xml; using BenchmarkDotNet.Attributes; -using BenchmarkDotNet.Configs; -using BenchmarkDotNet.Diagnostics.Windows; -using BenchmarkDotNet.Jobs; -using Microsoft.CodeAnalysis.CSharp.Syntax; using Umbraco.Core; -using Umbraco.Core.Configuration; using Umbraco.Core.Models; using Umbraco.Core.Models.PublishedContent; +using Umbraco.Tests.Benchmarks.Config; using Umbraco.Web.PublishedCache.XmlPublishedCache; namespace Umbraco.Tests.Benchmarks { - [Config(typeof(Config))] + [QuickRunWithMemoryDiagnoser] public class XmlPublishedContentInitBenchmarks { - private class Config : ManualConfig - { - public Config() - { - Add(new MemoryDiagnoser()); - - //The 'quick and dirty' settings, so it runs a little quicker - // see benchmarkdotnet FAQ - Add(Job.Default - .WithLaunchCount(1) // benchmark process will be launched only once - .WithIterationTime(100) // 100ms per iteration - .WithWarmupCount(3) // 3 warmup iteration - .WithTargetCount(3)); // 3 target iteration - } - } - public XmlPublishedContentInitBenchmarks() { _xml10 = Build(10); @@ -281,7 +261,7 @@ namespace Umbraco.Tests.Benchmarks var nodes = xmlNode.SelectNodes(dataXPath); contentType = GetPublishedContentType(PublishedItemType.Content, docTypeAlias); - + var propertyNodes = new Dictionary(); if (nodes != null) foreach (XmlNode n in nodes) @@ -307,8 +287,8 @@ namespace Umbraco.Tests.Benchmarks private static PublishedContentType GetPublishedContentType(PublishedItemType type, string alias) { - return new PublishedContentType(alias, new string[] {}, - new List(Enumerable.Range(0, 10).Select(x => new PublishedPropertyType("prop" + x, 0, "test", initConverters:false)))); + return new PublishedContentType(alias, new string[] { }, + new List(Enumerable.Range(0, 10).Select(x => new PublishedPropertyType("prop" + x, 0, "test", initConverters: false)))); } } diff --git a/src/Umbraco.Tests.Benchmarks/packages.config b/src/Umbraco.Tests.Benchmarks/packages.config index ae552b8cd5..82ed3b4bf2 100644 --- a/src/Umbraco.Tests.Benchmarks/packages.config +++ b/src/Umbraco.Tests.Benchmarks/packages.config @@ -1,40 +1,61 @@  - - + + - + - - + + + + + - - - - - - - - - - - + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file