-
Notifications
You must be signed in to change notification settings - Fork 225
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Sync to latest upstream PR and support inner join over subquery
- Loading branch information
Showing
17 changed files
with
246 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
test/EFCore.PG.FunctionalTests/BulkUpdates/FiltersInheritanceBulkUpdatesNpgsqlFixture.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
// Licensed to the .NET Foundation under one or more agreements. | ||
// The .NET Foundation licenses this file to you under the MIT license. | ||
|
||
namespace Npgsql.EntityFrameworkCore.PostgreSQL.BulkUpdates; | ||
|
||
public class FiltersInheritanceBulkUpdatesNpgsqlFixture : InheritanceBulkUpdatesNpgsqlFixture | ||
{ | ||
protected override bool EnableFilters | ||
=> true; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
test/EFCore.PG.FunctionalTests/BulkUpdates/InheritanceBulkUpdatesNpgsqlFixture.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
using Microsoft.EntityFrameworkCore.BulkUpdates; | ||
using Npgsql.EntityFrameworkCore.PostgreSQL.TestUtilities; | ||
|
||
namespace Npgsql.EntityFrameworkCore.PostgreSQL.BulkUpdates; | ||
|
||
public class InheritanceBulkUpdatesNpgsqlFixture : InheritanceBulkUpdatesRelationalFixture | ||
{ | ||
protected override ITestStoreFactory TestStoreFactory | ||
=> NpgsqlTestStoreFactory.Instance; | ||
} |
5 changes: 2 additions & 3 deletions
5
test/EFCore.PG.FunctionalTests/BulkUpdates/InheritanceBulkUpdatesNpgsqlTest.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
50 changes: 50 additions & 0 deletions
50
test/EFCore.PG.FunctionalTests/BulkUpdates/NorthwindBulkUpdatesNpgsqlFixture.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
using Microsoft.EntityFrameworkCore.BulkUpdates; | ||
using Microsoft.EntityFrameworkCore.TestModels.Northwind; | ||
using Npgsql.EntityFrameworkCore.PostgreSQL.TestUtilities; | ||
|
||
namespace Npgsql.EntityFrameworkCore.PostgreSQL.BulkUpdates; | ||
|
||
public class NorthwindBulkUpdatesNpgsqlFixture<TModelCustomizer> : NorthwindBulkUpdatesFixture<TModelCustomizer> | ||
where TModelCustomizer: IModelCustomizer, new() | ||
{ | ||
protected override ITestStoreFactory TestStoreFactory | ||
=> NpgsqlNorthwindTestStoreFactory.Instance; | ||
|
||
protected override void OnModelCreating(ModelBuilder modelBuilder, DbContext context) | ||
{ | ||
base.OnModelCreating(modelBuilder, context); | ||
|
||
modelBuilder.Entity<Customer>() | ||
.Property(c => c.CustomerID) | ||
.HasColumnType("char(5)"); | ||
|
||
modelBuilder.Entity<Employee>( | ||
b => | ||
{ | ||
b.Property(c => c.EmployeeID).HasColumnType("int"); | ||
b.Property(c => c.ReportsTo).HasColumnType("int"); | ||
}); | ||
|
||
modelBuilder.Entity<Order>( | ||
b => | ||
{ | ||
b.Property(o => o.EmployeeID).HasColumnType("int"); | ||
b.Property(o => o.OrderDate).HasColumnType("timestamp without time zone"); | ||
}); | ||
|
||
modelBuilder.Entity<OrderDetail>() | ||
.Property(od => od.UnitPrice) | ||
.HasColumnType("money"); | ||
|
||
modelBuilder.Entity<Product>( | ||
b => | ||
{ | ||
b.Property(p => p.UnitPrice).HasColumnType("money"); | ||
b.Property(p => p.UnitsInStock).HasColumnType("smallint"); | ||
}); | ||
|
||
modelBuilder.Entity<MostExpensiveProduct>() | ||
.Property(p => p.UnitPrice) | ||
.HasColumnType("money"); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 6 additions & 0 deletions
6
test/EFCore.PG.FunctionalTests/BulkUpdates/TPCFiltersInheritanceBulkUpdatesNpgsqlFixture.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
namespace Npgsql.EntityFrameworkCore.PostgreSQL.BulkUpdates; | ||
|
||
public class TPCFiltersInheritanceBulkUpdatesNpgsqlFixture : TPCInheritanceBulkUpdatesNpgsqlFixture | ||
{ | ||
protected override bool EnableFilters => true; | ||
} |
6 changes: 4 additions & 2 deletions
6
test/EFCore.PG.FunctionalTests/BulkUpdates/TPCFiltersInheritanceBulkUpdatesNpgsqlTest.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
test/EFCore.PG.FunctionalTests/BulkUpdates/TPCInheritanceBulkUpdatesNpgsqlFixture.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
using Microsoft.EntityFrameworkCore.BulkUpdates; | ||
using Npgsql.EntityFrameworkCore.PostgreSQL.TestUtilities; | ||
|
||
namespace Npgsql.EntityFrameworkCore.PostgreSQL.BulkUpdates; | ||
|
||
public class TPCInheritanceBulkUpdatesNpgsqlFixture : TPCInheritanceBulkUpdatesFixture | ||
{ | ||
protected override ITestStoreFactory TestStoreFactory | ||
=> NpgsqlTestStoreFactory.Instance; | ||
|
||
protected override bool UseGeneratedKeys | ||
=> false; | ||
} |
6 changes: 4 additions & 2 deletions
6
test/EFCore.PG.FunctionalTests/BulkUpdates/TPCInheritanceBulkUpdatesNpgsqlTest.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 6 additions & 0 deletions
6
test/EFCore.PG.FunctionalTests/BulkUpdates/TPTFiltersInheritanceBulkUpdatesNpgsqlFixture.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
namespace Npgsql.EntityFrameworkCore.PostgreSQL.BulkUpdates; | ||
|
||
public class TPTFiltersInheritanceBulkUpdatesNpgsqlFixture : TPTInheritanceBulkUpdatesNpgsqlFixture | ||
{ | ||
protected override bool EnableFilters => true; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
test/EFCore.PG.FunctionalTests/BulkUpdates/TPTInheritanceBulkUpdatesNpgsqlFixture.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
using Microsoft.EntityFrameworkCore.BulkUpdates; | ||
using Npgsql.EntityFrameworkCore.PostgreSQL.TestUtilities; | ||
|
||
namespace Npgsql.EntityFrameworkCore.PostgreSQL.BulkUpdates; | ||
|
||
public class TPTInheritanceBulkUpdatesNpgsqlFixture : TPTInheritanceBulkUpdatesFixture | ||
{ | ||
protected override ITestStoreFactory TestStoreFactory | ||
=> NpgsqlTestStoreFactory.Instance; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters