Merge branch 'master' into merge/release/5.0-preview2-to-master
This commit is contained in:
commit
8cd77358ea
|
|
@ -13,21 +13,21 @@
|
|||
<Uri>https://github.com/dotnet/blazor</Uri>
|
||||
<Sha>dd7fb4d3931d556458f62642c2edfc59f6295bfb</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.AspNetCore.Razor.Language" Version="5.0.0-preview.3.20156.7">
|
||||
<Dependency Name="Microsoft.AspNetCore.Razor.Language" Version="5.0.0-preview.3.20157.1">
|
||||
<Uri>https://github.com/dotnet/aspnetcore-tooling</Uri>
|
||||
<Sha>89579a87b9e8701a79e3584fa8bfd4e4efedcc7e</Sha>
|
||||
<Sha>cc921d78edc850e3214917274d117bcc1450884b</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.AspNetCore.Mvc.Razor.Extensions" Version="5.0.0-preview.3.20156.7">
|
||||
<Dependency Name="Microsoft.AspNetCore.Mvc.Razor.Extensions" Version="5.0.0-preview.3.20157.1">
|
||||
<Uri>https://github.com/dotnet/aspnetcore-tooling</Uri>
|
||||
<Sha>89579a87b9e8701a79e3584fa8bfd4e4efedcc7e</Sha>
|
||||
<Sha>cc921d78edc850e3214917274d117bcc1450884b</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.CodeAnalysis.Razor" Version="5.0.0-preview.3.20156.7">
|
||||
<Dependency Name="Microsoft.CodeAnalysis.Razor" Version="5.0.0-preview.3.20157.1">
|
||||
<Uri>https://github.com/dotnet/aspnetcore-tooling</Uri>
|
||||
<Sha>89579a87b9e8701a79e3584fa8bfd4e4efedcc7e</Sha>
|
||||
<Sha>cc921d78edc850e3214917274d117bcc1450884b</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.NET.Sdk.Razor" Version="5.0.0-preview.3.20156.7">
|
||||
<Dependency Name="Microsoft.NET.Sdk.Razor" Version="5.0.0-preview.3.20157.1">
|
||||
<Uri>https://github.com/dotnet/aspnetcore-tooling</Uri>
|
||||
<Sha>89579a87b9e8701a79e3584fa8bfd4e4efedcc7e</Sha>
|
||||
<Sha>cc921d78edc850e3214917274d117bcc1450884b</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="dotnet-ef" Version="5.0.0-preview.3.20156.3">
|
||||
<Uri>https://github.com/dotnet/efcore</Uri>
|
||||
|
|
@ -57,165 +57,169 @@
|
|||
<Uri>https://github.com/dotnet/efcore</Uri>
|
||||
<Sha>f1a6840fbc5c72a6cf2756dbdbcc65622434ebd7</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.AspNetCore.Analyzer.Testing" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.AspNetCore.Analyzer.Testing" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Caching.Abstractions" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Caching.Abstractions" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Caching.Memory" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Caching.Memory" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Caching.SqlServer" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Caching.SqlServer" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Caching.StackExchangeRedis" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Caching.StackExchangeRedis" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.Abstractions" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.Abstractions" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.Binder" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.AzureKeyVault" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.CommandLine" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.Binder" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.EnvironmentVariables" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.CommandLine" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.FileExtensions" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.EnvironmentVariables" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.Ini" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.FileExtensions" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.Json" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.Ini" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.UserSecrets" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.Json" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.Xml" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.UserSecrets" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Configuration" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Configuration.Xml" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.DependencyInjection.Abstractions" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Configuration" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.DependencyInjection" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.DependencyInjection.Abstractions" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.DiagnosticAdapter" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.DependencyInjection" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.FileProviders.Abstractions" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.DiagnosticAdapter" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.FileProviders.Composite" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.FileProviders.Abstractions" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.FileProviders.Physical" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.FileProviders.Composite" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.FileSystemGlobbing" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.FileProviders.Physical" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Hosting.Abstractions" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.FileSystemGlobbing" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Hosting" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Hosting.Abstractions" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Http" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Hosting" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Logging.Abstractions" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Http" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Logging.AzureAppServices" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Logging.Abstractions" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Logging.Configuration" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Logging.AzureAppServices" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Logging.Console" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Logging.Configuration" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Logging.Debug" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Logging.Console" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Logging.EventSource" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Logging.Debug" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Logging.EventLog" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Logging.EventSource" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Logging.TraceSource" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Logging.EventLog" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Logging.Testing" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Logging.TraceSource" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Logging" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Logging.Testing" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Options.ConfigurationExtensions" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Logging" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Options.DataAnnotations" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Options.ConfigurationExtensions" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Options" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Options.DataAnnotations" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Extensions.Primitives" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Options" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Internal.Extensions.Refs" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Microsoft.Extensions.Primitives" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Internal.Extensions.Refs" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.Win32.Registry" Version="5.0.0-preview.2.20155.3" CoherentParentDependency="Microsoft.NETCore.App.Runtime.win-x64">
|
||||
<Uri>https://github.com/dotnet/runtime</Uri>
|
||||
|
|
@ -328,9 +332,9 @@
|
|||
<Uri>https://github.com/dotnet/runtime</Uri>
|
||||
<Sha>2f6e072c97738a56eeeb25f1fdb5dcc955649db0</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Internal.AspNetCore.Analyzers" Version="5.0.0-preview.3.20156.2" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Dependency Name="Internal.AspNetCore.Analyzers" Version="5.0.0-preview.3.20156.3" CoherentParentDependency="Microsoft.AspNetCore.Razor.Language">
|
||||
<Uri>https://github.com/dotnet/extensions</Uri>
|
||||
<Sha>9a8d035b5f1c7264d8537d73a08cb812238699f1</Sha>
|
||||
<Sha>540b4e8f129a132749a60174464b8c8274bfed7d</Sha>
|
||||
</Dependency>
|
||||
<Dependency Name="Microsoft.DotNet.GenAPI" Version="5.0.0-beta.20151.1">
|
||||
<Uri>https://github.com/dotnet/arcade</Uri>
|
||||
|
|
|
|||
|
|
@ -97,47 +97,48 @@
|
|||
<!-- Packages from dotnet/blazor -->
|
||||
<MicrosoftAspNetCoreBlazorMonoPackageVersion>3.2.0-preview1.20067.1</MicrosoftAspNetCoreBlazorMonoPackageVersion>
|
||||
<!-- Packages from dotnet/extensions -->
|
||||
<InternalAspNetCoreAnalyzersPackageVersion>5.0.0-preview.3.20156.2</InternalAspNetCoreAnalyzersPackageVersion>
|
||||
<MicrosoftAspNetCoreAnalyzerTestingPackageVersion>5.0.0-preview.3.20156.2</MicrosoftAspNetCoreAnalyzerTestingPackageVersion>
|
||||
<MicrosoftExtensionsCachingAbstractionsPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsCachingAbstractionsPackageVersion>
|
||||
<MicrosoftExtensionsCachingMemoryPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsCachingMemoryPackageVersion>
|
||||
<MicrosoftExtensionsCachingSqlServerPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsCachingSqlServerPackageVersion>
|
||||
<MicrosoftExtensionsCachingStackExchangeRedisPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsCachingStackExchangeRedisPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationAbstractionsPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsConfigurationAbstractionsPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationBinderPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsConfigurationBinderPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationCommandLinePackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsConfigurationCommandLinePackageVersion>
|
||||
<MicrosoftExtensionsConfigurationEnvironmentVariablesPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsConfigurationEnvironmentVariablesPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationFileExtensionsPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsConfigurationFileExtensionsPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationIniPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsConfigurationIniPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationJsonPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsConfigurationJsonPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsConfigurationPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationUserSecretsPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsConfigurationUserSecretsPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationXmlPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsConfigurationXmlPackageVersion>
|
||||
<MicrosoftExtensionsDependencyInjectionAbstractionsPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsDependencyInjectionAbstractionsPackageVersion>
|
||||
<MicrosoftExtensionsDependencyInjectionPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsDependencyInjectionPackageVersion>
|
||||
<MicrosoftExtensionsDiagnosticAdapterPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsDiagnosticAdapterPackageVersion>
|
||||
<MicrosoftExtensionsFileProvidersAbstractionsPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsFileProvidersAbstractionsPackageVersion>
|
||||
<MicrosoftExtensionsFileProvidersCompositePackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsFileProvidersCompositePackageVersion>
|
||||
<MicrosoftExtensionsFileProvidersPhysicalPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsFileProvidersPhysicalPackageVersion>
|
||||
<MicrosoftExtensionsFileSystemGlobbingPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsFileSystemGlobbingPackageVersion>
|
||||
<MicrosoftExtensionsHostingAbstractionsPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsHostingAbstractionsPackageVersion>
|
||||
<MicrosoftExtensionsHostingPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsHostingPackageVersion>
|
||||
<MicrosoftExtensionsHttpPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsHttpPackageVersion>
|
||||
<MicrosoftExtensionsLoggingAbstractionsPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsLoggingAbstractionsPackageVersion>
|
||||
<MicrosoftExtensionsLoggingAzureAppServicesPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsLoggingAzureAppServicesPackageVersion>
|
||||
<MicrosoftExtensionsLoggingConfigurationPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsLoggingConfigurationPackageVersion>
|
||||
<MicrosoftExtensionsLoggingConsolePackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsLoggingConsolePackageVersion>
|
||||
<MicrosoftExtensionsLoggingDebugPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsLoggingDebugPackageVersion>
|
||||
<MicrosoftExtensionsLoggingEventSourcePackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsLoggingEventSourcePackageVersion>
|
||||
<MicrosoftExtensionsLoggingEventLogPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsLoggingEventLogPackageVersion>
|
||||
<MicrosoftExtensionsLoggingPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsLoggingPackageVersion>
|
||||
<MicrosoftExtensionsLoggingTestingPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsLoggingTestingPackageVersion>
|
||||
<MicrosoftExtensionsLoggingTraceSourcePackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsLoggingTraceSourcePackageVersion>
|
||||
<MicrosoftExtensionsOptionsConfigurationExtensionsPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsOptionsConfigurationExtensionsPackageVersion>
|
||||
<MicrosoftExtensionsOptionsDataAnnotationsPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsOptionsDataAnnotationsPackageVersion>
|
||||
<MicrosoftExtensionsOptionsPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsOptionsPackageVersion>
|
||||
<MicrosoftExtensionsPrimitivesPackageVersion>5.0.0-preview.3.20156.2</MicrosoftExtensionsPrimitivesPackageVersion>
|
||||
<MicrosoftInternalExtensionsRefsPackageVersion>5.0.0-preview.3.20156.2</MicrosoftInternalExtensionsRefsPackageVersion>
|
||||
<InternalAspNetCoreAnalyzersPackageVersion>5.0.0-preview.3.20156.3</InternalAspNetCoreAnalyzersPackageVersion>
|
||||
<MicrosoftAspNetCoreAnalyzerTestingPackageVersion>5.0.0-preview.3.20156.3</MicrosoftAspNetCoreAnalyzerTestingPackageVersion>
|
||||
<MicrosoftExtensionsCachingAbstractionsPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsCachingAbstractionsPackageVersion>
|
||||
<MicrosoftExtensionsCachingMemoryPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsCachingMemoryPackageVersion>
|
||||
<MicrosoftExtensionsCachingSqlServerPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsCachingSqlServerPackageVersion>
|
||||
<MicrosoftExtensionsCachingStackExchangeRedisPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsCachingStackExchangeRedisPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationAbstractionsPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsConfigurationAbstractionsPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationAzureKeyVaultPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsConfigurationAzureKeyVaultPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationBinderPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsConfigurationBinderPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationCommandLinePackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsConfigurationCommandLinePackageVersion>
|
||||
<MicrosoftExtensionsConfigurationEnvironmentVariablesPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsConfigurationEnvironmentVariablesPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationFileExtensionsPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsConfigurationFileExtensionsPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationIniPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsConfigurationIniPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationJsonPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsConfigurationJsonPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsConfigurationPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationUserSecretsPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsConfigurationUserSecretsPackageVersion>
|
||||
<MicrosoftExtensionsConfigurationXmlPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsConfigurationXmlPackageVersion>
|
||||
<MicrosoftExtensionsDependencyInjectionAbstractionsPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsDependencyInjectionAbstractionsPackageVersion>
|
||||
<MicrosoftExtensionsDependencyInjectionPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsDependencyInjectionPackageVersion>
|
||||
<MicrosoftExtensionsDiagnosticAdapterPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsDiagnosticAdapterPackageVersion>
|
||||
<MicrosoftExtensionsFileProvidersAbstractionsPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsFileProvidersAbstractionsPackageVersion>
|
||||
<MicrosoftExtensionsFileProvidersCompositePackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsFileProvidersCompositePackageVersion>
|
||||
<MicrosoftExtensionsFileProvidersPhysicalPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsFileProvidersPhysicalPackageVersion>
|
||||
<MicrosoftExtensionsFileSystemGlobbingPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsFileSystemGlobbingPackageVersion>
|
||||
<MicrosoftExtensionsHostingAbstractionsPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsHostingAbstractionsPackageVersion>
|
||||
<MicrosoftExtensionsHostingPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsHostingPackageVersion>
|
||||
<MicrosoftExtensionsHttpPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsHttpPackageVersion>
|
||||
<MicrosoftExtensionsLoggingAbstractionsPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsLoggingAbstractionsPackageVersion>
|
||||
<MicrosoftExtensionsLoggingAzureAppServicesPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsLoggingAzureAppServicesPackageVersion>
|
||||
<MicrosoftExtensionsLoggingConfigurationPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsLoggingConfigurationPackageVersion>
|
||||
<MicrosoftExtensionsLoggingConsolePackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsLoggingConsolePackageVersion>
|
||||
<MicrosoftExtensionsLoggingDebugPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsLoggingDebugPackageVersion>
|
||||
<MicrosoftExtensionsLoggingEventSourcePackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsLoggingEventSourcePackageVersion>
|
||||
<MicrosoftExtensionsLoggingEventLogPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsLoggingEventLogPackageVersion>
|
||||
<MicrosoftExtensionsLoggingPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsLoggingPackageVersion>
|
||||
<MicrosoftExtensionsLoggingTestingPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsLoggingTestingPackageVersion>
|
||||
<MicrosoftExtensionsLoggingTraceSourcePackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsLoggingTraceSourcePackageVersion>
|
||||
<MicrosoftExtensionsOptionsConfigurationExtensionsPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsOptionsConfigurationExtensionsPackageVersion>
|
||||
<MicrosoftExtensionsOptionsDataAnnotationsPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsOptionsDataAnnotationsPackageVersion>
|
||||
<MicrosoftExtensionsOptionsPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsOptionsPackageVersion>
|
||||
<MicrosoftExtensionsPrimitivesPackageVersion>5.0.0-preview.3.20156.3</MicrosoftExtensionsPrimitivesPackageVersion>
|
||||
<MicrosoftInternalExtensionsRefsPackageVersion>5.0.0-preview.3.20156.3</MicrosoftInternalExtensionsRefsPackageVersion>
|
||||
<!-- Packages from dotnet/efcore -->
|
||||
<dotnetefPackageVersion>5.0.0-preview.3.20156.3</dotnetefPackageVersion>
|
||||
<MicrosoftEntityFrameworkCoreInMemoryPackageVersion>5.0.0-preview.3.20156.3</MicrosoftEntityFrameworkCoreInMemoryPackageVersion>
|
||||
|
|
@ -147,10 +148,10 @@
|
|||
<MicrosoftEntityFrameworkCoreToolsPackageVersion>5.0.0-preview.3.20156.3</MicrosoftEntityFrameworkCoreToolsPackageVersion>
|
||||
<MicrosoftEntityFrameworkCorePackageVersion>5.0.0-preview.3.20156.3</MicrosoftEntityFrameworkCorePackageVersion>
|
||||
<!-- Packages from dotnet/aspnetcore-tooling -->
|
||||
<MicrosoftAspNetCoreMvcRazorExtensionsPackageVersion>5.0.0-preview.3.20156.7</MicrosoftAspNetCoreMvcRazorExtensionsPackageVersion>
|
||||
<MicrosoftAspNetCoreRazorLanguagePackageVersion>5.0.0-preview.3.20156.7</MicrosoftAspNetCoreRazorLanguagePackageVersion>
|
||||
<MicrosoftCodeAnalysisRazorPackageVersion>5.0.0-preview.3.20156.7</MicrosoftCodeAnalysisRazorPackageVersion>
|
||||
<MicrosoftNETSdkRazorPackageVersion>5.0.0-preview.3.20156.7</MicrosoftNETSdkRazorPackageVersion>
|
||||
<MicrosoftAspNetCoreMvcRazorExtensionsPackageVersion>5.0.0-preview.3.20157.1</MicrosoftAspNetCoreMvcRazorExtensionsPackageVersion>
|
||||
<MicrosoftAspNetCoreRazorLanguagePackageVersion>5.0.0-preview.3.20157.1</MicrosoftAspNetCoreRazorLanguagePackageVersion>
|
||||
<MicrosoftCodeAnalysisRazorPackageVersion>5.0.0-preview.3.20157.1</MicrosoftCodeAnalysisRazorPackageVersion>
|
||||
<MicrosoftNETSdkRazorPackageVersion>5.0.0-preview.3.20157.1</MicrosoftNETSdkRazorPackageVersion>
|
||||
</PropertyGroup>
|
||||
<!--
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
@echo off
|
||||
REM Disable "!Foo!" expansions because they break the filter syntax
|
||||
setlocal disableextensions
|
||||
REM Need delayed expansion !PATH! so parens in the path don't mess up the parens for the if statements that use parens for blocks
|
||||
setlocal enabledelayedexpansion
|
||||
|
||||
REM Use '$' as a variable name prefix to avoid MSBuild variable collisions with these variables
|
||||
set $target=%1
|
||||
|
|
@ -9,6 +9,7 @@ set $runtimeVersion=%3
|
|||
set $helixQueue=%4
|
||||
set $arch=%5
|
||||
set $quarantined=%6
|
||||
set $efVersion=%7
|
||||
|
||||
set DOTNET_HOME=%HELIX_CORRELATION_PAYLOAD%\sdk
|
||||
set DOTNET_ROOT=%DOTNET_HOME%\%$arch%
|
||||
|
|
@ -16,14 +17,24 @@ set DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
|
|||
set DOTNET_MULTILEVEL_LOOKUP=0
|
||||
set DOTNET_CLI_HOME=%HELIX_CORRELATION_PAYLOAD%\home
|
||||
|
||||
set PATH=%DOTNET_ROOT%;%PATH%;%HELIX_CORRELATION_PAYLOAD%\node\bin
|
||||
|
||||
set PATH=%DOTNET_ROOT%;!PATH!;%HELIX_CORRELATION_PAYLOAD%\node\bin
|
||||
echo Set path to: %PATH%
|
||||
echo "Installing SDK"
|
||||
powershell.exe -NoProfile -ExecutionPolicy unrestricted -Command "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; &([scriptblock]::Create((Invoke-WebRequest -useb 'https://dot.net/v1/dotnet-install.ps1'))) -Architecture %$arch% -Version %$sdkVersion% -InstallDir %DOTNET_ROOT%"
|
||||
echo "Installing Runtime"
|
||||
powershell.exe -NoProfile -ExecutionPolicy unrestricted -Command "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; &([scriptblock]::Create((Invoke-WebRequest -useb 'https://dot.net/v1/dotnet-install.ps1'))) -Architecture %$arch% -Runtime dotnet -Version %$runtimeVersion% -InstallDir %DOTNET_ROOT%"
|
||||
|
||||
echo "Checking for Microsoft.AspNetCore.App"
|
||||
if EXIST ".\Microsoft.AspNetCore.App" (
|
||||
echo "Found Microsoft.AspNetCore.App, copying to %DOTNET_ROOT%\shared\Microsoft.AspNetCore.App\%runtimeVersion%"
|
||||
xcopy /i /y ".\Microsoft.AspNetCore.App" %DOTNET_ROOT%\shared\Microsoft.AspNetCore.App\%runtimeVersion%\
|
||||
|
||||
echo "Adding current directory to nuget sources: %HELIX_WORKITEM_ROOT%"
|
||||
dotnet nuget add source %HELIX_WORKITEM_ROOT%
|
||||
dotnet nuget add source https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet5/nuget/v3/index.json
|
||||
dotnet nuget list source
|
||||
dotnet tool install dotnet-ef --global --version %$efVersion%
|
||||
|
||||
set PATH=!PATH!;%DOTNET_CLI_HOME%\.dotnet\tools
|
||||
)
|
||||
|
||||
echo "Current Directory: %HELIX_WORKITEM_ROOT%"
|
||||
|
|
@ -31,6 +42,8 @@ set HELIX=%$helixQueue%
|
|||
set HELIX_DIR=%HELIX_WORKITEM_ROOT%
|
||||
set NUGET_FALLBACK_PACKAGES=%HELIX_DIR%
|
||||
set NUGET_RESTORE=%HELIX_DIR%\nugetRestore
|
||||
set DotNetEfFullPath=%HELIX_DIR%\nugetRestore\dotnet-ef\%$efVersion%\tools\netcoreapp3.1\any\dotnet-ef.exe
|
||||
echo "Set DotNetEfFullPath: %DotNetEfFullPath%"
|
||||
echo "Setting HELIX_DIR: %HELIX_DIR%"
|
||||
echo Creating nuget restore directory: %NUGET_RESTORE%
|
||||
mkdir %NUGET_RESTORE%
|
||||
|
|
@ -53,6 +66,8 @@ if %$quarantined%==True (
|
|||
set %$quarantined=true
|
||||
)
|
||||
|
||||
REM Disable "!Foo!" expansions because they break the filter syntax
|
||||
setlocal disabledelayedexpansion
|
||||
set NONQUARANTINE_FILTER="Quarantined!=true"
|
||||
set QUARANTINE_FILTER="Quarantined=true"
|
||||
if %$quarantined%==true (
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@ dotnet_runtime_version="$3"
|
|||
helix_queue_name="$4"
|
||||
target_arch="$5"
|
||||
quarantined="$6"
|
||||
efVersion="$7"
|
||||
|
||||
RESET="\033[0m"
|
||||
RED="\033[0;31m"
|
||||
|
|
@ -33,6 +34,8 @@ export DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
|
|||
export helix="$helix_queue_name"
|
||||
export HELIX_DIR="$DIR"
|
||||
export NUGET_FALLBACK_PACKAGES="$DIR"
|
||||
export DotNetEfFullPath=$DIR\nugetRestore\dotnet-ef\$efVersion\tools\netcoreapp3.1\any\dotnet-ef.dll
|
||||
echo "Set DotNetEfFullPath: $DotNetEfFullPath"
|
||||
export NUGET_RESTORE="$DIR/nugetRestore"
|
||||
echo "Creating nugetRestore directory: $NUGET_RESTORE"
|
||||
mkdir $NUGET_RESTORE
|
||||
|
|
@ -95,6 +98,17 @@ if [ -d "Microsoft.AspNetCore.App" ]
|
|||
then
|
||||
echo "Found Microsoft.AspNetCore.App directory, copying to $DOTNET_ROOT/shared/Microsoft.AspNetCore.App/$dotnet_runtime_version."
|
||||
cp -r Microsoft.AspNetCore.App $DOTNET_ROOT/shared/Microsoft.AspNetCore.App/$dotnet_runtime_version
|
||||
|
||||
echo "Adding current directory to nuget sources: $DIR"
|
||||
dotnet nuget add source $DIR
|
||||
dotnet nuget add source https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet5/nuget/v3/index.json
|
||||
dotnet nuget list source
|
||||
|
||||
dotnet tool install dotnet-ef --global --version $efVersion
|
||||
|
||||
# Ensure tools are on on PATH
|
||||
export PATH="$PATH:$DOTNET_CLI_HOME/.dotnet/tools"
|
||||
|
||||
fi
|
||||
|
||||
if [ -e /proc/self/coredump_filter ]; then
|
||||
|
|
|
|||
|
|
@ -27,6 +27,8 @@
|
|||
<Reference Include="Moq" />
|
||||
</ItemGroup>
|
||||
|
||||
<Import Project="$(RepoRoot)src\Testing\src\build\Microsoft.AspNetCore.Testing.props" Condition=" '$(IsTestProject)' == 'true' " />
|
||||
|
||||
<ItemDefinitionGroup Condition=" '$(IsTestProject)' == 'true' ">
|
||||
<Content>
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
|
|
|
|||
|
|
@ -120,8 +120,8 @@ Usage: dotnet msbuild /t:Helix src/MyTestProject.csproj
|
|||
<TestAssembly>$(TargetFileName)</TestAssembly>
|
||||
<PreCommands>@(HelixPreCommand)</PreCommands>
|
||||
<PostCommands>@(HelixPostCommand)</PostCommands>
|
||||
<Command Condition="$(IsWindowsHelixQueue)">call runtests.cmd $(TargetFileName) $(NETCoreSdkVersion) $(MicrosoftNETCoreAppRuntimeVersion) $(_HelixFriendlyNameTargetQueue) $(TargetArchitecture) $(RunQuarantinedTests)</Command>
|
||||
<Command Condition="!$(IsWindowsHelixQueue)">./runtests.sh $(TargetFileName) $(NETCoreSdkVersion) $(MicrosoftNETCoreAppRuntimeVersion) $(_HelixFriendlyNameTargetQueue) $(TargetArchitecture) $(RunQuarantinedTests)</Command>
|
||||
<Command Condition="$(IsWindowsHelixQueue)">call runtests.cmd $(TargetFileName) $(NETCoreSdkVersion) $(MicrosoftNETCoreAppRuntimeVersion) $(_HelixFriendlyNameTargetQueue) $(TargetArchitecture) $(RunQuarantinedTests) $(DotnetEfPackageVersion)</Command>
|
||||
<Command Condition="!$(IsWindowsHelixQueue)">./runtests.sh $(TargetFileName) $(NETCoreSdkVersion) $(MicrosoftNETCoreAppRuntimeVersion) $(_HelixFriendlyNameTargetQueue) $(TargetArchitecture) $(RunQuarantinedTests) $(DotnetEfPackageVersion)</Command>
|
||||
<Command Condition="$(HelixCommand) != ''">$(HelixCommand)</Command>
|
||||
<Timeout>$(HelixTimeout)</Timeout>
|
||||
</HelixWorkItem>
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@
|
|||
<Reference Include="Microsoft.AspNetCore.Antiforgery" />
|
||||
<Reference Include="Microsoft.AspNetCore.Http" />
|
||||
<Reference Include="Microsoft.Extensions.DependencyInjection" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="Microsoft.Extensions.Logging" />
|
||||
<Reference Include="Microsoft.Extensions.WebEncoders" />
|
||||
</ItemGroup>
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
|
||||
<ItemGroup>
|
||||
<Reference Include="Microsoft.AspNetCore.Mvc.Testing" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
|
||||
<Target Name="PublishAssets" AfterTargets="Publish">
|
||||
|
|
|
|||
|
|
@ -6,7 +6,6 @@
|
|||
|
||||
<ItemGroup>
|
||||
<Reference Include="Microsoft.AspNetCore.Components.Server" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
|
||||
<PropertyGroup>
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
|
|
@ -33,7 +33,6 @@
|
|||
<Reference Include="Microsoft.AspNetCore.Hosting" />
|
||||
<Reference Include="Microsoft.AspNetCore.Server.Kestrel" />
|
||||
<Reference Include="Microsoft.AspNetCore.StaticFiles" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="Ignitor" />
|
||||
</ItemGroup>
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>$(DefaultNetCoreTargetFramework)</TargetFramework>
|
||||
|
||||
|
|
@ -26,6 +25,5 @@
|
|||
<ProjectReference Include="$(RepoRoot)src\DefaultBuilder\testassets\StartWithIApplicationBuilderUrlApp\StartWithIApplicationBuilderUrlApp.csproj" ReferenceOutputAssemblies="false" />
|
||||
|
||||
<Reference Include="Microsoft.AspNetCore" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@
|
|||
<Reference Include="Microsoft.Extensions.Diagnostics.HealthChecks.Abstractions" />
|
||||
<Reference Include="Microsoft.Extensions.Hosting.Abstractions" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Abstractions" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="Microsoft.Extensions.Logging" />
|
||||
<Reference Include="Microsoft.Extensions.Options" />
|
||||
<Reference Include="Microsoft.Extensions.Primitives" />
|
||||
|
|
|
|||
|
|
@ -20,7 +20,6 @@
|
|||
<Reference Include="Microsoft.AspNetCore.Owin" />
|
||||
<Reference Include="Microsoft.AspNetCore.Hosting" />
|
||||
<Reference Include="Microsoft.Extensions.Hosting" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="Microsoft.Extensions.Options" />
|
||||
<Reference Include="System.Threading.Channels" />
|
||||
</ItemGroup>
|
||||
|
|
|
|||
|
|
@ -21,7 +21,6 @@
|
|||
|
||||
<Reference Include="Microsoft.AspNetCore.Hosting" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Console" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -11,7 +11,6 @@
|
|||
<Reference Include="Microsoft.Extensions.DependencyInjection" />
|
||||
<Reference Include="Microsoft.AspNetCore.Routing" />
|
||||
<Reference Include="Microsoft.Extensions.Logging" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="Microsoft.Extensions.WebEncoders" />
|
||||
</ItemGroup>
|
||||
|
||||
|
|
|
|||
|
|
@ -25,7 +25,6 @@
|
|||
<ProjectReference Include="..\..\testassets\Identity.DefaultUI.WebSite\Identity.DefaultUI.WebSite.csproj" />
|
||||
|
||||
<Reference Include="Microsoft.AspNetCore.Mvc.Testing" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="Microsoft.EntityFrameworkCore.Sqlite" />
|
||||
<Reference Include="AngleSharp" />
|
||||
</ItemGroup>
|
||||
|
|
|
|||
|
|
@ -13,7 +13,6 @@
|
|||
<Reference Include="Microsoft.Extensions.Localization.Abstractions" />
|
||||
<Reference Include="Microsoft.Extensions.Localization" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Abstractions" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="Microsoft.Extensions.Options" />
|
||||
</ItemGroup>
|
||||
|
||||
|
|
|
|||
|
|
@ -10,7 +10,6 @@
|
|||
<Reference Include="Microsoft.Extensions.DependencyInjection.Abstractions" />
|
||||
<Reference Include="Microsoft.Extensions.DependencyInjection" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Abstractions" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="Microsoft.Extensions.Logging" />
|
||||
<Reference Include="Microsoft.Extensions.Options" />
|
||||
<Reference Include="Microsoft.Extensions.Primitives" />
|
||||
|
|
|
|||
|
|
@ -11,7 +11,6 @@
|
|||
<ItemGroup>
|
||||
<Reference Include="Microsoft.AspNetCore.Cors" />
|
||||
<Reference Include="Microsoft.AspNetCore.TestHost" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@
|
|||
<ItemGroup>
|
||||
<Reference Include="Microsoft.AspNetCore.Diagnostics.HealthChecks" />
|
||||
<Reference Include="Microsoft.AspNetCore.TestHost" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -7,7 +7,6 @@
|
|||
<ItemGroup>
|
||||
<Reference Include="Microsoft.AspNetCore.HttpOverrides" />
|
||||
<Reference Include="Microsoft.AspNetCore.TestHost" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Content Include="$(SharedSourceRoot)test\Certificates\*.cer" CopyToOutputDirectory="PreserveNewest" CopyToPublishDirectory="PreserveNewest" />
|
||||
</ItemGroup>
|
||||
|
||||
|
|
|
|||
|
|
@ -6,7 +6,6 @@
|
|||
|
||||
<ItemGroup>
|
||||
<Reference Include="Microsoft.AspNetCore.HttpsPolicy" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="Microsoft.AspNetCore.TestHost" />
|
||||
</ItemGroup>
|
||||
|
||||
|
|
|
|||
|
|
@ -9,7 +9,6 @@
|
|||
<Reference Include="Microsoft.AspNetCore.TestHost" />
|
||||
<Reference Include="Microsoft.Extensions.DependencyInjection" />
|
||||
<Reference Include="Microsoft.Extensions.Logging" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@
|
|||
<ItemGroup>
|
||||
<Reference Include="Microsoft.AspNetCore.NodeServices" />
|
||||
<Reference Include="Microsoft.AspNetCore.TestHost" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Content Include="js\**\*" />
|
||||
</ItemGroup>
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>$(DefaultNetCoreTargetFramework)</TargetFramework>
|
||||
</PropertyGroup>
|
||||
|
|
@ -14,7 +13,6 @@
|
|||
<ItemGroup>
|
||||
<Reference Include="Microsoft.AspNetCore.ResponseCaching" />
|
||||
<Reference Include="Microsoft.AspNetCore.TestHost" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@
|
|||
<Reference Include="Microsoft.AspNetCore.Http" />
|
||||
<Reference Include="Microsoft.AspNetCore.ResponseCompression" />
|
||||
<Reference Include="Microsoft.AspNetCore.TestHost" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="Microsoft.Net.Http.Headers" />
|
||||
</ItemGroup>
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@
|
|||
<Reference Include="Microsoft.AspNetCore.Session" />
|
||||
<Reference Include="Microsoft.AspNetCore.TestHost" />
|
||||
<Reference Include="Microsoft.Extensions.Caching.Memory" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -14,7 +14,6 @@
|
|||
<Reference Include="Microsoft.AspNetCore.TestHost" />
|
||||
<Reference Include="Microsoft.Extensions.DiagnosticAdapter" />
|
||||
<Reference Include="Microsoft.Extensions.Hosting" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Content Include="js\**\*" />
|
||||
</ItemGroup>
|
||||
|
||||
|
|
|
|||
|
|
@ -12,6 +12,7 @@ using Microsoft.AspNetCore.Hosting;
|
|||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.AspNetCore.Server.IntegrationTesting;
|
||||
using Microsoft.AspNetCore.Server.IntegrationTesting.Common;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.Extensions.FileProviders;
|
||||
using Microsoft.Extensions.Logging.Testing;
|
||||
|
|
|
|||
|
|
@ -29,7 +29,6 @@
|
|||
<Reference Include="Microsoft.AspNetCore.StaticFiles" />
|
||||
<Reference Include="Microsoft.AspNetCore.Server.HttpSys" />
|
||||
<Reference Include="Microsoft.AspNetCore.Server.Kestrel" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -9,7 +9,6 @@
|
|||
|
||||
<Reference Include="Microsoft.AspNetCore.Server.Kestrel" />
|
||||
<Reference Include="Microsoft.AspNetCore.WebSockets" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -33,7 +33,6 @@
|
|||
<Reference Include="Microsoft.Extensions.Configuration.UserSecrets" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Abstractions" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Console" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="Microsoft.Extensions.Logging" />
|
||||
|
||||
<Compile Include="$(SharedSourceRoot)CommandLineUtils\**\*.cs" />
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@
|
|||
|
||||
<ItemGroup>
|
||||
<Reference Include="Microsoft.AspNetCore.Authentication.Core" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -12,6 +12,7 @@ using System.Threading.Tasks;
|
|||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.AspNetCore.Mvc.ModelBinding;
|
||||
using Microsoft.Extensions.Logging.Testing;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
using Microsoft.AspNetCore.WebUtilities;
|
||||
using Newtonsoft.Json;
|
||||
using Moq;
|
||||
|
|
|
|||
|
|
@ -15,6 +15,5 @@
|
|||
<ProjectReference Include="..\..\shared\Mvc.TestDiagnosticListener\Microsoft.AspNetCore.Mvc.TestDiagnosticListener.csproj" />
|
||||
|
||||
<Reference Include="Microsoft.AspNetCore.ResponseCaching" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -7,7 +7,5 @@
|
|||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\shared\Mvc.Core.TestCommon\Microsoft.AspNetCore.Mvc.Core.TestCommon.csproj" />
|
||||
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -6,8 +6,6 @@
|
|||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\shared\Mvc.Core.TestCommon\Microsoft.AspNetCore.Mvc.Core.TestCommon.csproj" />
|
||||
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@
|
|||
<Reference Include="Microsoft.AspNetCore.Mvc" />
|
||||
<Reference Include="Microsoft.AspNetCore.Mvc.NewtonsoftJson" />
|
||||
<ProjectReference Include="..\..\shared\Mvc.Core.TestCommon\Microsoft.AspNetCore.Mvc.Core.TestCommon.csproj" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
|
|
|||
|
|
@ -15,8 +15,6 @@
|
|||
<Reference Include="Microsoft.AspNetCore.Mvc" />
|
||||
<ProjectReference Include="..\..\shared\Mvc.Views.TestCommon\Microsoft.AspNetCore.Mvc.Views.TestCommon.csproj" />
|
||||
<ProjectReference Include="..\..\shared\Mvc.TestDiagnosticListener\Microsoft.AspNetCore.Mvc.TestDiagnosticListener.csproj" />
|
||||
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -12,8 +12,6 @@
|
|||
<Reference Include="Microsoft.AspNetCore.Mvc.RazorPages" />
|
||||
<ProjectReference Include="..\..\shared\Mvc.Views.TestCommon\Microsoft.AspNetCore.Mvc.Views.TestCommon.csproj" />
|
||||
<ProjectReference Include="..\..\shared\Mvc.TestDiagnosticListener\Microsoft.AspNetCore.Mvc.TestDiagnosticListener.csproj" />
|
||||
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -12,6 +12,7 @@ using System.Threading.Tasks;
|
|||
using Microsoft.AspNetCore.Hosting;
|
||||
using Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation;
|
||||
using Microsoft.AspNetCore.TestHost;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using Microsoft.Extensions.Logging.Testing;
|
||||
|
|
|
|||
|
|
@ -12,6 +12,7 @@ using HtmlGenerationWebSite;
|
|||
using Microsoft.AspNetCore.Hosting;
|
||||
using Microsoft.AspNetCore.Mvc.Testing;
|
||||
using Microsoft.AspNetCore.TestHost;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.Extensions.Logging.Testing;
|
||||
using Xunit;
|
||||
|
|
|
|||
|
|
@ -59,6 +59,5 @@
|
|||
<Reference Include="Microsoft.AspNetCore.Routing.Abstractions" />
|
||||
<Reference Include="Microsoft.AspNetCore.Routing" />
|
||||
<Reference Include="Microsoft.AspNetCore.TestHost" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ using System.Diagnostics;
|
|||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.Extensions.CommandLineUtils;
|
||||
|
|
@ -28,12 +29,11 @@ namespace Templates.Test.Helpers
|
|||
? GetAssemblyMetadata("ArtifactsLogDir")
|
||||
: Path.Combine(Environment.GetEnvironmentVariable("HELIX_DIR"), "logs");
|
||||
|
||||
// FIGURE OUT EF PATH
|
||||
public static string DotNetEfFullPath => (string.IsNullOrEmpty(Environment.GetEnvironmentVariable("helix")))
|
||||
public static string DotNetEfFullPath => (string.IsNullOrEmpty(Environment.GetEnvironmentVariable("DotNetEfFullPath")))
|
||||
? typeof(ProjectFactoryFixture).Assembly.GetCustomAttributes<AssemblyMetadataAttribute>()
|
||||
.First(attribute => attribute.Key == "DotNetEfFullPath")
|
||||
.Value
|
||||
: Path.Combine("NuGetPackageRoot", "dotnet-ef/$(DotnetEfPackageVersion)/tools/netcoreapp3.1/any/dotnet-ef.dll");
|
||||
: Environment.GetEnvironmentVariable("DotNetEfFullPath");
|
||||
|
||||
public SemaphoreSlim DotNetNewLock { get; set; }
|
||||
public SemaphoreSlim NodeLock { get; set; }
|
||||
|
|
@ -306,14 +306,24 @@ namespace Templates.Test.Helpers
|
|||
|
||||
internal async Task<ProcessEx> RunDotNetEfCreateMigrationAsync(string migrationName)
|
||||
{
|
||||
var args = $"\"{DotNetEfFullPath}\" --verbose --no-build migrations add {migrationName}";
|
||||
|
||||
var args = $"--verbose --no-build migrations add {migrationName}";
|
||||
|
||||
// Only run one instance of 'dotnet new' at once, as a workaround for
|
||||
// https://github.com/aspnet/templating/issues/63
|
||||
await DotNetNewLock.WaitAsync();
|
||||
try
|
||||
{
|
||||
var result = ProcessEx.Run(Output, TemplateOutputDir, DotNetMuxer.MuxerPathOrDefault(), args);
|
||||
var command = DotNetMuxer.MuxerPathOrDefault();
|
||||
if (string.IsNullOrEmpty(Environment.GetEnvironmentVariable("DotNetEfFullPath")))
|
||||
{
|
||||
args = $"\"{DotNetEfFullPath}\" " + args;
|
||||
}
|
||||
else
|
||||
{
|
||||
command = "dotnet-ef";
|
||||
}
|
||||
|
||||
var result = ProcessEx.Run(Output, TemplateOutputDir, command, args);
|
||||
await result.Exited;
|
||||
return result;
|
||||
}
|
||||
|
|
@ -325,14 +335,24 @@ namespace Templates.Test.Helpers
|
|||
|
||||
internal async Task<ProcessEx> RunDotNetEfUpdateDatabaseAsync()
|
||||
{
|
||||
var args = $"\"{DotNetEfFullPath}\" --verbose --no-build database update";
|
||||
var args = "--verbose --no-build database update";
|
||||
|
||||
// Only run one instance of 'dotnet new' at once, as a workaround for
|
||||
// https://github.com/aspnet/templating/issues/63
|
||||
await DotNetNewLock.WaitAsync();
|
||||
try
|
||||
{
|
||||
var result = ProcessEx.Run(Output, TemplateOutputDir, DotNetMuxer.MuxerPathOrDefault(), args);
|
||||
var command = DotNetMuxer.MuxerPathOrDefault();
|
||||
if (string.IsNullOrEmpty(Environment.GetEnvironmentVariable("DotNetEfFullPath")))
|
||||
{
|
||||
args = $"\"{DotNetEfFullPath}\" " + args;
|
||||
}
|
||||
else
|
||||
{
|
||||
command = "dotnet-ef";
|
||||
}
|
||||
|
||||
var result = ProcessEx.Run(Output, TemplateOutputDir, command, args);
|
||||
await result.Exited;
|
||||
return result;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -120,7 +120,7 @@ namespace Templates.Test
|
|||
|
||||
[ConditionalTheory]
|
||||
[MemberData(nameof(MSBuildIdentityUIPackageOptions))]
|
||||
[SkipOnHelix("ef restore no worky")]
|
||||
[SkipOnHelix("cert failure", Queues = "OSX.1014.Amd64;OSX.1014.Amd64.Open")]
|
||||
public async Task IdentityUIPackage_WorksWithDifferentOptions(IDictionary<string, string> packageOptions, string versionValidator, string[] expectedFiles)
|
||||
{
|
||||
Project = await ProjectFactory.GetOrCreateProject("identityuipackage" + string.Concat(packageOptions.Values), Output);
|
||||
|
|
|
|||
|
|
@ -3,12 +3,12 @@
|
|||
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Threading.Tasks;
|
||||
using Templates.Test.Helpers;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
using Templates.Test.Helpers;
|
||||
using Xunit;
|
||||
using Xunit.Abstractions;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
|
||||
namespace Templates.Test
|
||||
{
|
||||
|
|
@ -107,7 +107,7 @@ namespace Templates.Test
|
|||
[ConditionalTheory]
|
||||
[InlineData(true)]
|
||||
[InlineData(false)]
|
||||
[SkipOnHelix("ef restore no worky")]
|
||||
[SkipOnHelix("cert failure", Queues = "OSX.1014.Amd64;OSX.1014.Amd64.Open")]
|
||||
public async Task MvcTemplate_IndividualAuth(bool useLocalDB)
|
||||
{
|
||||
Project = await ProjectFactory.GetOrCreateProject("mvcindividual" + (useLocalDB ? "uld" : ""), Output);
|
||||
|
|
@ -222,8 +222,7 @@ namespace Templates.Test
|
|||
}
|
||||
}
|
||||
|
||||
[ConditionalFact]
|
||||
[SkipOnHelix("razor compilation restore no worky")]
|
||||
[Fact]
|
||||
public async Task MvcTemplate_RazorRuntimeCompilation_BuildsAndPublishes()
|
||||
{
|
||||
Project = await ProjectFactory.GetOrCreateProject("mvc_rc", Output);
|
||||
|
|
|
|||
|
|
@ -5,7 +5,6 @@ using System.Threading.Tasks;
|
|||
using Templates.Test.Helpers;
|
||||
using Xunit;
|
||||
using Xunit.Abstractions;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
|
||||
namespace Templates.Test
|
||||
{
|
||||
|
|
@ -41,8 +40,7 @@ namespace Templates.Test
|
|||
Assert.True(0 == buildResult.ExitCode, ErrorMessages.GetFailedProcessMessage("build", Project, buildResult));
|
||||
}
|
||||
|
||||
[ConditionalFact]
|
||||
[SkipOnHelix("restore no worky")]
|
||||
[Fact]
|
||||
public async Task RazorClassLibraryTemplateAsync()
|
||||
{
|
||||
Project = await ProjectFactory.GetOrCreateProject("razorclasslib", Output);
|
||||
|
|
|
|||
|
|
@ -97,7 +97,7 @@ namespace Templates.Test
|
|||
[ConditionalTheory]
|
||||
[InlineData(false)]
|
||||
[InlineData(true)]
|
||||
[SkipOnHelix("ef restore no worky")]
|
||||
[SkipOnHelix("cert failure", Queues = "OSX.1014.Amd64;OSX.1014.Amd64.Open")]
|
||||
public async Task RazorPagesTemplate_IndividualAuth(bool useLocalDB)
|
||||
{
|
||||
Project = await ProjectFactory.GetOrCreateProject("razorpagesindividual" + (useLocalDB ? "uld" : ""), Output);
|
||||
|
|
@ -212,8 +212,7 @@ namespace Templates.Test
|
|||
}
|
||||
}
|
||||
|
||||
[ConditionalFact]
|
||||
[SkipOnHelix("runtime compliation restore no worky")]
|
||||
[Fact]
|
||||
public async Task RazorPagesTemplate_RazorRuntimeCompilation_BuildsAndPublishes()
|
||||
{
|
||||
Project = await ProjectFactory.GetOrCreateProject("razorpages_rc", Output);
|
||||
|
|
|
|||
|
|
@ -21,8 +21,7 @@ namespace Templates.Test
|
|||
public ProjectFactoryFixture ProjectFactory { get; }
|
||||
public ITestOutputHelper Output { get; }
|
||||
|
||||
[ConditionalFact]
|
||||
[SkipOnHelix("restore no worky")]
|
||||
[Fact]
|
||||
public async Task WorkerTemplateAsync()
|
||||
{
|
||||
Project = await ProjectFactory.GetOrCreateProject("worker", Output);
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@ using System.IO;
|
|||
using System.Threading.Tasks;
|
||||
using Microsoft.AspNetCore.Server.IIS.FunctionalTests;
|
||||
using Microsoft.AspNetCore.Server.IntegrationTesting.IIS;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
using Microsoft.Extensions.Logging.Testing;
|
||||
using Xunit.Abstractions;
|
||||
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@ using System.Collections.Generic;
|
|||
using System.Net.Http;
|
||||
using Microsoft.AspNetCore.Server.IntegrationTesting;
|
||||
using Microsoft.AspNetCore.Server.IntegrationTesting.IIS;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using Microsoft.Extensions.Logging.Testing;
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>$(DefaultNetCoreTargetFramework)</TargetFramework>
|
||||
<TestGroupName>IIS.FunctionalTests</TestGroupName>
|
||||
|
|
@ -24,7 +23,6 @@
|
|||
|
||||
<ItemGroup>
|
||||
<Reference Include="Microsoft.AspNetCore.Hosting" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="Microsoft.Extensions.Logging" />
|
||||
<Reference Include="System.Diagnostics.EventLog" />
|
||||
</ItemGroup>
|
||||
|
|
|
|||
|
|
@ -30,7 +30,6 @@
|
|||
|
||||
<ItemGroup>
|
||||
<Reference Include="Microsoft.AspNetCore.Hosting" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="Microsoft.Extensions.Logging" />
|
||||
<Reference Include="System.Diagnostics.EventLog" />
|
||||
<Reference Include="System.Net.WebSockets.WebSocketProtocol" />
|
||||
|
|
|
|||
|
|
@ -26,7 +26,6 @@
|
|||
<ItemGroup>
|
||||
<Reference Include="Microsoft.AspNetCore.Hosting" />
|
||||
<Reference Include="Microsoft.Extensions.Logging" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="System.Diagnostics.EventLog" />
|
||||
</ItemGroup>
|
||||
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@
|
|||
<ItemGroup>
|
||||
<Reference Include="Microsoft.AspNetCore.Hosting" />
|
||||
<Reference Include="Microsoft.AspNetCore.Server.IIS" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="Microsoft.Extensions.Logging" />
|
||||
<Reference Include="System.Diagnostics.EventLog" />
|
||||
</ItemGroup>
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
|
||||
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using Microsoft.Extensions.Logging.Testing;
|
||||
using Xunit;
|
||||
|
|
|
|||
|
|
@ -28,7 +28,6 @@
|
|||
<ItemGroup>
|
||||
<Reference Include="Microsoft.AspNetCore.Hosting" />
|
||||
<Reference Include="Microsoft.Extensions.Logging" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="System.Diagnostics.EventLog" />
|
||||
</ItemGroup>
|
||||
|
||||
|
|
|
|||
|
|
@ -93,7 +93,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Infrastructure
|
|||
|
||||
Walk(connection =>
|
||||
{
|
||||
connection.GetTransport().Abort(new ConnectionAbortedException(CoreStrings.ConnectionAbortedDuringServerShutdown));
|
||||
connection.TransportConnection.Abort(new ConnectionAbortedException(CoreStrings.ConnectionAbortedDuringServerShutdown));
|
||||
abortTasks.Add(connection.ExecutionTask);
|
||||
});
|
||||
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Infrastructure
|
|||
public ConnectionReference(KestrelConnection connection)
|
||||
{
|
||||
_weakReference = new WeakReference<KestrelConnection>(connection);
|
||||
ConnectionId = connection.GetTransport().ConnectionId;
|
||||
ConnectionId = connection.TransportConnection.ConnectionId;
|
||||
}
|
||||
|
||||
public string ConnectionId { get; }
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Infrastructure
|
|||
}
|
||||
}
|
||||
|
||||
public abstract BaseConnectionContext GetTransport();
|
||||
public abstract BaseConnectionContext TransportConnection { get; }
|
||||
|
||||
public void OnHeartbeat(Action<object> action, object state)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -10,8 +10,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Infrastructure
|
|||
internal class KestrelConnection<T> : KestrelConnection, IThreadPoolWorkItem where T : BaseConnectionContext
|
||||
{
|
||||
private readonly Func<T, Task> _connectionDelegate;
|
||||
|
||||
public T TransportConnection { get; set; }
|
||||
private readonly T _transportConnection;
|
||||
|
||||
public KestrelConnection(long id,
|
||||
ServiceContext serviceContext,
|
||||
|
|
@ -21,12 +20,14 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Infrastructure
|
|||
: base(id, serviceContext, logger)
|
||||
{
|
||||
_connectionDelegate = connectionDelegate;
|
||||
TransportConnection = connectionContext;
|
||||
_transportConnection = connectionContext;
|
||||
connectionContext.Features.Set<IConnectionHeartbeatFeature>(this);
|
||||
connectionContext.Features.Set<IConnectionCompleteFeature>(this);
|
||||
connectionContext.Features.Set<IConnectionLifetimeNotificationFeature>(this);
|
||||
}
|
||||
|
||||
public override BaseConnectionContext TransportConnection => _transportConnection;
|
||||
|
||||
void IThreadPoolWorkItem.Execute()
|
||||
{
|
||||
_ = ExecuteAsync();
|
||||
|
|
@ -34,7 +35,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Infrastructure
|
|||
|
||||
internal async Task ExecuteAsync()
|
||||
{
|
||||
var connectionContext = TransportConnection;
|
||||
var connectionContext = _transportConnection;
|
||||
|
||||
try
|
||||
{
|
||||
|
|
@ -63,15 +64,10 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Infrastructure
|
|||
// Dispose the transport connection, this needs to happen before removing it from the
|
||||
// connection manager so that we only signal completion of this connection after the transport
|
||||
// is properly torn down.
|
||||
await TransportConnection.DisposeAsync();
|
||||
await connectionContext.DisposeAsync();
|
||||
|
||||
_serviceContext.ConnectionManager.RemoveConnection(_id);
|
||||
}
|
||||
}
|
||||
|
||||
public override BaseConnectionContext GetTransport()
|
||||
{
|
||||
return TransportConnection;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -81,7 +81,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Tests
|
|||
connection.ConnectionClosed = new CancellationToken(canceled: true);
|
||||
var kestrelConnection = new KestrelConnection<ConnectionContext>(0, serviceContext, _ => Task.CompletedTask, connection, serviceContext.Log);
|
||||
serviceContext.ConnectionManager.AddConnection(0, kestrelConnection);
|
||||
var completeFeature = kestrelConnection.GetTransport().Features.Get<IConnectionCompleteFeature>();
|
||||
var completeFeature = kestrelConnection.TransportConnection.Features.Get<IConnectionCompleteFeature>();
|
||||
|
||||
Assert.NotNull(completeFeature);
|
||||
object stateObject = new object();
|
||||
|
|
@ -102,7 +102,7 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Tests
|
|||
connection.ConnectionClosed = new CancellationToken(canceled: true);
|
||||
var kestrelConnection = new KestrelConnection<ConnectionContext>(0, serviceContext, _ => Task.CompletedTask, connection, serviceContext.Log);
|
||||
serviceContext.ConnectionManager.AddConnection(0, kestrelConnection);
|
||||
var completeFeature = kestrelConnection.GetTransport().Features.Get<IConnectionCompleteFeature>();
|
||||
var completeFeature = kestrelConnection.TransportConnection.Features.Get<IConnectionCompleteFeature>();
|
||||
|
||||
Assert.NotNull(completeFeature);
|
||||
object stateObject = new object();
|
||||
|
|
|
|||
|
|
@ -18,7 +18,6 @@
|
|||
<ProjectReference Include="$(RepoRoot)src\Servers\IIS\IntegrationTesting.IIS\src\Microsoft.AspNetCore.Server.IntegrationTesting.IIS.csproj" />
|
||||
<ProjectReference Include="$(RepoRoot)src\Servers\testassets\ServerComparison.TestSites\ServerComparison.TestSites.csproj" ReferenceOutputAssemblies="false" />
|
||||
<Reference Include="Microsoft.Extensions.Logging" />
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="Microsoft.Net.Http.Headers" />
|
||||
<Reference Include="Serilog.Extensions.Logging" />
|
||||
<Reference Include="Serilog.Sinks.File" />
|
||||
|
|
|
|||
|
|
@ -10,6 +10,7 @@ using System.Threading;
|
|||
using System.Threading.Tasks;
|
||||
using Microsoft.AspNetCore.Hosting;
|
||||
using Microsoft.AspNetCore.Hosting.Server.Features;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.Extensions.Hosting;
|
||||
using Microsoft.Extensions.Logging;
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
|
||||
|
||||
using System;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
using Microsoft.Extensions.Logging.Abstractions;
|
||||
using Microsoft.Extensions.Logging.Testing;
|
||||
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@
|
|||
using System;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.AspNetCore.SignalR.Tests;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using Microsoft.Extensions.Logging.Testing;
|
||||
using Xunit;
|
||||
|
|
|
|||
|
|
@ -0,0 +1,307 @@
|
|||
// Licensed to the .NET Foundation under one or more agreements.
|
||||
// The .NET Foundation licenses this file to you under the MIT license.
|
||||
// See the LICENSE file in the project root for more information.
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Text;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using Serilog;
|
||||
using Serilog.Core;
|
||||
using Serilog.Events;
|
||||
using Serilog.Extensions.Logging;
|
||||
using Xunit.Abstractions;
|
||||
using ILogger = Microsoft.Extensions.Logging.ILogger;
|
||||
|
||||
namespace Microsoft.AspNetCore.Testing
|
||||
{
|
||||
public class AssemblyTestLog : IDisposable
|
||||
{
|
||||
private static readonly string MaxPathLengthEnvironmentVariableName = "ASPNETCORE_TEST_LOG_MAXPATH";
|
||||
private static readonly string LogFileExtension = ".log";
|
||||
private static readonly int MaxPathLength = GetMaxPathLength();
|
||||
|
||||
private static readonly object _lock = new object();
|
||||
private static readonly Dictionary<Assembly, AssemblyTestLog> _logs = new Dictionary<Assembly, AssemblyTestLog>();
|
||||
|
||||
private readonly ILoggerFactory _globalLoggerFactory;
|
||||
private readonly ILogger _globalLogger;
|
||||
private readonly string _baseDirectory;
|
||||
private readonly Assembly _assembly;
|
||||
private readonly IServiceProvider _serviceProvider;
|
||||
|
||||
private static int GetMaxPathLength()
|
||||
{
|
||||
var maxPathString = Environment.GetEnvironmentVariable(MaxPathLengthEnvironmentVariableName);
|
||||
var defaultMaxPath = 245;
|
||||
return string.IsNullOrEmpty(maxPathString) ? defaultMaxPath : int.Parse(maxPathString);
|
||||
}
|
||||
|
||||
private AssemblyTestLog(ILoggerFactory globalLoggerFactory, ILogger globalLogger, string baseDirectory, Assembly assembly, IServiceProvider serviceProvider)
|
||||
{
|
||||
_globalLoggerFactory = globalLoggerFactory;
|
||||
_globalLogger = globalLogger;
|
||||
_baseDirectory = baseDirectory;
|
||||
_assembly = assembly;
|
||||
_serviceProvider = serviceProvider;
|
||||
}
|
||||
|
||||
public IDisposable StartTestLog(ITestOutputHelper output, string className, out ILoggerFactory loggerFactory, [CallerMemberName] string testName = null) =>
|
||||
StartTestLog(output, className, out loggerFactory, LogLevel.Debug, testName);
|
||||
|
||||
public IDisposable StartTestLog(ITestOutputHelper output, string className, out ILoggerFactory loggerFactory, LogLevel minLogLevel, [CallerMemberName] string testName = null) =>
|
||||
StartTestLog(output, className, out loggerFactory, minLogLevel, out var _, out var _, testName);
|
||||
|
||||
internal IDisposable StartTestLog(ITestOutputHelper output, string className, out ILoggerFactory loggerFactory, LogLevel minLogLevel, out string resolvedTestName, out string logOutputDirectory, [CallerMemberName] string testName = null)
|
||||
{
|
||||
var logStart = DateTimeOffset.UtcNow;
|
||||
var serviceProvider = CreateLoggerServices(output, className, minLogLevel, out resolvedTestName, out logOutputDirectory, testName, logStart);
|
||||
var factory = serviceProvider.GetRequiredService<ILoggerFactory>();
|
||||
loggerFactory = factory;
|
||||
var logger = loggerFactory.CreateLogger("TestLifetime");
|
||||
|
||||
var stopwatch = Stopwatch.StartNew();
|
||||
|
||||
var scope = logger.BeginScope("Test: {testName}", testName);
|
||||
|
||||
_globalLogger.LogInformation("Starting test {testName}", testName);
|
||||
logger.LogInformation("Starting test {testName} at {logStart}", testName, logStart.ToString("s"));
|
||||
|
||||
return new Disposable(() =>
|
||||
{
|
||||
stopwatch.Stop();
|
||||
_globalLogger.LogInformation("Finished test {testName} in {duration}s", testName, stopwatch.Elapsed.TotalSeconds);
|
||||
logger.LogInformation("Finished test {testName} in {duration}s", testName, stopwatch.Elapsed.TotalSeconds);
|
||||
scope.Dispose();
|
||||
factory.Dispose();
|
||||
(serviceProvider as IDisposable)?.Dispose();
|
||||
});
|
||||
}
|
||||
|
||||
public ILoggerFactory CreateLoggerFactory(ITestOutputHelper output, string className, [CallerMemberName] string testName = null, DateTimeOffset? logStart = null)
|
||||
=> CreateLoggerFactory(output, className, LogLevel.Trace, testName, logStart);
|
||||
|
||||
public ILoggerFactory CreateLoggerFactory(ITestOutputHelper output, string className, LogLevel minLogLevel, [CallerMemberName] string testName = null, DateTimeOffset? logStart = null)
|
||||
=> CreateLoggerServices(output, className, minLogLevel, out var _, out var _, testName, logStart).GetRequiredService<ILoggerFactory>();
|
||||
|
||||
public IServiceProvider CreateLoggerServices(ITestOutputHelper output, string className, LogLevel minLogLevel, out string normalizedTestName, [CallerMemberName] string testName = null, DateTimeOffset? logStart = null)
|
||||
=> CreateLoggerServices(output, className, minLogLevel, out normalizedTestName, out var _, testName, logStart);
|
||||
|
||||
public IServiceProvider CreateLoggerServices(ITestOutputHelper output, string className, LogLevel minLogLevel, out string normalizedTestName, out string logOutputDirectory, [CallerMemberName] string testName = null, DateTimeOffset? logStart = null)
|
||||
{
|
||||
normalizedTestName = string.Empty;
|
||||
logOutputDirectory = string.Empty;
|
||||
var assemblyName = _assembly.GetName().Name;
|
||||
|
||||
// Try to shorten the class name using the assembly name
|
||||
if (className.StartsWith(assemblyName + "."))
|
||||
{
|
||||
className = className.Substring(assemblyName.Length + 1);
|
||||
}
|
||||
|
||||
SerilogLoggerProvider serilogLoggerProvider = null;
|
||||
if (!string.IsNullOrEmpty(_baseDirectory))
|
||||
{
|
||||
logOutputDirectory = Path.Combine(_baseDirectory, className);
|
||||
testName = TestFileOutputContext.RemoveIllegalFileChars(testName);
|
||||
|
||||
if (logOutputDirectory.Length + testName.Length + LogFileExtension.Length >= MaxPathLength)
|
||||
{
|
||||
_globalLogger.LogWarning($"Test name {testName} is too long. Please shorten test name.");
|
||||
|
||||
// Shorten the test name by removing the middle portion of the testname
|
||||
var testNameLength = MaxPathLength - logOutputDirectory.Length - LogFileExtension.Length;
|
||||
|
||||
if (testNameLength <= 0)
|
||||
{
|
||||
throw new InvalidOperationException("Output file path could not be constructed due to max path length restrictions. Please shorten test assembly, class or method names.");
|
||||
}
|
||||
|
||||
testName = testName.Substring(0, testNameLength / 2) + testName.Substring(testName.Length - testNameLength / 2, testNameLength / 2);
|
||||
|
||||
_globalLogger.LogWarning($"To prevent long paths test name was shortened to {testName}.");
|
||||
}
|
||||
|
||||
var testOutputFile = Path.Combine(logOutputDirectory, $"{testName}{LogFileExtension}");
|
||||
|
||||
if (File.Exists(testOutputFile))
|
||||
{
|
||||
_globalLogger.LogWarning($"Output log file {testOutputFile} already exists. Please try to keep log file names unique.");
|
||||
|
||||
for (var i = 0; i < 1000; i++)
|
||||
{
|
||||
testOutputFile = Path.Combine(logOutputDirectory, $"{testName}.{i}{LogFileExtension}");
|
||||
|
||||
if (!File.Exists(testOutputFile))
|
||||
{
|
||||
_globalLogger.LogWarning($"To resolve log file collision, the enumerated file {testOutputFile} will be used.");
|
||||
testName = $"{testName}.{i}";
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
normalizedTestName = testName;
|
||||
serilogLoggerProvider = ConfigureFileLogging(testOutputFile, logStart);
|
||||
}
|
||||
|
||||
var serviceCollection = new ServiceCollection();
|
||||
serviceCollection.AddLogging(builder =>
|
||||
{
|
||||
builder.SetMinimumLevel(minLogLevel);
|
||||
|
||||
if (output != null)
|
||||
{
|
||||
builder.AddXunit(output, minLogLevel, logStart);
|
||||
}
|
||||
|
||||
if (serilogLoggerProvider != null)
|
||||
{
|
||||
// Use a factory so that the container will dispose it
|
||||
builder.Services.AddSingleton<ILoggerProvider>(_ => serilogLoggerProvider);
|
||||
}
|
||||
});
|
||||
|
||||
return serviceCollection.BuildServiceProvider();
|
||||
}
|
||||
|
||||
// For back compat
|
||||
public static AssemblyTestLog Create(string assemblyName, string baseDirectory)
|
||||
=> Create(Assembly.Load(new AssemblyName(assemblyName)), baseDirectory);
|
||||
|
||||
public static AssemblyTestLog Create(Assembly assembly, string baseDirectory)
|
||||
{
|
||||
var logStart = DateTimeOffset.UtcNow;
|
||||
SerilogLoggerProvider serilogLoggerProvider = null;
|
||||
if (!string.IsNullOrEmpty(baseDirectory))
|
||||
{
|
||||
baseDirectory = TestFileOutputContext.GetAssemblyBaseDirectory(assembly, baseDirectory);
|
||||
var globalLogFileName = Path.Combine(baseDirectory, "global.log");
|
||||
serilogLoggerProvider = ConfigureFileLogging(globalLogFileName, logStart);
|
||||
}
|
||||
|
||||
var serviceCollection = new ServiceCollection();
|
||||
|
||||
serviceCollection.AddLogging(builder =>
|
||||
{
|
||||
// Global logging, when it's written, is expected to be outputted. So set the log level to minimum.
|
||||
builder.SetMinimumLevel(LogLevel.Trace);
|
||||
|
||||
if (serilogLoggerProvider != null)
|
||||
{
|
||||
// Use a factory so that the container will dispose it
|
||||
builder.Services.AddSingleton<ILoggerProvider>(_ => serilogLoggerProvider);
|
||||
}
|
||||
});
|
||||
|
||||
var serviceProvider = serviceCollection.BuildServiceProvider();
|
||||
var loggerFactory = serviceProvider.GetRequiredService<ILoggerFactory>();
|
||||
|
||||
var logger = loggerFactory.CreateLogger("GlobalTestLog");
|
||||
logger.LogInformation("Global Test Logging initialized at {logStart}. "
|
||||
+ "Configure the output directory via 'LoggingTestingFileLoggingDirectory' MSBuild property "
|
||||
+ "or set 'LoggingTestingDisableFileLogging' to 'true' to disable file logging.",
|
||||
logStart.ToString("s"));
|
||||
return new AssemblyTestLog(loggerFactory, logger, baseDirectory, assembly, serviceProvider);
|
||||
}
|
||||
|
||||
public static AssemblyTestLog ForAssembly(Assembly assembly)
|
||||
{
|
||||
lock (_lock)
|
||||
{
|
||||
if (!_logs.TryGetValue(assembly, out var log))
|
||||
{
|
||||
var baseDirectory = TestFileOutputContext.GetOutputDirectory(assembly);
|
||||
|
||||
log = Create(assembly, baseDirectory);
|
||||
_logs[assembly] = log;
|
||||
|
||||
// Try to clear previous logs, continue if it fails.
|
||||
var assemblyBaseDirectory = TestFileOutputContext.GetAssemblyBaseDirectory(assembly);
|
||||
if (!string.IsNullOrEmpty(assemblyBaseDirectory) && !TestFileOutputContext.GetPreserveExistingLogsInOutput(assembly))
|
||||
{
|
||||
try
|
||||
{
|
||||
Directory.Delete(assemblyBaseDirectory, recursive: true);
|
||||
}
|
||||
catch { }
|
||||
}
|
||||
}
|
||||
return log;
|
||||
}
|
||||
}
|
||||
|
||||
private static TestFrameworkFileLoggerAttribute GetFileLoggerAttribute(Assembly assembly)
|
||||
=> assembly.GetCustomAttribute<TestFrameworkFileLoggerAttribute>()
|
||||
?? throw new InvalidOperationException($"No {nameof(TestFrameworkFileLoggerAttribute)} found on the assembly {assembly.GetName().Name}. "
|
||||
+ "The attribute is added via msbuild properties of the Microsoft.Extensions.Logging.Testing. "
|
||||
+ "Please ensure the msbuild property is imported or a direct reference to Microsoft.Extensions.Logging.Testing is added.");
|
||||
|
||||
private static SerilogLoggerProvider ConfigureFileLogging(string fileName, DateTimeOffset? logStart)
|
||||
{
|
||||
var dir = Path.GetDirectoryName(fileName);
|
||||
if (!Directory.Exists(dir))
|
||||
{
|
||||
Directory.CreateDirectory(dir);
|
||||
}
|
||||
|
||||
if (File.Exists(fileName))
|
||||
{
|
||||
File.Delete(fileName);
|
||||
}
|
||||
|
||||
var serilogger = new LoggerConfiguration()
|
||||
.Enrich.FromLogContext()
|
||||
.Enrich.With(new AssemblyLogTimestampOffsetEnricher(logStart))
|
||||
.MinimumLevel.Verbose()
|
||||
.WriteTo.File(fileName, outputTemplate: "[{TimestampOffset}] [{SourceContext}] [{Level}] {Message:l}{NewLine}{Exception}", flushToDiskInterval: TimeSpan.FromSeconds(1), shared: true)
|
||||
.CreateLogger();
|
||||
return new SerilogLoggerProvider(serilogger, dispose: true);
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
(_serviceProvider as IDisposable)?.Dispose();
|
||||
_globalLoggerFactory.Dispose();
|
||||
}
|
||||
|
||||
private class AssemblyLogTimestampOffsetEnricher : ILogEventEnricher
|
||||
{
|
||||
private DateTimeOffset? _logStart;
|
||||
|
||||
public AssemblyLogTimestampOffsetEnricher(DateTimeOffset? logStart)
|
||||
{
|
||||
_logStart = logStart;
|
||||
}
|
||||
|
||||
public void Enrich(LogEvent logEvent, ILogEventPropertyFactory propertyFactory)
|
||||
=> logEvent.AddPropertyIfAbsent(
|
||||
propertyFactory.CreateProperty(
|
||||
"TimestampOffset",
|
||||
_logStart.HasValue
|
||||
? $"{(DateTimeOffset.UtcNow - _logStart.Value).TotalSeconds.ToString("N3")}s"
|
||||
: DateTimeOffset.UtcNow.ToString("s")));
|
||||
}
|
||||
|
||||
private class Disposable : IDisposable
|
||||
{
|
||||
private Action _action;
|
||||
|
||||
public Disposable(Action action)
|
||||
{
|
||||
_action = action;
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
_action();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,39 @@
|
|||
// Licensed to the .NET Foundation under one or more agreements.
|
||||
// The .NET Foundation licenses this file to you under the MIT license.
|
||||
// See the LICENSE file in the project root for more information.
|
||||
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Microsoft.AspNetCore.Testing
|
||||
{
|
||||
/// <summary>
|
||||
/// Capture the memory dump upon test failure.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// This currently only works in Windows environments
|
||||
/// </remarks>
|
||||
[AttributeUsage(AttributeTargets.Method, AllowMultiple = false)]
|
||||
public class CollectDumpAttribute : Attribute, ITestMethodLifecycle
|
||||
{
|
||||
public Task OnTestStartAsync(TestContext context, CancellationToken cancellationToken)
|
||||
{
|
||||
return Task.CompletedTask;
|
||||
}
|
||||
|
||||
public Task OnTestEndAsync(TestContext context, Exception exception, CancellationToken cancellationToken)
|
||||
{
|
||||
if (exception != null)
|
||||
{
|
||||
var path = Path.Combine(context.FileOutput.TestClassOutputDirectory, context.FileOutput.GetUniqueFileName(context.FileOutput.TestName, ".dmp"));
|
||||
var process = Process.GetCurrentProcess();
|
||||
DumpCollector.Collect(process, path);
|
||||
}
|
||||
|
||||
return Task.CompletedTask;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,77 @@
|
|||
// Licensed to the .NET Foundation under one or more agreements.
|
||||
// The .NET Foundation licenses this file to you under the MIT license.
|
||||
// See the LICENSE file in the project root for more information.
|
||||
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
using System.Runtime.InteropServices;
|
||||
using Microsoft.Win32.SafeHandles;
|
||||
|
||||
namespace Microsoft.AspNetCore.Testing
|
||||
{
|
||||
public static partial class DumpCollector
|
||||
{
|
||||
private static class Windows
|
||||
{
|
||||
internal static void Collect(Process process, string outputFile)
|
||||
{
|
||||
// Open the file for writing
|
||||
using (var stream = new FileStream(outputFile, FileMode.Create, FileAccess.ReadWrite, FileShare.None))
|
||||
{
|
||||
// Dump the process!
|
||||
var exceptionInfo = new NativeMethods.MINIDUMP_EXCEPTION_INFORMATION();
|
||||
if (!NativeMethods.MiniDumpWriteDump(process.Handle, (uint)process.Id, stream.SafeFileHandle, NativeMethods.MINIDUMP_TYPE.MiniDumpWithFullMemory, ref exceptionInfo, IntPtr.Zero, IntPtr.Zero))
|
||||
{
|
||||
var err = Marshal.GetHRForLastWin32Error();
|
||||
Marshal.ThrowExceptionForHR(err);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private static class NativeMethods
|
||||
{
|
||||
[DllImport("Dbghelp.dll")]
|
||||
public static extern bool MiniDumpWriteDump(IntPtr hProcess, uint ProcessId, SafeFileHandle hFile, MINIDUMP_TYPE DumpType, ref MINIDUMP_EXCEPTION_INFORMATION ExceptionParam, IntPtr UserStreamParam, IntPtr CallbackParam);
|
||||
|
||||
[StructLayout(LayoutKind.Sequential, Pack = 4)]
|
||||
public struct MINIDUMP_EXCEPTION_INFORMATION
|
||||
{
|
||||
public uint ThreadId;
|
||||
public IntPtr ExceptionPointers;
|
||||
public int ClientPointers;
|
||||
}
|
||||
|
||||
[Flags]
|
||||
public enum MINIDUMP_TYPE : uint
|
||||
{
|
||||
MiniDumpNormal = 0,
|
||||
MiniDumpWithDataSegs = 1 << 0,
|
||||
MiniDumpWithFullMemory = 1 << 1,
|
||||
MiniDumpWithHandleData = 1 << 2,
|
||||
MiniDumpFilterMemory = 1 << 3,
|
||||
MiniDumpScanMemory = 1 << 4,
|
||||
MiniDumpWithUnloadedModules = 1 << 5,
|
||||
MiniDumpWithIndirectlyReferencedMemory = 1 << 6,
|
||||
MiniDumpFilterModulePaths = 1 << 7,
|
||||
MiniDumpWithProcessThreadData = 1 << 8,
|
||||
MiniDumpWithPrivateReadWriteMemory = 1 << 9,
|
||||
MiniDumpWithoutOptionalData = 1 << 10,
|
||||
MiniDumpWithFullMemoryInfo = 1 << 11,
|
||||
MiniDumpWithThreadInfo = 1 << 12,
|
||||
MiniDumpWithCodeSegs = 1 << 13,
|
||||
MiniDumpWithoutAuxiliaryState = 1 << 14,
|
||||
MiniDumpWithFullAuxiliaryState = 1 << 15,
|
||||
MiniDumpWithPrivateWriteCopyMemory = 1 << 16,
|
||||
MiniDumpIgnoreInaccessibleMemory = 1 << 17,
|
||||
MiniDumpWithTokenInformation = 1 << 18,
|
||||
MiniDumpWithModuleHeaders = 1 << 19,
|
||||
MiniDumpFilterTriage = 1 << 20,
|
||||
MiniDumpWithAvxXStateContext = 1 << 21,
|
||||
MiniDumpWithIptTrace = 1 << 22,
|
||||
MiniDumpValidTypeFlags = (-1) ^ ((~1) << 22)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
// Licensed to the .NET Foundation under one or more agreements.
|
||||
// The .NET Foundation licenses this file to you under the MIT license.
|
||||
// See the LICENSE file in the project root for more information.
|
||||
|
||||
using System.Diagnostics;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace Microsoft.AspNetCore.Testing
|
||||
{
|
||||
public static partial class DumpCollector
|
||||
{
|
||||
public static void Collect(Process process, string fileName)
|
||||
{
|
||||
if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
|
||||
{
|
||||
Windows.Collect(process, fileName);
|
||||
}
|
||||
// No implementations yet for macOS and Linux
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,26 @@
|
|||
// Licensed to the .NET Foundation under one or more agreements.
|
||||
// The .NET Foundation licenses this file to you under the MIT license.
|
||||
// See the LICENSE file in the project root for more information.
|
||||
|
||||
using System;
|
||||
using System.Reflection;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using Xunit.Abstractions;
|
||||
|
||||
namespace Microsoft.AspNetCore.Testing
|
||||
{
|
||||
public interface ILoggedTest : IDisposable
|
||||
{
|
||||
ILogger Logger { get; }
|
||||
|
||||
ILoggerFactory LoggerFactory { get; }
|
||||
|
||||
ITestOutputHelper TestOutputHelper { get; }
|
||||
|
||||
// For back compat
|
||||
IDisposable StartLog(out ILoggerFactory loggerFactory, LogLevel minLogLevel, string testName);
|
||||
|
||||
void Initialize(TestContext context, MethodInfo methodInfo, object[] testMethodArguments, ITestOutputHelper testOutputHelper);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
// Licensed to the .NET Foundation under one or more agreements.
|
||||
// The .NET Foundation licenses this file to you under the MIT license.
|
||||
// See the LICENSE file in the project root for more information.
|
||||
|
||||
using System.Reflection;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using Microsoft.Extensions.Logging.Testing;
|
||||
using Xunit.Abstractions;
|
||||
|
||||
namespace Microsoft.AspNetCore.Testing
|
||||
{
|
||||
public class LoggedTest : LoggedTestBase
|
||||
{
|
||||
// Obsolete but keeping for back compat
|
||||
public LoggedTest(ITestOutputHelper output = null) : base (output) { }
|
||||
|
||||
public ITestSink TestSink { get; set; }
|
||||
|
||||
public override void Initialize(TestContext context, MethodInfo methodInfo, object[] testMethodArguments, ITestOutputHelper testOutputHelper)
|
||||
{
|
||||
base.Initialize(context, methodInfo, testMethodArguments, testOutputHelper);
|
||||
|
||||
TestSink = new TestSink();
|
||||
LoggerFactory.AddProvider(new TestLoggerProvider(TestSink));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,124 @@
|
|||
// Licensed to the .NET Foundation under one or more agreements.
|
||||
// The .NET Foundation licenses this file to you under the MIT license.
|
||||
// See the LICENSE file in the project root for more information.
|
||||
|
||||
using System;
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.ExceptionServices;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using Microsoft.Extensions.Logging.Testing;
|
||||
using Serilog;
|
||||
using Xunit.Abstractions;
|
||||
|
||||
namespace Microsoft.AspNetCore.Testing
|
||||
{
|
||||
public class LoggedTestBase : ILoggedTest, ITestMethodLifecycle
|
||||
{
|
||||
private ExceptionDispatchInfo _initializationException;
|
||||
|
||||
private IDisposable _testLog;
|
||||
|
||||
// Obsolete but keeping for back compat
|
||||
public LoggedTestBase(ITestOutputHelper output = null)
|
||||
{
|
||||
TestOutputHelper = output;
|
||||
}
|
||||
|
||||
protected TestContext Context { get; private set; }
|
||||
|
||||
// Internal for testing
|
||||
internal string ResolvedTestClassName { get; set; }
|
||||
|
||||
public string ResolvedLogOutputDirectory { get; set; }
|
||||
|
||||
public string ResolvedTestMethodName { get; set; }
|
||||
|
||||
public Microsoft.Extensions.Logging.ILogger Logger { get; set; }
|
||||
|
||||
public ILoggerFactory LoggerFactory { get; set; }
|
||||
|
||||
public ITestOutputHelper TestOutputHelper { get; set; }
|
||||
|
||||
public void AddTestLogging(IServiceCollection services) => services.AddSingleton(LoggerFactory);
|
||||
|
||||
// For back compat
|
||||
public IDisposable StartLog(out ILoggerFactory loggerFactory, [CallerMemberName] string testName = null) => StartLog(out loggerFactory, LogLevel.Debug, testName);
|
||||
|
||||
// For back compat
|
||||
public IDisposable StartLog(out ILoggerFactory loggerFactory, LogLevel minLogLevel, [CallerMemberName] string testName = null)
|
||||
{
|
||||
return AssemblyTestLog.ForAssembly(GetType().GetTypeInfo().Assembly).StartTestLog(TestOutputHelper, GetType().FullName, out loggerFactory, minLogLevel, testName);
|
||||
}
|
||||
|
||||
public virtual void Initialize(TestContext context, MethodInfo methodInfo, object[] testMethodArguments, ITestOutputHelper testOutputHelper)
|
||||
{
|
||||
try
|
||||
{
|
||||
TestOutputHelper = testOutputHelper;
|
||||
|
||||
var classType = GetType();
|
||||
var logLevelAttribute = methodInfo.GetCustomAttribute<LogLevelAttribute>()
|
||||
?? methodInfo.DeclaringType.GetCustomAttribute<LogLevelAttribute>()
|
||||
?? methodInfo.DeclaringType.Assembly.GetCustomAttribute<LogLevelAttribute>();
|
||||
|
||||
// internal for testing
|
||||
ResolvedTestClassName = context.FileOutput.TestClassName;
|
||||
|
||||
_testLog = AssemblyTestLog
|
||||
.ForAssembly(classType.GetTypeInfo().Assembly)
|
||||
.StartTestLog(
|
||||
TestOutputHelper,
|
||||
context.FileOutput.TestClassName,
|
||||
out var loggerFactory,
|
||||
logLevelAttribute?.LogLevel ?? LogLevel.Debug,
|
||||
out var resolvedTestName,
|
||||
out var logDirectory,
|
||||
context.FileOutput.TestName);
|
||||
|
||||
ResolvedLogOutputDirectory = logDirectory;
|
||||
ResolvedTestMethodName = resolvedTestName;
|
||||
|
||||
LoggerFactory = loggerFactory;
|
||||
Logger = loggerFactory.CreateLogger(classType);
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
_initializationException = ExceptionDispatchInfo.Capture(e);
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void Dispose()
|
||||
{
|
||||
if (_testLog == null)
|
||||
{
|
||||
// It seems like sometimes the MSBuild goop that adds the test framework can end up in a bad state and not actually add it
|
||||
// Not sure yet why that happens but the exception isn't clear so I'm adding this error so we can detect it better.
|
||||
// -anurse
|
||||
throw new InvalidOperationException("LoggedTest base class was used but nothing initialized it! The test framework may not be enabled. Try cleaning your 'obj' directory.");
|
||||
}
|
||||
|
||||
_initializationException?.Throw();
|
||||
_testLog.Dispose();
|
||||
}
|
||||
|
||||
Task ITestMethodLifecycle.OnTestStartAsync(TestContext context, CancellationToken cancellationToken)
|
||||
{
|
||||
|
||||
Context = context;
|
||||
|
||||
Initialize(context, context.TestMethod, context.MethodArguments, context.Output);
|
||||
return Task.CompletedTask;
|
||||
}
|
||||
|
||||
Task ITestMethodLifecycle.OnTestEndAsync(TestContext context, Exception exception, CancellationToken cancellationToken)
|
||||
{
|
||||
return Task.CompletedTask;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
<PropertyGroup>
|
||||
<Description>Various helpers for writing tests that use ASP.NET Core.</Description>
|
||||
<TargetFrameworks>netstandard2.0;net46</TargetFrameworks>
|
||||
<TargetFrameworks>netstandard2.0;net461</TargetFrameworks>
|
||||
<NoWarn>$(NoWarn);CS1591</NoWarn>
|
||||
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
||||
<PackageTags>aspnetcore</PackageTags>
|
||||
|
|
@ -19,7 +19,10 @@
|
|||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Reference Include="Microsoft.Extensions.Logging.Testing" />
|
||||
<Reference Include="Microsoft.Win32.Registry" />
|
||||
<Reference Include="Serilog.Extensions.Logging" />
|
||||
<Reference Include="Serilog.Sinks.File" />
|
||||
<Reference Include="System.ValueTuple" />
|
||||
|
||||
<!--
|
||||
|
|
@ -34,7 +37,7 @@
|
|||
<Reference Include="xunit.extensibility.execution" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup Condition="'$(TargetFramework)' == 'net46'">
|
||||
<ItemGroup Condition="'$(TargetFramework)' == 'net461'">
|
||||
<Reference Include="System.Net.Http" />
|
||||
<Reference Include="System.Runtime.InteropServices.RuntimeInformation" />
|
||||
</ItemGroup>
|
||||
|
|
|
|||
|
|
@ -0,0 +1,17 @@
|
|||
// Licensed to the .NET Foundation under one or more agreements.
|
||||
// The .NET Foundation licenses this file to you under the MIT license.
|
||||
// See the LICENSE file in the project root for more information.
|
||||
|
||||
using System;
|
||||
|
||||
namespace Microsoft.AspNetCore.Testing
|
||||
{
|
||||
[AttributeUsage(AttributeTargets.Assembly, AllowMultiple = false)]
|
||||
public class TestFrameworkFileLoggerAttribute : TestOutputDirectoryAttribute
|
||||
{
|
||||
public TestFrameworkFileLoggerAttribute(string preserveExistingLogsInOutput, string tfm, string baseDirectory = null)
|
||||
: base(preserveExistingLogsInOutput, tfm, baseDirectory)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,30 @@
|
|||
<Project>
|
||||
<PropertyGroup>
|
||||
<!-- Priority: LoggingTestingDisableFileLogging > LoggingTestingFileLoggingDirectory > ASPNETCORE_TEST_LOG_DIR > Default location -->
|
||||
<RepoRoot Condition="'$(RepoRoot)' == ''">$(RepositoryRoot)</RepoRoot>
|
||||
<LoggingTestingFileLoggingDirectory Condition="'$(LoggingTestingFileLoggingDirectory)' == ''">$(ASPNETCORE_TEST_LOG_DIR)</LoggingTestingFileLoggingDirectory>
|
||||
<LoggingTestingFileLoggingDirectory Condition="'$(LoggingTestingFileLoggingDirectory)' == '' AND '$(RepoRoot)' != ''">$(RepoRoot)artifacts\log\</LoggingTestingFileLoggingDirectory>
|
||||
</PropertyGroup>
|
||||
|
||||
<Target Name="SetLoggingTestingAssemblyAttributes"
|
||||
BeforeTargets="GetAssemblyAttributes"
|
||||
Condition="'$(GenerateLoggingTestingAssemblyAttributes)' != 'false'">
|
||||
<PropertyGroup>
|
||||
<PreserveExistingLogsInOutput Condition="'$(PreserveExistingLogsInOutput)' == '' AND '$(ContinuousIntegrationBuild)' == 'true'">true</PreserveExistingLogsInOutput>
|
||||
<PreserveExistingLogsInOutput Condition="'$(PreserveExistingLogsInOutput)' == ''">false</PreserveExistingLogsInOutput>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<AssemblyAttribute Include="Xunit.TestFramework">
|
||||
<_Parameter1>Microsoft.AspNetCore.Testing.AspNetTestFramework</_Parameter1>
|
||||
<_Parameter2>Microsoft.AspNetCore.Testing</_Parameter2>
|
||||
</AssemblyAttribute>
|
||||
|
||||
<AssemblyAttribute Include="Microsoft.AspNetCore.Testing.TestFrameworkFileLoggerAttribute">
|
||||
<_Parameter1>$(PreserveExistingLogsInOutput)</_Parameter1>
|
||||
<_Parameter2>$(TargetFramework)</_Parameter2>
|
||||
<_Parameter3 Condition="'$(LoggingTestingDisableFileLogging)' != 'true'">$(LoggingTestingFileLoggingDirectory)</_Parameter3>
|
||||
</AssemblyAttribute>
|
||||
</ItemGroup>
|
||||
</Target>
|
||||
</Project>
|
||||
|
|
@ -0,0 +1,221 @@
|
|||
// Licensed to the .NET Foundation under one or more agreements.
|
||||
// The .NET Foundation licenses this file to you under the MIT license.
|
||||
// See the LICENSE file in the project root for more information.
|
||||
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Text.RegularExpressions;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
using Xunit;
|
||||
|
||||
namespace Microsoft.Extensions.Logging.Testing.Tests
|
||||
{
|
||||
public class AssemblyTestLogTests : LoggedTest
|
||||
{
|
||||
private static readonly Assembly ThisAssembly = typeof(AssemblyTestLogTests).GetTypeInfo().Assembly;
|
||||
private static readonly string ThisAssemblyName = ThisAssembly.GetName().Name;
|
||||
private static readonly string TFM = ThisAssembly.GetCustomAttributes().OfType<TestOutputDirectoryAttribute>().FirstOrDefault().TargetFramework;
|
||||
|
||||
[Fact]
|
||||
public void FunctionalLogs_LogsPreservedFromNonQuarantinedTest()
|
||||
{
|
||||
}
|
||||
|
||||
[Fact]
|
||||
[QuarantinedTest]
|
||||
public void FunctionalLogs_LogsPreservedFromQuarantinedTest()
|
||||
{
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void ForAssembly_ReturnsSameInstanceForSameAssembly()
|
||||
{
|
||||
Assert.Same(
|
||||
AssemblyTestLog.ForAssembly(ThisAssembly),
|
||||
AssemblyTestLog.ForAssembly(ThisAssembly));
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void TestLogWritesToITestOutputHelper()
|
||||
{
|
||||
var output = new TestTestOutputHelper();
|
||||
var assemblyLog = AssemblyTestLog.Create(ThisAssemblyName, baseDirectory: null);
|
||||
|
||||
using (assemblyLog.StartTestLog(output, "NonExistant.Test.Class", out var loggerFactory))
|
||||
{
|
||||
var logger = loggerFactory.CreateLogger("TestLogger");
|
||||
logger.LogInformation("Information!");
|
||||
|
||||
// Trace is disabled by default
|
||||
logger.LogTrace("Trace!");
|
||||
}
|
||||
|
||||
var testLogContent = MakeConsistent(output.Output);
|
||||
|
||||
Assert.Equal(
|
||||
@"[OFFSET] TestLifetime Information: Starting test TestLogWritesToITestOutputHelper at TIMESTAMP
|
||||
[OFFSET] TestLogger Information: Information!
|
||||
[OFFSET] TestLifetime Information: Finished test TestLogWritesToITestOutputHelper in DURATION
|
||||
", testLogContent, ignoreLineEndingDifferences: true);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public Task TestLogEscapesIllegalFileNames() =>
|
||||
RunTestLogFunctionalTest((tempDir) =>
|
||||
{
|
||||
var illegalTestName = "T:e/s//t";
|
||||
var escapedTestName = "T_e_s_t";
|
||||
using (var testAssemblyLog = AssemblyTestLog.Create(ThisAssemblyName, baseDirectory: tempDir))
|
||||
using (testAssemblyLog.StartTestLog(output: null, className: "FakeTestAssembly.FakeTestClass", loggerFactory: out var testLoggerFactory, minLogLevel: LogLevel.Trace, resolvedTestName: out var resolvedTestname, out var _, testName: illegalTestName))
|
||||
{
|
||||
Assert.Equal(escapedTestName, resolvedTestname);
|
||||
}
|
||||
});
|
||||
|
||||
[Fact]
|
||||
public Task TestLogWritesToGlobalLogFile() =>
|
||||
RunTestLogFunctionalTest((tempDir) =>
|
||||
{
|
||||
// Because this test writes to a file, it is a functional test and should be logged
|
||||
// but it's also testing the test logging facility. So this is pretty meta ;)
|
||||
var logger = LoggerFactory.CreateLogger("Test");
|
||||
|
||||
using (var testAssemblyLog = AssemblyTestLog.Create(ThisAssemblyName, tempDir))
|
||||
{
|
||||
logger.LogInformation("Created test log in {baseDirectory}", tempDir);
|
||||
|
||||
using (testAssemblyLog.StartTestLog(output: null, className: $"{ThisAssemblyName}.FakeTestClass", loggerFactory: out var testLoggerFactory, minLogLevel: LogLevel.Trace, testName: "FakeTestName"))
|
||||
{
|
||||
var testLogger = testLoggerFactory.CreateLogger("TestLogger");
|
||||
testLogger.LogInformation("Information!");
|
||||
testLogger.LogTrace("Trace!");
|
||||
}
|
||||
}
|
||||
|
||||
logger.LogInformation("Finished test log in {baseDirectory}", tempDir);
|
||||
|
||||
var globalLogPath = Path.Combine(tempDir, ThisAssemblyName, TFM, "global.log");
|
||||
var testLog = Path.Combine(tempDir, ThisAssemblyName, TFM, "FakeTestClass", "FakeTestName.log");
|
||||
|
||||
Assert.True(File.Exists(globalLogPath), $"Expected global log file {globalLogPath} to exist");
|
||||
Assert.True(File.Exists(testLog), $"Expected test log file {testLog} to exist");
|
||||
|
||||
var globalLogContent = MakeConsistent(File.ReadAllText(globalLogPath));
|
||||
var testLogContent = MakeConsistent(File.ReadAllText(testLog));
|
||||
|
||||
Assert.Equal(
|
||||
@"[OFFSET] [GlobalTestLog] [Information] Global Test Logging initialized at TIMESTAMP. Configure the output directory via 'LoggingTestingFileLoggingDirectory' MSBuild property or set 'LoggingTestingDisableFileLogging' to 'true' to disable file logging.
|
||||
[OFFSET] [GlobalTestLog] [Information] Starting test FakeTestName
|
||||
[OFFSET] [GlobalTestLog] [Information] Finished test FakeTestName in DURATION
|
||||
", globalLogContent, ignoreLineEndingDifferences: true);
|
||||
Assert.Equal(
|
||||
@"[OFFSET] [TestLifetime] [Information] Starting test FakeTestName at TIMESTAMP
|
||||
[OFFSET] [TestLogger] [Information] Information!
|
||||
[OFFSET] [TestLogger] [Verbose] Trace!
|
||||
[OFFSET] [TestLifetime] [Information] Finished test FakeTestName in DURATION
|
||||
", testLogContent, ignoreLineEndingDifferences: true);
|
||||
});
|
||||
|
||||
[Fact]
|
||||
public Task TestLogTruncatesTestNameToAvoidLongPaths() =>
|
||||
RunTestLogFunctionalTest((tempDir) =>
|
||||
{
|
||||
var longTestName = new string('0', 50) + new string('1', 50) + new string('2', 50) + new string('3', 50) + new string('4', 50);
|
||||
var logger = LoggerFactory.CreateLogger("Test");
|
||||
using (var testAssemblyLog = AssemblyTestLog.Create(ThisAssemblyName, tempDir))
|
||||
{
|
||||
logger.LogInformation("Created test log in {baseDirectory}", tempDir);
|
||||
|
||||
using (testAssemblyLog.StartTestLog(output: null, className: $"{ThisAssemblyName}.FakeTestClass", loggerFactory: out var testLoggerFactory, minLogLevel: LogLevel.Trace, testName: longTestName))
|
||||
{
|
||||
testLoggerFactory.CreateLogger("TestLogger").LogInformation("Information!");
|
||||
}
|
||||
}
|
||||
logger.LogInformation("Finished test log in {baseDirectory}", tempDir);
|
||||
|
||||
var testLogFiles = new DirectoryInfo(Path.Combine(tempDir, ThisAssemblyName, TFM, "FakeTestClass")).EnumerateFiles();
|
||||
var testLog = Assert.Single(testLogFiles);
|
||||
var testFileName = Path.GetFileNameWithoutExtension(testLog.Name);
|
||||
|
||||
// The first half of the file comes from the beginning of the test name passed to the logger
|
||||
Assert.Equal(longTestName.Substring(0, testFileName.Length / 2), testFileName.Substring(0, testFileName.Length / 2));
|
||||
// The last half of the file comes from the ending of the test name passed to the logger
|
||||
Assert.Equal(longTestName.Substring(longTestName.Length - testFileName.Length / 2, testFileName.Length / 2), testFileName.Substring(testFileName.Length - testFileName.Length / 2, testFileName.Length / 2));
|
||||
});
|
||||
|
||||
[Fact]
|
||||
public Task TestLogEnumerateFilenamesToAvoidCollisions() =>
|
||||
RunTestLogFunctionalTest((tempDir) =>
|
||||
{
|
||||
var logger = LoggerFactory.CreateLogger("Test");
|
||||
using (var testAssemblyLog = AssemblyTestLog.Create(ThisAssemblyName, tempDir))
|
||||
{
|
||||
logger.LogInformation("Created test log in {baseDirectory}", tempDir);
|
||||
|
||||
for (var i = 0; i < 10; i++)
|
||||
{
|
||||
using (testAssemblyLog.StartTestLog(output: null, className: $"{ThisAssemblyName}.FakeTestClass", loggerFactory: out var testLoggerFactory, minLogLevel: LogLevel.Trace, testName: "FakeTestName"))
|
||||
{
|
||||
testLoggerFactory.CreateLogger("TestLogger").LogInformation("Information!");
|
||||
}
|
||||
}
|
||||
}
|
||||
logger.LogInformation("Finished test log in {baseDirectory}", tempDir);
|
||||
|
||||
// The first log file exists
|
||||
Assert.True(File.Exists(Path.Combine(tempDir, ThisAssemblyName, TFM, "FakeTestClass", "FakeTestName.log")));
|
||||
|
||||
// Subsequent files exist
|
||||
for (var i = 0; i < 9; i++)
|
||||
{
|
||||
Assert.True(File.Exists(Path.Combine(tempDir, ThisAssemblyName, TFM, "FakeTestClass", $"FakeTestName.{i}.log")));
|
||||
}
|
||||
});
|
||||
|
||||
private static readonly Regex TimestampRegex = new Regex(@"\d+-\d+-\d+T\d+:\d+:\d+");
|
||||
private static readonly Regex TimestampOffsetRegex = new Regex(@"\d+\.\d+s");
|
||||
private static readonly Regex DurationRegex = new Regex(@"[^ ]+s$");
|
||||
|
||||
private async Task RunTestLogFunctionalTest(Action<string> action, [CallerMemberName] string testName = null)
|
||||
{
|
||||
var tempDir = Path.Combine(Path.GetTempPath(), $"TestLogging_{Guid.NewGuid().ToString("N")}");
|
||||
try
|
||||
{
|
||||
action(tempDir);
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (Directory.Exists(tempDir))
|
||||
{
|
||||
try
|
||||
{
|
||||
Directory.Delete(tempDir, recursive: true);
|
||||
}
|
||||
catch
|
||||
{
|
||||
await Task.Delay(100);
|
||||
Directory.Delete(tempDir, recursive: true);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private static string MakeConsistent(string input)
|
||||
{
|
||||
return string.Join(Environment.NewLine, input.Split(new[] { Environment.NewLine }, StringSplitOptions.None)
|
||||
.Select(line =>
|
||||
{
|
||||
var strippedPrefix = line.IndexOf("[") >= 0 ? line.Substring(line.IndexOf("[")) : line;
|
||||
|
||||
var strippedDuration = DurationRegex.Replace(strippedPrefix, "DURATION");
|
||||
var strippedTimestamp = TimestampRegex.Replace(strippedDuration, "TIMESTAMP");
|
||||
var strippedTimestampOffset = TimestampOffsetRegex.Replace(strippedTimestamp, "OFFSET");
|
||||
return strippedTimestampOffset;
|
||||
}));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,193 @@
|
|||
// Licensed to the .NET Foundation under one or more agreements.
|
||||
// The .NET Foundation licenses this file to you under the MIT license.
|
||||
// See the LICENSE file in the project root for more information.
|
||||
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
using Microsoft.AspNetCore.Testing;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Xunit;
|
||||
using Xunit.Abstractions;
|
||||
|
||||
namespace Microsoft.Extensions.Logging.Testing.Tests
|
||||
{
|
||||
[LogLevel(LogLevel.Debug)]
|
||||
[ShortClassName]
|
||||
public class LoggedTestXunitTests : TestLoggedTest
|
||||
{
|
||||
private readonly ITestOutputHelper _output;
|
||||
|
||||
public LoggedTestXunitTests(ITestOutputHelper output)
|
||||
{
|
||||
_output = output;
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void LoggedFactInitializesLoggedTestProperties()
|
||||
{
|
||||
Assert.NotNull(Logger);
|
||||
Assert.NotNull(LoggerFactory);
|
||||
Assert.NotNull(TestSink);
|
||||
Assert.NotNull(TestOutputHelper);
|
||||
}
|
||||
|
||||
[Theory]
|
||||
[InlineData("Hello world")]
|
||||
public void LoggedTheoryInitializesLoggedTestProperties(string argument)
|
||||
{
|
||||
Assert.NotNull(Logger);
|
||||
Assert.NotNull(LoggerFactory);
|
||||
Assert.NotNull(TestSink);
|
||||
Assert.NotNull(TestOutputHelper);
|
||||
// Use the test argument
|
||||
Assert.NotNull(argument);
|
||||
}
|
||||
|
||||
[ConditionalFact]
|
||||
public void ConditionalLoggedFactGetsInitializedLoggerFactory()
|
||||
{
|
||||
Assert.NotNull(Logger);
|
||||
Assert.NotNull(LoggerFactory);
|
||||
Assert.NotNull(TestSink);
|
||||
Assert.NotNull(TestOutputHelper);
|
||||
}
|
||||
|
||||
[ConditionalTheory]
|
||||
[InlineData("Hello world")]
|
||||
public void LoggedConditionalTheoryInitializesLoggedTestProperties(string argument)
|
||||
{
|
||||
Assert.NotNull(Logger);
|
||||
Assert.NotNull(LoggerFactory);
|
||||
Assert.NotNull(TestSink);
|
||||
Assert.NotNull(TestOutputHelper);
|
||||
// Use the test argument
|
||||
Assert.NotNull(argument);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
[LogLevel(LogLevel.Information)]
|
||||
public void LoggedFactFilteredByMethodLogLevel()
|
||||
{
|
||||
Logger.LogInformation("Information");
|
||||
Logger.LogDebug("Debug");
|
||||
|
||||
var message = Assert.Single(TestSink.Writes);
|
||||
Assert.Equal(LogLevel.Information, message.LogLevel);
|
||||
Assert.Equal("Information", message.Formatter(message.State, null));
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void LoggedFactFilteredByClassLogLevel()
|
||||
{
|
||||
Logger.LogDebug("Debug");
|
||||
Logger.LogTrace("Trace");
|
||||
|
||||
var message = Assert.Single(TestSink.Writes);
|
||||
Assert.Equal(LogLevel.Debug, message.LogLevel);
|
||||
Assert.Equal("Debug", message.Formatter(message.State, null));
|
||||
}
|
||||
|
||||
[Theory]
|
||||
[InlineData("Hello world")]
|
||||
[LogLevel(LogLevel.Information)]
|
||||
public void LoggedTheoryFilteredByLogLevel(string argument)
|
||||
{
|
||||
Logger.LogInformation("Information");
|
||||
Logger.LogDebug("Debug");
|
||||
|
||||
var message = Assert.Single(TestSink.Writes);
|
||||
Assert.Equal(LogLevel.Information, message.LogLevel);
|
||||
Assert.Equal("Information", message.Formatter(message.State, null));
|
||||
|
||||
// Use the test argument
|
||||
Assert.NotNull(argument);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void AddTestLoggingUpdatedWhenLoggerFactoryIsSet()
|
||||
{
|
||||
var loggerFactory = new LoggerFactory();
|
||||
var serviceCollection = new ServiceCollection();
|
||||
|
||||
LoggerFactory = loggerFactory;
|
||||
AddTestLogging(serviceCollection);
|
||||
|
||||
Assert.Same(loggerFactory, serviceCollection.BuildServiceProvider().GetRequiredService<ILoggerFactory>());
|
||||
}
|
||||
|
||||
[ConditionalTheory]
|
||||
[EnvironmentVariableSkipCondition("ASPNETCORE_TEST_LOG_DIR", "")] // The test name is only generated when logging is enabled via the environment variable
|
||||
[InlineData(null)]
|
||||
public void LoggedTheoryNullArgumentsAreEscaped(string argument)
|
||||
{
|
||||
Assert.NotNull(LoggerFactory);
|
||||
Assert.Equal($"{nameof(LoggedTheoryNullArgumentsAreEscaped)}_null", ResolvedTestMethodName);
|
||||
// Use the test argument
|
||||
Assert.Null(argument);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void AdditionalSetupInvoked()
|
||||
{
|
||||
Assert.True(SetupInvoked);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void MessageWrittenEventInvoked()
|
||||
{
|
||||
WriteContext context = null;
|
||||
TestSink.MessageLogged += ctx => context = ctx;
|
||||
Logger.LogInformation("Information");
|
||||
Assert.Equal(TestSink.Writes.Single(), context);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void ScopeStartedEventInvoked()
|
||||
{
|
||||
BeginScopeContext context = null;
|
||||
TestSink.ScopeStarted += ctx => context = ctx;
|
||||
using (Logger.BeginScope("Scope")) {}
|
||||
Assert.Equal(TestSink.Scopes.Single(), context);
|
||||
}
|
||||
}
|
||||
|
||||
public class LoggedTestXunitLogLevelTests : LoggedTest
|
||||
{
|
||||
[Fact]
|
||||
public void LoggedFactFilteredByAssemblyLogLevel()
|
||||
{
|
||||
Logger.LogTrace("Trace");
|
||||
|
||||
var message = Assert.Single(TestSink.Writes);
|
||||
Assert.Equal(LogLevel.Trace, message.LogLevel);
|
||||
Assert.Equal("Trace", message.Formatter(message.State, null));
|
||||
}
|
||||
}
|
||||
|
||||
public class LoggedTestXunitInitializationTests : TestLoggedTest
|
||||
{
|
||||
[Fact]
|
||||
public void ITestOutputHelperInitializedByDefault()
|
||||
{
|
||||
Assert.True(ITestOutputHelperIsInitialized);
|
||||
}
|
||||
}
|
||||
|
||||
public class TestLoggedTest : LoggedTest
|
||||
{
|
||||
public bool SetupInvoked { get; private set; } = false;
|
||||
public bool ITestOutputHelperIsInitialized { get; private set; } = false;
|
||||
|
||||
public override void Initialize(TestContext context, MethodInfo methodInfo, object[] testMethodArguments, ITestOutputHelper testOutputHelper)
|
||||
{
|
||||
base.Initialize(context, methodInfo, testMethodArguments, testOutputHelper);
|
||||
|
||||
try
|
||||
{
|
||||
TestOutputHelper.WriteLine("Test");
|
||||
ITestOutputHelperIsInitialized = true;
|
||||
} catch { }
|
||||
SetupInvoked = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -1,5 +1,4 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>$(DefaultNetCoreTargetFramework);net472</TargetFrameworks>
|
||||
|
||||
|
|
@ -18,7 +17,7 @@
|
|||
<Reference Include="System.Runtime.InteropServices.RuntimeInformation" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup Condition="'$(TargetFramework)' == 'net461'">
|
||||
<ItemGroup Condition="'$(TargetFramework)' == 'net472'">
|
||||
<Reference Include="System.Net.Http" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
|
|
|
|||
|
|
@ -1,6 +1,8 @@
|
|||
using Microsoft.AspNetCore.Testing;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using Microsoft.Extensions.Logging.Testing;
|
||||
using Xunit;
|
||||
|
||||
[assembly: Repeat(1)]
|
||||
[assembly: LogLevel(LogLevel.Trace)]
|
||||
[assembly: AssemblyFixture(typeof(TestAssemblyFixture))]
|
||||
[assembly: TestFramework("Microsoft.AspNetCore.Testing.AspNetTestFramework", "Microsoft.AspNetCore.Testing")]
|
||||
|
|
|
|||
|
|
@ -0,0 +1,37 @@
|
|||
// Licensed to the .NET Foundation under one or more agreements.
|
||||
// The .NET Foundation licenses this file to you under the MIT license.
|
||||
// See the LICENSE file in the project root for more information.
|
||||
|
||||
using System;
|
||||
using System.Text;
|
||||
using Xunit.Abstractions;
|
||||
|
||||
namespace Microsoft.Extensions.Logging.Testing.Tests
|
||||
{
|
||||
public class TestTestOutputHelper : ITestOutputHelper
|
||||
{
|
||||
private StringBuilder _output = new StringBuilder();
|
||||
|
||||
public bool Throw { get; set; }
|
||||
|
||||
public string Output => _output.ToString();
|
||||
|
||||
public void WriteLine(string message)
|
||||
{
|
||||
if (Throw)
|
||||
{
|
||||
throw new Exception("Boom!");
|
||||
}
|
||||
_output.AppendLine(message);
|
||||
}
|
||||
|
||||
public void WriteLine(string format, params object[] args)
|
||||
{
|
||||
if (Throw)
|
||||
{
|
||||
throw new Exception("Boom!");
|
||||
}
|
||||
_output.AppendLine(string.Format(format, args));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -17,7 +17,6 @@ namespace Microsoft.DotNet.OpenApi.Add.Tests
|
|||
public OpenApiAddURLTests(ITestOutputHelper output) : base(output){ }
|
||||
|
||||
[Fact]
|
||||
[QuarantinedTest]
|
||||
public async Task OpenApi_Add_Url_WithContentDisposition()
|
||||
{
|
||||
var project = CreateBasicProject(withOpenApi: false);
|
||||
|
|
@ -50,7 +49,6 @@ namespace Microsoft.DotNet.OpenApi.Add.Tests
|
|||
}
|
||||
|
||||
[Fact]
|
||||
[QuarantinedTest]
|
||||
public async Task OpenAPI_Add_Url_NoContentDisposition()
|
||||
{
|
||||
var project = CreateBasicProject(withOpenApi: false);
|
||||
|
|
@ -84,7 +82,6 @@ namespace Microsoft.DotNet.OpenApi.Add.Tests
|
|||
}
|
||||
|
||||
[Fact]
|
||||
[QuarantinedTest]
|
||||
public async Task OpenAPI_Add_Url_NoExtension_AssumesJson()
|
||||
{
|
||||
var project = CreateBasicProject(withOpenApi: false);
|
||||
|
|
@ -118,7 +115,6 @@ namespace Microsoft.DotNet.OpenApi.Add.Tests
|
|||
}
|
||||
|
||||
[Fact]
|
||||
[QuarantinedTest]
|
||||
public async Task OpenApi_Add_Url_NoSegment()
|
||||
{
|
||||
var project = CreateBasicProject(withOpenApi: false);
|
||||
|
|
@ -152,7 +148,6 @@ namespace Microsoft.DotNet.OpenApi.Add.Tests
|
|||
}
|
||||
|
||||
[Fact]
|
||||
[QuarantinedTest]
|
||||
public async Task OpenApi_Add_Url()
|
||||
{
|
||||
var project = CreateBasicProject(withOpenApi: false);
|
||||
|
|
@ -185,7 +180,6 @@ namespace Microsoft.DotNet.OpenApi.Add.Tests
|
|||
}
|
||||
|
||||
[Fact]
|
||||
[QuarantinedTest]
|
||||
public async Task OpenApi_Add_Url_SameName_UniqueFile()
|
||||
{
|
||||
var project = CreateBasicProject(withOpenApi: false);
|
||||
|
|
@ -246,7 +240,6 @@ namespace Microsoft.DotNet.OpenApi.Add.Tests
|
|||
}
|
||||
|
||||
[Fact]
|
||||
[QuarantinedTest]
|
||||
public async Task OpenApi_Add_Url_NSwagCSharp()
|
||||
{
|
||||
var project = CreateBasicProject(withOpenApi: false);
|
||||
|
|
@ -279,7 +272,6 @@ namespace Microsoft.DotNet.OpenApi.Add.Tests
|
|||
}
|
||||
|
||||
[Fact]
|
||||
[QuarantinedTest]
|
||||
public async Task OpenApi_Add_Url_NSwagTypeScript()
|
||||
{
|
||||
var project = CreateBasicProject(withOpenApi: false);
|
||||
|
|
@ -312,7 +304,6 @@ namespace Microsoft.DotNet.OpenApi.Add.Tests
|
|||
}
|
||||
|
||||
[Fact]
|
||||
[QuarantinedTest]
|
||||
public async Task OpenApi_Add_Url_OutputFile()
|
||||
{
|
||||
var project = CreateBasicProject(withOpenApi: false);
|
||||
|
|
@ -345,7 +336,6 @@ namespace Microsoft.DotNet.OpenApi.Add.Tests
|
|||
}
|
||||
|
||||
[Fact]
|
||||
[QuarantinedTest]
|
||||
public async Task OpenApi_Add_URL_FileAlreadyExists_Fail()
|
||||
{
|
||||
var project = CreateBasicProject(withOpenApi: false);
|
||||
|
|
@ -404,7 +394,6 @@ namespace Microsoft.DotNet.OpenApi.Add.Tests
|
|||
}
|
||||
|
||||
[Fact]
|
||||
[QuarantinedTest]
|
||||
public void OpenApi_Add_URL_MultipleTimes_OnlyOneReference()
|
||||
{
|
||||
var project = CreateBasicProject(withOpenApi: false);
|
||||
|
|
@ -431,7 +420,6 @@ namespace Microsoft.DotNet.OpenApi.Add.Tests
|
|||
}
|
||||
|
||||
[Fact]
|
||||
[QuarantinedTest]
|
||||
public async Task OpenAPi_Add_URL_InvalidUrl()
|
||||
{
|
||||
var project = CreateBasicProject(withOpenApi: false);
|
||||
|
|
@ -459,7 +447,6 @@ namespace Microsoft.DotNet.OpenApi.Add.Tests
|
|||
Assert.False(File.Exists(jsonFile));
|
||||
}
|
||||
|
||||
[QuarantinedTest]
|
||||
[Fact]
|
||||
public void OpenApi_Add_URL_ActualResponse()
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue