diff --git a/build/azure-pipelines.yml b/build/azure-pipelines.yml index cf80f9ef7b..a1b519d000 100644 --- a/build/azure-pipelines.yml +++ b/build/azure-pipelines.yml @@ -78,24 +78,13 @@ stages: vmImage: "windows-latest" steps: - checkout: self - submodules: true + submodules: false + lfs: false, + fetchDepth: 500 - task: UseDotNet@2 displayName: Use .NET SDK from global.json inputs: useGlobalJson: true - - template: templates/backoffice-install.yml - - script: npm run build:for:cms - displayName: Run build (Bellissima) - workingDirectory: src/Umbraco.Web.UI.Client - - script: npm run check:paths - displayName: Run check:paths - workingDirectory: src/Umbraco.Web.UI.Client - - script: npm ci --no-fund --no-audit --prefer-offline - displayName: Run npm ci (Login) - workingDirectory: src/Umbraco.Web.UI.Login - - script: npm run build - displayName: Run npm build (Login) - workingDirectory: src/Umbraco.Web.UI.Login - task: DotNetCoreCLI@2 displayName: Run dotnet restore inputs: @@ -125,7 +114,10 @@ stages: vmImage: "ubuntu-latest" steps: - checkout: self - submodules: true + submodules: false + lfs: false, + fetchDepth: 1 + fetchFilter: tree:0 - template: templates/backoffice-install.yml - script: npm run build:for:npm displayName: Run build:for:npm @@ -209,7 +201,10 @@ stages: BASE_PATH: /v$(umbracoMajorVersion)/ui steps: - checkout: self - submodules: true + submodules: false + lfs: false, + fetchDepth: 1 + fetchFilter: tree:0 - template: templates/backoffice-install.yml - script: npm run storybook:build displayName: Build Storybook @@ -266,6 +261,11 @@ stages: pool: vmImage: $(vmImage) steps: + - checkout: self + submodules: false + lfs: false, + fetchDepth: 1 + fetchFilter: tree:0 - task: DownloadPipelineArtifact@2 displayName: Download build artifacts inputs: @@ -306,6 +306,11 @@ stages: variables: Tests__Database__DatabaseType: "Sqlite" steps: + - checkout: self + submodules: false + lfs: false, + fetchDepth: 1 + fetchFilter: tree:0 # Setup test environment - task: DownloadPipelineArtifact@2 displayName: Download build artifacts diff --git a/src/Umbraco.Cms.Persistence.EFCore/Locking/SqlServerEFCoreDistributedLockingMechanism.cs b/src/Umbraco.Cms.Persistence.EFCore/Locking/SqlServerEFCoreDistributedLockingMechanism.cs index 38cdeef114..91342c386f 100644 --- a/src/Umbraco.Cms.Persistence.EFCore/Locking/SqlServerEFCoreDistributedLockingMechanism.cs +++ b/src/Umbraco.Cms.Persistence.EFCore/Locking/SqlServerEFCoreDistributedLockingMechanism.cs @@ -170,7 +170,9 @@ internal class SqlServerEFCoreDistributedLockingMechanism : IDistributedLocki "A transaction with minimum ReadCommitted isolation level is required."); } - var rowsAffected = await dbContext.Database.ExecuteSqlAsync(@$"SET LOCK_TIMEOUT {(int)_timeout.TotalMilliseconds};UPDATE umbracoLock WITH (REPEATABLEREAD) SET value = (CASE WHEN (value=1) THEN -1 ELSE 1 END) WHERE id={LockId}"); +#pragma warning disable EF1002 + var rowsAffected = await dbContext.Database.ExecuteSqlRawAsync(@$"SET LOCK_TIMEOUT {(int)_timeout.TotalMilliseconds};UPDATE umbracoLock WITH (REPEATABLEREAD) SET value = (CASE WHEN (value=1) THEN -1 ELSE 1 END) WHERE id={LockId}"); +#pragma warning restore EF1002 if (rowsAffected == 0) { diff --git a/tests/Umbraco.Tests.Integration/Testing/UmbracoIntegrationTest.cs b/tests/Umbraco.Tests.Integration/Testing/UmbracoIntegrationTest.cs index 39e6c8ac04..7f7d1d06e4 100644 --- a/tests/Umbraco.Tests.Integration/Testing/UmbracoIntegrationTest.cs +++ b/tests/Umbraco.Tests.Integration/Testing/UmbracoIntegrationTest.cs @@ -84,7 +84,11 @@ public abstract class UmbracoIntegrationTest : UmbracoIntegrationTestBase } [TearDown] - public void TearDownAsync() => _host.StopAsync(); + public void TearDownAsync() + { + _host.StopAsync(); + Services.DisposeIfDisposable(); + } /// /// Create the Generic Host and execute startup ConfigureServices/Configure calls