Update to 5.0.0-preview8

This commit is contained in:
Shay Rojansky
2020-09-13 17:05:47 +03:00
parent c442559286
commit 4776189715
7 changed files with 12 additions and 12 deletions

View File

@@ -1,13 +1,13 @@
<Project>
<ItemGroup>
<PackageReference Update="Microsoft.Extensions.DependencyInjection.Abstractions" Version="5.0.0-preview.3.20215.2" />
<PackageReference Update="Microsoft.EntityFrameworkCore" Version="5.0.0-preview.5.20278.2 " />
<PackageReference Update="Microsoft.EntityFrameworkCore.Relational" Version="5.0.0-preview.5.20278.2 " />
<PackageReference Update="Microsoft.Extensions.DependencyInjection.Abstractions" Version="5.0.0-preview.8.20407.11" />
<PackageReference Update="Microsoft.EntityFrameworkCore" Version="5.0.0-preview.8.20407.4" />
<PackageReference Update="Microsoft.EntityFrameworkCore.Relational" Version="5.0.0-preview.8.20407.4" />
<!-- Test -->
<PackageReference Update="xunit" Version="2.4.1" />
<PackageReference Update="xunit.runner.visualstudio" Version="2.4.1" />
<PackageReference Update="Microsoft.NET.Test.Sdk" Version="16.4.0" />
<PackageReference Update="Microsoft.EntityFrameworkCore.InMemory" Version="5.0.0-preview.5.20278.2 " />
<PackageReference Update="xunit.runner.visualstudio" Version="2.4.3" />
<PackageReference Update="Microsoft.NET.Test.Sdk" Version="16.7.1" />
<PackageReference Update="Microsoft.EntityFrameworkCore.InMemory" Version="5.0.0-preview.8.20407.4" />
</ItemGroup>
</Project>

View File

@@ -71,7 +71,7 @@ namespace EFCore.NamingConventions.Test
{
using var context = CreateContext();
var entityType = context.Model.FindEntityType(typeof(SimpleBlog));
Assert.Equal("ix_simpleblog_fullname", entityType.GetIndexes().Single().GetName());
Assert.Equal("ix_simpleblog_fullname", entityType.GetIndexes().Single().GetDatabaseName());
}
TestContext CreateContext(CultureInfo culture = null)

View File

@@ -91,7 +91,7 @@ namespace EFCore.NamingConventions.Test
{
using var context = CreateContext();
var entityType = context.Model.FindEntityType(typeof(SimpleBlog));
Assert.Equal("ix_simple_blog_full_name", entityType.GetIndexes().Single().GetName());
Assert.Equal("ix_simple_blog_full_name", entityType.GetIndexes().Single().GetDatabaseName());
}
TestContext CreateContext(CultureInfo culture = null) => new TestContext(builder => builder.UseSnakeCaseNamingConvention(culture));

View File

@@ -69,7 +69,7 @@ namespace EFCore.NamingConventions.Test
{
using var context = CreateContext();
var entityType = context.Model.FindEntityType(typeof(SimpleBlog));
Assert.Equal("IX_SIMPLEBLOG_FULLNAME", entityType.GetIndexes().Single().GetName());
Assert.Equal("IX_SIMPLEBLOG_FULLNAME", entityType.GetIndexes().Single().GetDatabaseName());
}
TestContext CreateContext(CultureInfo culture = null) => new TestContext(builder => builder.UseUpperCaseNamingConvention(culture));

View File

@@ -89,7 +89,7 @@ namespace EFCore.NamingConventions.Test
{
using var context = CreateContext();
var entityType = context.Model.FindEntityType(typeof(SimpleBlog));
Assert.Equal("IX_SIMPLE_BLOG_FULL_NAME", entityType.GetIndexes().Single().GetName());
Assert.Equal("IX_SIMPLE_BLOG_FULL_NAME", entityType.GetIndexes().Single().GetDatabaseName());
}
TestContext CreateContext(CultureInfo culture = null) => new TestContext(builder => builder.UseUpperSnakeCaseNamingConvention(culture));

View File

@@ -4,7 +4,7 @@
<AssemblyName>EFCore.NamingConventions</AssemblyName>
<RootNamespace>EFCore</RootNamespace>
<TargetFramework>netstandard2.1</TargetFramework>
<VersionPrefix>5.0.0-preview5</VersionPrefix>
<VersionPrefix>5.0.0-preview8</VersionPrefix>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<SignAssembly>true</SignAssembly>
<AssemblyOriginatorKeyFile>../EFCore.NamingConventions.snk</AssemblyOriginatorKeyFile>

View File

@@ -106,6 +106,6 @@ namespace EFCore.NamingConventions.Internal
public void ProcessIndexAdded(
IConventionIndexBuilder indexBuilder,
IConventionContext<IConventionIndexBuilder> context)
=> indexBuilder.HasName(RewriteName(indexBuilder.Metadata.GetName()));
=> indexBuilder.HasDatabaseName(RewriteName(indexBuilder.Metadata.GetDatabaseName()));
}
}