Skip to content

Commit 209cb52

Browse files
committed
Removed old #if commands
1 parent 6e53b33 commit 209cb52

File tree

4 files changed

+25
-14
lines changed

4 files changed

+25
-14
lines changed

DataLayer/SpecialisedEntities/Configurations/PaymentConfig.cs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,6 @@ public void Configure
1515
entity.HasDiscriminator(b => b.PType) //#A
1616
.HasValue<PaymentCash>(PTypes.Cash) //#B
1717
.HasValue<PaymentCard>(PTypes.Card); //#C
18-
19-
#if NETSTANDARD2_0
20-
//This is needed for TestChangePaymentTypeOk to work - see EF Core issue #7510
21-
entity.Property(p => p.PType)
22-
.Metadata.AfterSaveBehavior = PropertySaveBehavior.Save;
23-
#endif
2418
}
2519
}
2620
}

DataLayer/SpecialisedEntities/Configurations/UserConfig.cs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,7 @@ public void Configure
1313
{
1414
entity.HasAlternateKey(p => p.Email);
1515

16-
#if NETSTANDARD2_0
17-
entity.OwnsOne(e => e.HomeAddress).ToTable("Addresses");
18-
#elif NETSTANDARD2_1
19-
entity.OwnsOne(e => e.HomeAddress); //Cannot map ownedtype to separate table
20-
#endif
16+
entity.OwnsOne(e => e.HomeAddress);
2117
}
2218
}
2319
}

EfCoreInAction.Test.sln

Lines changed: 24 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
Microsoft Visual Studio Solution File, Format Version 12.00
3-
# Visual Studio Version 16
4-
VisualStudioVersion = 16.0.30717.126
3+
# Visual Studio Version 17
4+
VisualStudioVersion = 17.0.31825.309
55
MinimumVisualStudioVersion = 10.0.40219.1
66
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "DataLayer", "DataLayer\DataLayer.csproj", "{2451DCF6-EA52-434D-8A97-D23F4A8C6A72}"
77
EndProject
@@ -18,6 +18,8 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
1818
EndProject
1919
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "TestSupport", "TestSupport\TestSupport.csproj", "{0CB1A11C-6144-414D-81A9-F880DEB2C71A}"
2020
EndProject
21+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TestFromSqlRaw", "TestFromSqlRaw\TestFromSqlRaw.csproj", "{AADA2740-B6C5-4915-8705-4AD3B40F00D8}"
22+
EndProject
2123
Global
2224
GlobalSection(SolutionConfigurationPlatforms) = preSolution
2325
Debug|Any CPU = Debug|Any CPU
@@ -92,6 +94,26 @@ Global
9294
{0CB1A11C-6144-414D-81A9-F880DEB2C71A}.Release|x64.Build.0 = Release|Any CPU
9395
{0CB1A11C-6144-414D-81A9-F880DEB2C71A}.Release|x86.ActiveCfg = Release|Any CPU
9496
{0CB1A11C-6144-414D-81A9-F880DEB2C71A}.Release|x86.Build.0 = Release|Any CPU
97+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
98+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Debug|Any CPU.Build.0 = Debug|Any CPU
99+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Debug|ARM.ActiveCfg = Debug|Any CPU
100+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Debug|ARM.Build.0 = Debug|Any CPU
101+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Debug|ARM64.ActiveCfg = Debug|Any CPU
102+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Debug|ARM64.Build.0 = Debug|Any CPU
103+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Debug|x64.ActiveCfg = Debug|Any CPU
104+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Debug|x64.Build.0 = Debug|Any CPU
105+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Debug|x86.ActiveCfg = Debug|Any CPU
106+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Debug|x86.Build.0 = Debug|Any CPU
107+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Release|Any CPU.ActiveCfg = Release|Any CPU
108+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Release|Any CPU.Build.0 = Release|Any CPU
109+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Release|ARM.ActiveCfg = Release|Any CPU
110+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Release|ARM.Build.0 = Release|Any CPU
111+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Release|ARM64.ActiveCfg = Release|Any CPU
112+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Release|ARM64.Build.0 = Release|Any CPU
113+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Release|x64.ActiveCfg = Release|Any CPU
114+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Release|x64.Build.0 = Release|Any CPU
115+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Release|x86.ActiveCfg = Release|Any CPU
116+
{AADA2740-B6C5-4915-8705-4AD3B40F00D8}.Release|x86.Build.0 = Release|Any CPU
95117
EndGlobalSection
96118
GlobalSection(SolutionProperties) = preSolution
97119
HideSolutionNode = FALSE

TestSupport/EfHelpers/SqliteInMemory.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
using System;
55
using Microsoft.Data.Sqlite;
66
using Microsoft.EntityFrameworkCore;
7-
using Microsoft.Extensions.Logging;
87
using TestSupport.EfHelpers.Internal;
98

109
namespace TestSupport.EfHelpers

0 commit comments

Comments
 (0)