From c7084b53797b474b9955f5ef6b956d3fdac907b8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=BCseyin=20Sekmeno=C4=9Flu?= Date: Fri, 7 Jun 2024 15:38:45 +0300 Subject: [PATCH 1/4] feat: upgraded to .net v8 --- Directory.Build.props | 9 +++++++-- .../Cogworks.AzureSearch.IoC.Umbraco.csproj | 14 +++++++------- ...ks.AzureSearch.IoC.Umbraco.UnitTests.csproj | 18 ++++++++++++------ .../UmbracoIocExtensionTests.cs | 10 +++++----- 4 files changed, 31 insertions(+), 20 deletions(-) diff --git a/Directory.Build.props b/Directory.Build.props index 1ce346f..c228a49 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -14,7 +14,7 @@ - net7.0;net6.0;net5.0 + net8.0;net7.0;net6.0 latest 1591;1701;1702;8032;NU1701;AD0001;CA1041;CS0311;CS5001 false @@ -31,6 +31,11 @@ true + + enable + disable + + enable disable @@ -54,7 +59,7 @@ - + diff --git a/src/Cogworks.AzureSearch.IoC.Umbraco/Cogworks.AzureSearch.IoC.Umbraco.csproj b/src/Cogworks.AzureSearch.IoC.Umbraco/Cogworks.AzureSearch.IoC.Umbraco.csproj index a859fb1..f8b4d29 100644 --- a/src/Cogworks.AzureSearch.IoC.Umbraco/Cogworks.AzureSearch.IoC.Umbraco.csproj +++ b/src/Cogworks.AzureSearch.IoC.Umbraco/Cogworks.AzureSearch.IoC.Umbraco.csproj @@ -3,8 +3,8 @@ . Cogworks.AzureSearch.IoC.Umbraco Cogworks.AzureSearch.IoC.Umbraco - An Umbraco extension to Cogworks.AzureSearch. - An Umbraco 9, 10, 11 extension to Cogworks.AzureSearch + An Umbraco 10+ extension to Cogworks.AzureSearch. + An Umbraco 10+ extension to Cogworks.AzureSearch Azure Search Umbraco container IoC Apache-2.0 @@ -15,18 +15,18 @@ + + + + - + - - - - diff --git a/tests/UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests.csproj b/tests/UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests.csproj index 87011af..25a43dc 100644 --- a/tests/UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests.csproj +++ b/tests/UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests.csproj @@ -4,7 +4,7 @@ - net7.0;net6.0;net5.0 + net8.0;net7.0;net6.0 latest 1591;1701;1702;8032;NU1701;AD0001;CA1041;CS0311;CS5001 false @@ -21,6 +21,11 @@ true + + disable + disable + + disable disable @@ -35,18 +40,19 @@ + + + + + - + - - - - diff --git a/tests/UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests/UmbracoIocExtensionTests.cs b/tests/UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests/UmbracoIocExtensionTests.cs index 3cd321c..2c352e5 100644 --- a/tests/UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests/UmbracoIocExtensionTests.cs +++ b/tests/UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests/UmbracoIocExtensionTests.cs @@ -39,17 +39,17 @@ public class UmbracoIocExtensionTests public UmbracoIocExtensionTests() { _serviceCollection = new ServiceCollection(); - var dirName = Path.GetDirectoryName( - Assembly.GetExecutingAssembly() - .Location - .Replace("bin\\Debug", string.Empty)); var typeLoader = -#if NET6_0_OR_GREATER || NET7_0 +#if NET6_0_OR_GREATER || NET7_0 || NET8_0 new TypeLoader( Substitute.For(), Substitute.For>()); #else + var dirName = Path.GetDirectoryName( + Assembly.GetExecutingAssembly() + .Location + .Replace("bin\\Debug", string.Empty)); new TypeLoader( Substitute.For(), new VaryingRuntimeHash(), From 59494a2c0bfa2022735a1b9f88ed4ec8a0587987 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=BCseyin=20Sekmeno=C4=9Flu?= Date: Fri, 7 Jun 2024 15:45:22 +0300 Subject: [PATCH 2/4] feat: updated net versions in pipelines --- .github/workflows/build.yml | 12 ++++++------ .github/workflows/changelog.yml | 4 ++-- .github/workflows/gitflow.yml | 2 +- .github/workflows/pull-request.yml | 12 ++++++------ .github/workflows/release-github.yml | 2 +- .github/workflows/release-nuget.yml | 2 +- 6 files changed, 17 insertions(+), 17 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 13592cd..32182cb 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -33,11 +33,11 @@ jobs: steps: - name: Checkout reference commit if: ${{ github.event_name == 'pull_request' }} - uses: actions/checkout@v2 + uses: actions/checkout@v4 - name: Checkout master if: ${{ github.event_name != 'pull_request' }} - uses: actions/checkout@v2 + uses: actions/checkout@v4 with: ref: master fetch-depth: 0 @@ -53,13 +53,13 @@ jobs: with: node-version: '16.13.0' - - name: Setup .NET 5/6/7 - uses: actions/setup-dotnet@v3 + - name: Setup .NET 6/7/8 + uses: actions/setup-dotnet@v4 with: dotnet-version: | - 5.0.x 6.0.x 7.0.x + 8.0.x - name: Configure NuGet uses: nuget/setup-nuget@v1 @@ -81,7 +81,7 @@ jobs: dotnet publish \ -o ${{ env.BINARIES_OUTPUT }} \ -c ${{ env.CONFIG }} \ - -f net7.0 \ + -f net8.0 \ --no-build \ --no-restore diff --git a/.github/workflows/changelog.yml b/.github/workflows/changelog.yml index d62fe48..799dd21 100644 --- a/.github/workflows/changelog.yml +++ b/.github/workflows/changelog.yml @@ -14,7 +14,7 @@ jobs: CONVENTIONAL_GITHUB_RELEASER_TOKEN: ${{ secrets.GITHUB_TOKEN }} steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: fetch-depth: 0 @@ -41,7 +41,7 @@ jobs: echo "branch=$branch_check" >> $GITHUB_ENV - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 name: Checkout tag branch with: fetch-depth: 0 diff --git a/.github/workflows/gitflow.yml b/.github/workflows/gitflow.yml index 9f951b4..51266cb 100644 --- a/.github/workflows/gitflow.yml +++ b/.github/workflows/gitflow.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: ref: master fetch-depth: 0 diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml index 4228305..33e0ecc 100644 --- a/.github/workflows/pull-request.yml +++ b/.github/workflows/pull-request.yml @@ -29,11 +29,11 @@ jobs: steps: - name: Checkout reference commit if: ${{ github.event_name == 'pull_request' }} - uses: actions/checkout@v2 + uses: actions/checkout@v4 - name: Checkout master if: ${{ github.event_name != 'pull_request' }} - uses: actions/checkout@v2 + uses: actions/checkout@v4 with: ref: master fetch-depth: 0 @@ -49,13 +49,13 @@ jobs: with: node-version: '16.13.0' - - name: Setup .NET 5/6/7 - uses: actions/setup-dotnet@v3 + - name: Setup .NET 6/7/8 + uses: actions/setup-dotnet@v4 with: dotnet-version: | - 5.0.x 6.0.x 7.0.x + 8.0.x - name: Configure NuGet uses: nuget/setup-nuget@v1 @@ -94,7 +94,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout commit - uses: actions/checkout@v2 + uses: actions/checkout@v4 - uses: actions/download-artifact@v1 with: diff --git a/.github/workflows/release-github.yml b/.github/workflows/release-github.yml index 22315d6..1302d8c 100644 --- a/.github/workflows/release-github.yml +++ b/.github/workflows/release-github.yml @@ -22,7 +22,7 @@ jobs: steps: - name: Checkout master - uses: actions/checkout@v2 + uses: actions/checkout@v4 with: ref: master fetch-depth: 0 diff --git a/.github/workflows/release-nuget.yml b/.github/workflows/release-nuget.yml index 9f8bb35..853e679 100644 --- a/.github/workflows/release-nuget.yml +++ b/.github/workflows/release-nuget.yml @@ -22,7 +22,7 @@ jobs: steps: - name: Checkout master - uses: actions/checkout@v2 + uses: actions/checkout@v4 with: ref: master fetch-depth: 0 From 79fcbfe9b137aa2dd0708ca8de448a32c06ef3dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=BCseyin=20Sekmeno=C4=9Flu?= Date: Fri, 7 Jun 2024 15:55:34 +0300 Subject: [PATCH 3/4] fixed net versions of umbraco packages --- .../Cogworks.AzureSearch.IoC.Umbraco.csproj | 4 ++-- .../Cogworks.AzureSearch.IoC.Umbraco.UnitTests.csproj | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Cogworks.AzureSearch.IoC.Umbraco/Cogworks.AzureSearch.IoC.Umbraco.csproj b/src/Cogworks.AzureSearch.IoC.Umbraco/Cogworks.AzureSearch.IoC.Umbraco.csproj index f8b4d29..37b0496 100644 --- a/src/Cogworks.AzureSearch.IoC.Umbraco/Cogworks.AzureSearch.IoC.Umbraco.csproj +++ b/src/Cogworks.AzureSearch.IoC.Umbraco/Cogworks.AzureSearch.IoC.Umbraco.csproj @@ -16,11 +16,11 @@ - + - + diff --git a/tests/UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests.csproj b/tests/UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests.csproj index 25a43dc..d776364 100644 --- a/tests/UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests.csproj +++ b/tests/UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests.csproj @@ -42,11 +42,11 @@ - + - + From b6856e3872b7de8dfc12e771d530579f5bb30db3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=BCseyin=20Sekmeno=C4=9Flu?= Date: Mon, 10 Jun 2024 11:50:19 +0300 Subject: [PATCH 4/4] fixed build error --- Directory.Build.props | 2 +- .../Cogworks.AzureSearch.IoC.Umbraco.csproj | 2 +- .../Cogworks.AzureSearch.IoC.Umbraco.UnitTests.csproj | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Directory.Build.props b/Directory.Build.props index c228a49..2172f42 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -16,7 +16,7 @@ net8.0;net7.0;net6.0 latest - 1591;1701;1702;8032;NU1701;AD0001;CA1041;CS0311;CS5001 + 1591;1701;1702;8032;NU1701;NU1902;AD0001;CA1041;CS0311;CS5001 false true false diff --git a/src/Cogworks.AzureSearch.IoC.Umbraco/Cogworks.AzureSearch.IoC.Umbraco.csproj b/src/Cogworks.AzureSearch.IoC.Umbraco/Cogworks.AzureSearch.IoC.Umbraco.csproj index 37b0496..06fa4d1 100644 --- a/src/Cogworks.AzureSearch.IoC.Umbraco/Cogworks.AzureSearch.IoC.Umbraco.csproj +++ b/src/Cogworks.AzureSearch.IoC.Umbraco/Cogworks.AzureSearch.IoC.Umbraco.csproj @@ -16,7 +16,7 @@ - + diff --git a/tests/UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests.csproj b/tests/UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests.csproj index d776364..be658ea 100644 --- a/tests/UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests.csproj +++ b/tests/UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests/Cogworks.AzureSearch.IoC.Umbraco.UnitTests.csproj @@ -6,7 +6,7 @@ net8.0;net7.0;net6.0 latest - 1591;1701;1702;8032;NU1701;AD0001;CA1041;CS0311;CS5001 + 1591;1701;1702;8032;NU1701;NU1902;AD0001;CA1041;CS0311;CS5001 false true false @@ -42,7 +42,7 @@ - +