Skip to content

Commit

Permalink
Merge pull request #272 from Flexberry/feature-update-to-net6
Browse files Browse the repository at this point in the history
Update ODataService for work on .Net6 and .Net7
  • Loading branch information
Anisimova2020 authored Feb 17, 2023
2 parents aca15f8 + 8a29fc7 commit 8587d23
Show file tree
Hide file tree
Showing 34 changed files with 807 additions and 510 deletions.
66 changes: 52 additions & 14 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,20 +58,40 @@ jobs:
with:
dotnet-version: 3.1.x

# Building requires an up-to-date .NET SDK.

- name: Install .NET 6.0
uses: actions/setup-dotnet@v1
with:
dotnet-version: 6.0.x

# Building requires an up-to-date .NET SDK.

- name: Install .NET 7.0
uses: actions/setup-dotnet@v1
with:
dotnet-version: 7.0.x

- name: Restore NewPlatform.Flexberry.ORM.ODataService.sln
run: nuget restore NewPlatform.Flexberry.ORM.ODataService.sln -NonInteractive
run: dotnet restore NewPlatform.Flexberry.ORM.ODataService.sln

- name: Install xunit.runner.console
run: nuget install xunit.runner.console -Version 2.4.1 -OutputDirectory testrunner
run: nuget install xunit.runner.console -Version $XUNIT_RUNNER -OutputDirectory testrunner

- name: Compile code
run: msbuild /verbosity:quiet /p:WarningLevel=0 /p:Configuration=Debug NewPlatform.Flexberry.ORM.ODataService.sln
run: dotnet build --no-restore -v q /p:WarningLevel=0 -c $CONFIGURATION NewPlatform.Flexberry.ORM.ODataService.sln

- name: Test under mono
run: mono ./testrunner/xunit.runner.console.2.4.1/tools/net461/xunit.console.exe ./Tests/NewPlatform.Flexberry.ORM.ODataService.Tests/bin/Debug/net461/NewPlatform.Flexberry.ORM.ODataService.Tests.dll
- name: Test on dotnet 3.1
run: dotnet test ./Tests/NewPlatform.Flexberry.ORM.ODataService.Tests/bin/$CONFIGURATION/netcoreapp3.1/NewPlatform.Flexberry.ORM.ODataService.Tests.dll

- name: Test under dotnet
run: dotnet test ./Tests/NewPlatform.Flexberry.ORM.ODataService.Tests/bin/Debug/netcoreapp3.1/NewPlatform.Flexberry.ORM.ODataService.Tests.dll
- name: Test on dotnet 6.0
run: dotnet test ./Tests/NewPlatform.Flexberry.ORM.ODataService.Tests/bin/$CONFIGURATION/net6.0/NewPlatform.Flexberry.ORM.ODataService.Tests.dll

- name: Test on dotnet 7.0
run: dotnet test ./Tests/NewPlatform.Flexberry.ORM.ODataService.Tests/bin/$CONFIGURATION/net7.0/NewPlatform.Flexberry.ORM.ODataService.Tests.dll

- name: Test under mono
run: mono ./testrunner/xunit.runner.console.$XUNIT_RUNNER/tools/net461/xunit.console.exe ./Tests/NewPlatform.Flexberry.ORM.ODataService.Tests/bin/$CONFIGURATION/net461/NewPlatform.Flexberry.ORM.ODataService.Tests.dll

- name: Cleanup
if: always()
Expand Down Expand Up @@ -117,20 +137,38 @@ jobs:
with:
dotnet-version: 3.1.x

# Building requires an up-to-date .NET SDK.

- name: Install .NET 6.0
uses: actions/setup-dotnet@v1
with:
dotnet-version: 6.0.x

- name: Install .NET 7.0
uses: actions/setup-dotnet@v1
with:
dotnet-version: 7.0.x

- name: Restore NewPlatform.Flexberry.ORM.ODataService.sln
run: nuget restore NewPlatform.Flexberry.ORM.ODataService.sln -NonInteractive
run: dotnet restore NewPlatform.Flexberry.ORM.ODataService.sln

- name: Install xunit.runner.console
run: nuget install xunit.runner.console -Version 2.4.1 -OutputDirectory testrunner
run: nuget install xunit.runner.console -Version $XUNIT_RUNNER -OutputDirectory testrunner

- name: Compile code
run: msbuild /verbosity:quiet /p:WarningLevel=0 /p:Configuration=Debug NewPlatform.Flexberry.ORM.ODataService.sln
run: dotnet build --no-restore -v q /p:WarningLevel=0 -c $CONFIGURATION NewPlatform.Flexberry.ORM.ODataService.sln

- name: Test under mono
run: mono ./testrunner/xunit.runner.console.2.4.1/tools/net461/xunit.console.exe ./Tests/NewPlatform.Flexberry.ORM.ODataService.Tests/bin/Debug/net461/NewPlatform.Flexberry.ORM.ODataService.Tests.dll
- name: Test on dotnet 3.1
run: dotnet test ./Tests/NewPlatform.Flexberry.ORM.ODataService.Tests/bin/$CONFIGURATION/netcoreapp3.1/NewPlatform.Flexberry.ORM.ODataService.Tests.dll

- name: Test under dotnet
run: dotnet test ./Tests/NewPlatform.Flexberry.ORM.ODataService.Tests/bin/Debug/netcoreapp3.1/NewPlatform.Flexberry.ORM.ODataService.Tests.dll
- name: Test on dotnet 6.0
run: dotnet test ./Tests/NewPlatform.Flexberry.ORM.ODataService.Tests/bin/$CONFIGURATION/net6.0/NewPlatform.Flexberry.ORM.ODataService.Tests.dll

- name: Test on dotnet 7.0
run: dotnet test ./Tests/NewPlatform.Flexberry.ORM.ODataService.Tests/bin/$CONFIGURATION/net7.0/NewPlatform.Flexberry.ORM.ODataService.Tests.dll

- name: Test under mono
run: mono ./testrunner/xunit.runner.console.$XUNIT_RUNNER/tools/net461/xunit.console.exe ./Tests/NewPlatform.Flexberry.ORM.ODataService.Tests/bin/$CONFIGURATION/net461/NewPlatform.Flexberry.ORM.ODataService.Tests.dll

- name: Cleanup
if: always()
Expand Down
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,16 @@ This project adheres to [Semantic Versioning](http://semver.org/).

### Fixed

## [7.0.0] - 2023.02.17

### Added
1. Added stubbed namespace for entities with publish name.
2. Added .net6 and .net7 as target frameworks.

### Changed
1. Upgrade `Microsoft.AspNet.OData` to `7.6.1`
2. Upgrade `NewPlatform.Flexberry.AspNetCore.OData` to `7.6.2`

## [6.2.0] - 2023.02.16

### Added
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net45;net461;netcoreapp3.1;netstandard2.0</TargetFrameworks>
<TargetFrameworks>net45;net461;netcoreapp3.1;netstandard2.0;net6.0;net7.0</TargetFrameworks>
<Configurations>Debug;Release</Configurations>
<LangVersion>latest</LangVersion>
<RootNamespace>NewPlatform.Flexberry.ORM.ODataService.Files</RootNamespace>
Expand All @@ -21,7 +21,7 @@
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="NewPlatform.Flexberry.ORM" Version="6.1.0" />
<PackageReference Include="NewPlatform.Flexberry.ORM" Version="7.0.0" />
<PackageReference Include="StyleCop.Analyzers" Version="1.1.118">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
Expand All @@ -40,7 +40,7 @@
<PackageReference Include="Microsoft.AspNetCore.StaticFiles" Version="2.2.0" />
</ItemGroup>

<ItemGroup Condition=" '$(TargetFramework)' == 'netcoreapp3.1'">
<ItemGroup Condition=" '$(TargetFramework)' == 'netcoreapp3.1' Or '$(TargetFramework)' == 'net6.0' Or '$(TargetFramework)' == 'net7.0' ">
<FrameworkReference Include="Microsoft.AspNetCore.App" />
</ItemGroup>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 16
VisualStudioVersion = 16.0.29709.97
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NewPlatform.Flexberry.ORM.ODataService", "NewPlatform.Flexberry.ORM.ODataService\NewPlatform.Flexberry.ORM.ODataService.csproj", "{01BBE45A-3A3F-4EA5-9457-8C62167B5E99}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NewPlatform.Flexberry.ORM.ODataService", "NewPlatform.Flexberry.ORM.ODataService\NewPlatform.Flexberry.ORM.ODataService.csproj", "{01BBE45A-3A3F-4EA5-9457-8C62167B5E99}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "NuGet Package Properties", "NuGet Package Properties", "{EF5F8D62-3B41-44F8-B748-E5CE1CBF00A9}"
ProjectSection(SolutionItems) = preProject
Expand All @@ -12,30 +12,39 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "NuGet Package Properties",
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Tests", "Tests", "{A94D831A-7B5D-40C6-B76B-2B8B6335DB3E}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NewPlatform.Flexberry.ORM.ODataService.Tests", "Tests\NewPlatform.Flexberry.ORM.ODataService.Tests\NewPlatform.Flexberry.ORM.ODataService.Tests.csproj", "{8E43819E-6643-4E5F-A3A2-B1C212033DE6}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NewPlatform.Flexberry.ORM.ODataService.Tests", "Tests\NewPlatform.Flexberry.ORM.ODataService.Tests\NewPlatform.Flexberry.ORM.ODataService.Tests.csproj", "{8E43819E-6643-4E5F-A3A2-B1C212033DE6}"
ProjectSection(ProjectDependencies) = postProject
{5090ACBA-7CD6-4AA7-88A2-15D541573988} = {5090ACBA-7CD6-4AA7-88A2-15D541573988}
EndProjectSection
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NewPlatform.Flexberry.ORM.ODataService.Tests.Objects", "Tests\Objects\NewPlatform.Flexberry.ORM.ODataService.Tests.Objects.csproj", "{10CE2502-3EEF-4285-935F-E18F5F623C6D}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NewPlatform.Flexberry.ORM.ODataService.Tests.Objects", "Tests\Objects\NewPlatform.Flexberry.ORM.ODataService.Tests.Objects.csproj", "{10CE2502-3EEF-4285-935F-E18F5F623C6D}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NewPlatform.Flexberry.ORM.ODataService.Tests.BusinessServers", "Tests\BusinessServers\NewPlatform.Flexberry.ORM.ODataService.Tests.BusinessServers.csproj", "{BFB771C3-51D8-4804-BB0F-A0B4BD7981D9}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NewPlatform.Flexberry.ORM.ODataService.Tests.BusinessServers", "Tests\BusinessServers\NewPlatform.Flexberry.ORM.ODataService.Tests.BusinessServers.csproj", "{BFB771C3-51D8-4804-BB0F-A0B4BD7981D9}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Open Source", "Open Source", "{DB00E5CF-65B6-4A94-8C83-A80DB75E9B02}"
ProjectSection(SolutionItems) = preProject
.gitignore = .gitignore
.travis.yml = .travis.yml
.github\workflows\build.yml = .github\workflows\build.yml
CHANGELOG.md = CHANGELOG.md
ConfigTuner.ps1 = ConfigTuner.ps1
LICENSE.md = LICENSE.md
README.md = README.md
EndProjectSection
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NewPlatform.Flexberry.ORM.ODataService.Files", "NewPlatform.Flexberry.ORM.ODataService.Files\NewPlatform.Flexberry.ORM.ODataService.Files.csproj", "{22FAA967-EA69-4AE9-9A07-ECEE6C499BBB}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NewPlatform.Flexberry.ORM.ODataService.WebApi", "NewPlatform.Flexberry.ORM.ODataService.WebApi\NewPlatform.Flexberry.ORM.ODataService.WebApi.csproj", "{D3EBD348-D0F8-4C1E-BDC0-6C77D9D443CB}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NewPlatform.Flexberry.ORM.ODataService.Files", "NewPlatform.Flexberry.ORM.ODataService.Files\NewPlatform.Flexberry.ORM.ODataService.Files.csproj", "{22FAA967-EA69-4AE9-9A07-ECEE6C499BBB}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NewPlatform.Flexberry.ORM.ODataService.Cors", "NewPlatform.Flexberry.ORM.ODataService.Cors\NewPlatform.Flexberry.ORM.ODataService.Cors.csproj", "{225422F1-D9A8-4B35-9AE3-68C2C1BAAD22}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NewPlatform.Flexberry.ORM.ODataService.WebApi", "NewPlatform.Flexberry.ORM.ODataService.WebApi\NewPlatform.Flexberry.ORM.ODataService.WebApi.csproj", "{D3EBD348-D0F8-4C1E-BDC0-6C77D9D443CB}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ODataServiceSample.AspNet", "Samples\ODataServiceSample.AspNet\ODataServiceSample.AspNet.csproj", "{D1CE223D-844E-45FF-BDAD-6252A3F3A4EA}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NewPlatform.Flexberry.ORM.ODataServiceCore.Common", "NewPlatform.Flexberry.ORM.ODataServiceCore.Common\NewPlatform.Flexberry.ORM.ODataServiceCore.Common.csproj", "{2C84BB80-78BD-4771-BA5A-32D32DB568DE}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NewPlatform.Flexberry.ORM.ODataServiceCore.WebApi", "NewPlatform.Flexberry.ORM.ODataServiceCore.WebApi\NewPlatform.Flexberry.ORM.ODataServiceCore.WebApi.csproj", "{B9E13B47-4A51-4D47-B5B1-2C1A3A8008B1}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ODataServiceSample.AspNetCore", "Samples\ODataServiceSample.AspNetCore\ODataServiceSample.AspNetCore.csproj", "{5090ACBA-7CD6-4AA7-88A2-15D541573988}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Samples", "Samples", "{DE953BA7-BD14-48DA-AAAA-E835DC84497A}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down Expand Up @@ -66,14 +75,22 @@ Global
{D3EBD348-D0F8-4C1E-BDC0-6C77D9D443CB}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D3EBD348-D0F8-4C1E-BDC0-6C77D9D443CB}.Release|Any CPU.ActiveCfg = Release|Any CPU
{D3EBD348-D0F8-4C1E-BDC0-6C77D9D443CB}.Release|Any CPU.Build.0 = Release|Any CPU
{225422F1-D9A8-4B35-9AE3-68C2C1BAAD22}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{225422F1-D9A8-4B35-9AE3-68C2C1BAAD22}.Debug|Any CPU.Build.0 = Debug|Any CPU
{225422F1-D9A8-4B35-9AE3-68C2C1BAAD22}.Release|Any CPU.ActiveCfg = Release|Any CPU
{225422F1-D9A8-4B35-9AE3-68C2C1BAAD22}.Release|Any CPU.Build.0 = Release|Any CPU
{D1CE223D-844E-45FF-BDAD-6252A3F3A4EA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D1CE223D-844E-45FF-BDAD-6252A3F3A4EA}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D1CE223D-844E-45FF-BDAD-6252A3F3A4EA}.Release|Any CPU.ActiveCfg = Release|Any CPU
{D1CE223D-844E-45FF-BDAD-6252A3F3A4EA}.Release|Any CPU.Build.0 = Release|Any CPU
{2C84BB80-78BD-4771-BA5A-32D32DB568DE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{2C84BB80-78BD-4771-BA5A-32D32DB568DE}.Debug|Any CPU.Build.0 = Debug|Any CPU
{2C84BB80-78BD-4771-BA5A-32D32DB568DE}.Release|Any CPU.ActiveCfg = Release|Any CPU
{2C84BB80-78BD-4771-BA5A-32D32DB568DE}.Release|Any CPU.Build.0 = Release|Any CPU
{B9E13B47-4A51-4D47-B5B1-2C1A3A8008B1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{B9E13B47-4A51-4D47-B5B1-2C1A3A8008B1}.Debug|Any CPU.Build.0 = Debug|Any CPU
{B9E13B47-4A51-4D47-B5B1-2C1A3A8008B1}.Release|Any CPU.ActiveCfg = Release|Any CPU
{B9E13B47-4A51-4D47-B5B1-2C1A3A8008B1}.Release|Any CPU.Build.0 = Release|Any CPU
{5090ACBA-7CD6-4AA7-88A2-15D541573988}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{5090ACBA-7CD6-4AA7-88A2-15D541573988}.Debug|Any CPU.Build.0 = Debug|Any CPU
{5090ACBA-7CD6-4AA7-88A2-15D541573988}.Release|Any CPU.ActiveCfg = Release|Any CPU
{5090ACBA-7CD6-4AA7-88A2-15D541573988}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand All @@ -82,9 +99,10 @@ Global
{8E43819E-6643-4E5F-A3A2-B1C212033DE6} = {A94D831A-7B5D-40C6-B76B-2B8B6335DB3E}
{10CE2502-3EEF-4285-935F-E18F5F623C6D} = {A94D831A-7B5D-40C6-B76B-2B8B6335DB3E}
{BFB771C3-51D8-4804-BB0F-A0B4BD7981D9} = {A94D831A-7B5D-40C6-B76B-2B8B6335DB3E}
{D1CE223D-844E-45FF-BDAD-6252A3F3A4EA} = {DE953BA7-BD14-48DA-AAAA-E835DC84497A}
{5090ACBA-7CD6-4AA7-88A2-15D541573988} = {DE953BA7-BD14-48DA-AAAA-E835DC84497A}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
EnterpriseLibraryConfigurationToolBinariesPath = packages\Unity.2.1.505.2\lib\NET35;packages\Unity.Interception.2.1.505.0\lib\NET35;packages\EnterpriseLibrary.Common.5.0.505.0\lib\NET35;packages\EnterpriseLibrary.Data.5.0.505.0\lib\NET35;packages\EnterpriseLibrary.Logging.5.0.505.0\lib\NET35;packages\EnterpriseLibrary.Logging.Database.5.0.505.0\lib\NET35
SolutionGuid = {611B715C-AD46-45B1-BA4E-36C8F1A1896E}
EndGlobalSection
EndGlobal
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="NewPlatform.Flexberry.LockService" Version="3.0.0" />
<PackageReference Include="NewPlatform.Flexberry.ORM" Version="6.1.0" />
<PackageReference Include="NewPlatform.Flexberry.ORM" Version="7.0.0" />
<PackageReference Include="StyleCop.Analyzers" Version="1.1.118">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
Expand Down
Loading

0 comments on commit 8587d23

Please sign in to comment.