Skip to content

Commit f139aae

Browse files
Merge branch 'v15/dev' into contrib
2 parents d0799b1 + dc2dc09 commit f139aae

File tree

1,742 files changed

+24866
-7889
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,742 files changed

+24866
-7889
lines changed

Directory.Packages.props

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,13 @@
33
<PropertyGroup>
44
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
55
</PropertyGroup>
6-
76
<!-- Global packages (private, build-time packages for all projects) -->
87
<ItemGroup>
98
<GlobalPackageReference Include="Nerdbank.GitVersioning" Version="3.6.146" />
109
<GlobalPackageReference Include="StyleCop.Analyzers" Version="1.2.0-beta.556" />
1110
<GlobalPackageReference Include="Umbraco.Code" Version="2.2.0" />
1211
<GlobalPackageReference Include="Umbraco.GitVersioning.Extensions" Version="0.2.0" />
1312
</ItemGroup>
14-
1513
<!-- Microsoft packages -->
1614
<ItemGroup>
1715
<PackageVersion Include="Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation" Version="9.0.0" />
@@ -37,20 +35,18 @@
3735
<PackageVersion Include="Microsoft.Extensions.Options.DataAnnotations" Version="9.0.0" />
3836
<PackageVersion Include="Microsoft.Extensions.Caching.Hybrid" Version="9.0.0-preview.9.24556.5" />
3937
</ItemGroup>
40-
4138
<!-- Umbraco packages -->
4239
<ItemGroup>
4340
<PackageVersion Include="Umbraco.JsonSchema.Extensions" Version="0.3.0" />
4441
<PackageVersion Include="Umbraco.CSharpTest.Net.Collections" Version="15.0.0" />
4542
</ItemGroup>
46-
4743
<!-- Third-party packages -->
4844
<ItemGroup>
4945
<PackageVersion Include="Asp.Versioning.Mvc" Version="8.1.0" />
5046
<PackageVersion Include="Asp.Versioning.Mvc.ApiExplorer" Version="8.1.0" />
5147
<PackageVersion Include="Dazinator.Extensions.FileProviders" Version="2.0.0" />
52-
<PackageVersion Include="Examine" Version="3.4.0" />
53-
<PackageVersion Include="Examine.Core" Version="3.4.0" />
48+
<PackageVersion Include="Examine" Version="3.5.0" />
49+
<PackageVersion Include="Examine.Core" Version="3.5.0" />
5450
<PackageVersion Include="HtmlAgilityPack" Version="1.11.71" />
5551
<PackageVersion Include="JsonPatch.Net" Version="3.1.1" />
5652
<PackageVersion Include="K4os.Compression.LZ4" Version="1.3.8" />
@@ -77,14 +73,14 @@
7773
<PackageVersion Include="Serilog.Sinks.Async" Version="2.1.0" />
7874
<PackageVersion Include="Serilog.Sinks.File" Version="6.0.0" />
7975
<PackageVersion Include="Serilog.Sinks.Map" Version="2.0.0" />
80-
<PackageVersion Include="SixLabors.ImageSharp" Version="3.1.5" />
76+
<PackageVersion Include="SixLabors.ImageSharp" Version="3.1.6" />
8177
<PackageVersion Include="SixLabors.ImageSharp.Web" Version="3.1.3" />
82-
<PackageVersion Include="Swashbuckle.AspNetCore" Version="7.0.0" />
78+
<PackageVersion Include="Swashbuckle.AspNetCore" Version="7.1.0" />
8379
</ItemGroup>
84-
8580
<!-- Transitive pinned versions (only required because our direct dependencies have vulnerable versions of transitive dependencies) -->
8681
<ItemGroup>
8782
<!-- Microsoft.EntityFrameworkCore.SqlServer and NPoco.SqlServer brings in a vulnerable version of Azure.Identity -->
83+
<!-- Take top-level depedendency on Azure.Identity, because Microsoft.EntityFrameworkCore.SqlServer depends on a vulnerable version -->
8884
<PackageVersion Include="Azure.Identity" Version="1.13.1" />
8985
<!-- Microsoft.EntityFrameworkCore.SqlServer brings in a vulnerable version of System.Runtime.Caching -->
9086
<PackageVersion Include="System.Runtime.Caching" Version="9.0.0" />
@@ -95,12 +91,13 @@
9591
<!-- Dazinator.Extensions.FileProviders and MiniProfiler.AspNetCore.Mvc brings in a vulnerable version of System.Text.RegularExpressions -->
9692
<PackageVersion Include="System.Text.RegularExpressions" Version="4.3.1" />
9793
<!-- OpenIddict.AspNetCore, Npoco.SqlServer and Microsoft.EntityFrameworkCore.SqlServer brings in a vulnerable version of Microsoft.IdentityModel.JsonWebTokens -->
98-
<PackageVersion Include="Microsoft.IdentityModel.JsonWebTokens" Version="8.2.0" />
94+
<!-- Take top-level depedendency on Microsoft.IdentityModel.JsonWebTokens, because OpenIddict.AspNetCore, Npoco.SqlServer and Microsoft.EntityFrameworkCore.SqlServer depends on a vulnerable version -->
95+
<PackageVersion Include="Microsoft.IdentityModel.JsonWebTokens" Version="8.2.1" />
9996
<!-- Azure.Identity, Microsoft.EntityFrameworkCore.SqlServer and Dazinator.Extensions.FileProviders brings in a legacy version of System.Text.Encodings.Web -->
10097
<PackageVersion Include="System.Text.Encodings.Web" Version="9.0.0" />
10198
<!-- NPoco.SqlServer brings in a vulnerable version of Microsoft.Data.SqlClient -->
10299
<PackageVersion Include="Microsoft.Data.SqlClient" Version="5.2.2" />
103100
<!-- Examine.Lucene brings in a vulnerable version of Lucene.Net.Replicator -->
104101
<PackageVersion Include="Lucene.Net.Replicator" Version="4.8.0-beta00017" />
105102
</ItemGroup>
106-
</Project>
103+
</Project>

build/azure-pipelines.yml

Lines changed: 125 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -78,24 +78,14 @@ stages:
7878
vmImage: "windows-latest"
7979
steps:
8080
- checkout: self
81-
submodules: true
81+
submodules: false
82+
lfs: false,
83+
fetchDepth: 500
84+
- template: templates/backoffice-install.yml
8285
- task: UseDotNet@2
8386
displayName: Use .NET SDK from global.json
8487
inputs:
8588
useGlobalJson: true
86-
- template: templates/backoffice-install.yml
87-
- script: npm run build:for:cms
88-
displayName: Run build (Bellissima)
89-
workingDirectory: src/Umbraco.Web.UI.Client
90-
- script: npm run check:paths
91-
displayName: Run check:paths
92-
workingDirectory: src/Umbraco.Web.UI.Client
93-
- script: npm ci --no-fund --no-audit --prefer-offline
94-
displayName: Run npm ci (Login)
95-
workingDirectory: src/Umbraco.Web.UI.Login
96-
- script: npm run build
97-
displayName: Run npm build (Login)
98-
workingDirectory: src/Umbraco.Web.UI.Login
9989
- task: DotNetCoreCLI@2
10090
displayName: Run dotnet restore
10191
inputs:
@@ -125,7 +115,10 @@ stages:
125115
vmImage: "ubuntu-latest"
126116
steps:
127117
- checkout: self
128-
submodules: true
118+
submodules: false
119+
lfs: false,
120+
fetchDepth: 1
121+
fetchFilter: tree:0
129122
- template: templates/backoffice-install.yml
130123
- script: npm run build:for:npm
131124
displayName: Run build:for:npm
@@ -209,7 +202,10 @@ stages:
209202
BASE_PATH: /v$(umbracoMajorVersion)/ui
210203
steps:
211204
- checkout: self
212-
submodules: true
205+
submodules: false
206+
lfs: false,
207+
fetchDepth: 1
208+
fetchFilter: tree:0
213209
- template: templates/backoffice-install.yml
214210
- script: npm run storybook:build
215211
displayName: Build Storybook
@@ -266,6 +262,11 @@ stages:
266262
pool:
267263
vmImage: $(vmImage)
268264
steps:
265+
- checkout: self
266+
submodules: false
267+
lfs: false,
268+
fetchDepth: 1
269+
fetchFilter: tree:0
269270
- task: DownloadPipelineArtifact@2
270271
displayName: Download build artifacts
271272
inputs:
@@ -297,15 +298,41 @@ stages:
297298
matrix:
298299
# Windows:
299300
# vmImage: 'windows-latest'
300-
Linux:
301+
# We split the tests into 3 parts for each OS to reduce the time it takes to run them on the pipeline
302+
LinuxPart1Of3:
301303
vmImage: "ubuntu-latest"
302-
macOS:
304+
# Filter tests that are part of the Umbraco.Infrastructure namespace but not part of the Umbraco.Infrastructure.Service namespace
305+
testFilter: "(FullyQualifiedName~Umbraco.Infrastructure) & (FullyQualifiedName!~Umbraco.Infrastructure.Service)"
306+
LinuxPart2Of3:
307+
vmImage: "ubuntu-latest"
308+
# Filter tests that are part of the Umbraco.Infrastructure.Service namespace
309+
testFilter: "(FullyQualifiedName~Umbraco.Infrastructure.Service)"
310+
LinuxPart3Of3:
311+
vmImage: "ubuntu-latest"
312+
# Filter tests that are not part of the Umbraco.Infrastructure namespace. So this will run all tests that are not part of the Umbraco.Infrastructure namespace
313+
testFilter: "(FullyQualifiedName!~Umbraco.Infrastructure)"
314+
macOSPart1Of3:
315+
vmImage: "macOS-latest"
316+
# Filter tests that are part of the Umbraco.Infrastructure namespace but not part of the Umbraco.Infrastructure.Service namespace
317+
testFilter: "(FullyQualifiedName~Umbraco.Infrastructure) & (FullyQualifiedName!~Umbraco.Infrastructure.Service)"
318+
macOSPart2Of3:
319+
vmImage: "macOS-latest"
320+
# Filter tests that are part of the Umbraco.Infrastructure.Service namespace
321+
testFilter: "(FullyQualifiedName~Umbraco.Infrastructure.Service)"
322+
macOSPart3Of3:
303323
vmImage: "macOS-latest"
324+
# Filter tests that are not part of the Umbraco.Infrastructure namespace.
325+
testFilter: "(FullyQualifiedName!~Umbraco.Infrastructure)"
304326
pool:
305327
vmImage: $(vmImage)
306328
variables:
307329
Tests__Database__DatabaseType: "Sqlite"
308330
steps:
331+
- checkout: self
332+
submodules: false
333+
lfs: false,
334+
fetchDepth: 1
335+
fetchFilter: tree:0
309336
# Setup test environment
310337
- task: DownloadPipelineArtifact@2
311338
displayName: Download build artifacts
@@ -326,14 +353,13 @@ stages:
326353
projects: "tests/Umbraco.Tests.Integration/Umbraco.Tests.Integration.csproj"
327354
testRunTitle: Integration Tests SQLite - $(Agent.OS)
328355
${{ if and(eq(variables['Agent.OS'],'Windows_NT'), or(variables.releaseTestFilter, parameters.forceReleaseTestFilter)) }}:
329-
arguments: "--configuration $(buildConfiguration) --no-build ${{parameters.integrationReleaseTestFilter}}"
356+
arguments: '--filter "$(testFilter)" --configuration $(buildConfiguration) --no-build ${{parameters.integrationReleaseTestFilter}}'
330357
${{ elseif eq(variables['Agent.OS'],'Windows_NT') }}:
331-
arguments: "--configuration $(buildConfiguration) --no-build ${{parameters.integrationNonReleaseTestFilter}}"
358+
arguments: '--filter "$(testFilter)" --configuration $(buildConfiguration) --no-build ${{parameters.integrationNonReleaseTestFilter}}'
332359
${{ elseif or(variables.releaseTestFilter, parameters.forceReleaseTestFilter) }}:
333-
arguments: "--configuration $(buildConfiguration) --no-build ${{parameters.nonWindowsIntegrationReleaseTestFilter}}"
360+
arguments: '--filter "$(testFilter)" --configuration $(buildConfiguration) --no-build ${{parameters.nonWindowsIntegrationReleaseTestFilter}}'
334361
${{ else }}:
335-
arguments: "--configuration $(buildConfiguration) --no-build ${{parameters.nonWindowsIntegrationNonReleaseTestFilter}}"
336-
362+
arguments: '--filter "$(testFilter)" --configuration $(buildConfiguration) --no-build ${{parameters.nonWindowsIntegrationNonReleaseTestFilter}}'
337363
# Integration Tests (SQL Server)
338364
- job:
339365
timeoutInMinutes: 180
@@ -342,15 +368,46 @@ stages:
342368
displayName: Integration Tests (SQL Server)
343369
strategy:
344370
matrix:
345-
Windows:
371+
# We split the tests into 3 parts for each OS to reduce the time it takes to run them on the pipeline
372+
WindowsPart1Of3:
346373
vmImage: "windows-latest"
347374
Tests__Database__DatabaseType: LocalDb
348375
Tests__Database__SQLServerMasterConnectionString: N/A
349-
Linux:
376+
# Filter tests that are part of the Umbraco.Infrastructure namespace but not part of the Umbraco.Infrastructure.Service namespace
377+
testFilter: "(FullyQualifiedName~Umbraco.Infrastructure) & (FullyQualifiedName!~Umbraco.Infrastructure.Service)"
378+
WindowsPart2Of3:
379+
vmImage: "windows-latest"
380+
Tests__Database__DatabaseType: LocalDb
381+
Tests__Database__SQLServerMasterConnectionString: N/A
382+
# Filter tests that are part of the Umbraco.Infrastructure.Service namespace
383+
testFilter: "(FullyQualifiedName~Umbraco.Infrastructure.Service)"
384+
WindowsPart3Of3:
385+
vmImage: "windows-latest"
386+
Tests__Database__DatabaseType: LocalDb
387+
Tests__Database__SQLServerMasterConnectionString: N/A
388+
# Filter tests that are not part of the Umbraco.Infrastructure namespace. So this will run all tests that are not part of the Umbraco.Infrastructure namespace
389+
testFilter: "(FullyQualifiedName!~Umbraco.Infrastructure)"
390+
LinuxPart1Of3:
350391
vmImage: "ubuntu-latest"
351392
SA_PASSWORD: UmbracoIntegration123!
352393
Tests__Database__DatabaseType: SqlServer
353394
Tests__Database__SQLServerMasterConnectionString: "Server=(local);User Id=sa;Password=$(SA_PASSWORD);TrustServerCertificate=True"
395+
# Filter tests that are part of the Umbraco.Infrastructure namespace but not part of the Umbraco.Infrastructure.Service namespace
396+
testFilter: "(FullyQualifiedName~Umbraco.Infrastructure) & (FullyQualifiedName!~Umbraco.Infrastructure.Service)"
397+
LinuxPart2Of3:
398+
vmImage: "ubuntu-latest"
399+
SA_PASSWORD: UmbracoIntegration123!
400+
Tests__Database__DatabaseType: SqlServer
401+
Tests__Database__SQLServerMasterConnectionString: "Server=(local);User Id=sa;Password=$(SA_PASSWORD);TrustServerCertificate=True"
402+
# Filter tests that are part of the Umbraco.Infrastructure.Service namespace
403+
testFilter: "(FullyQualifiedName~Umbraco.Infrastructure.Service)"
404+
LinuxPart3Of3:
405+
vmImage: "ubuntu-latest"
406+
SA_PASSWORD: UmbracoIntegration123!
407+
Tests__Database__DatabaseType: SqlServer
408+
Tests__Database__SQLServerMasterConnectionString: "Server=(local);User Id=sa;Password=$(SA_PASSWORD);TrustServerCertificate=True"
409+
# Filter tests that are not part of the Umbraco.Infrastructure namespace. So this will run all tests that are not part of the Umbraco.Infrastructure namespace
410+
testFilter: "(FullyQualifiedName!~Umbraco.Infrastructure)"
354411
pool:
355412
vmImage: $(vmImage)
356413
steps:
@@ -383,13 +440,13 @@ stages:
383440
projects: "tests/Umbraco.Tests.Integration/Umbraco.Tests.Integration.csproj"
384441
testRunTitle: Integration Tests SQL Server - $(Agent.OS)
385442
${{ if and(eq(variables['Agent.OS'],'Windows_NT'), or(variables.releaseTestFilter, parameters.forceReleaseTestFilter)) }}:
386-
arguments: "--configuration $(buildConfiguration) --no-build ${{parameters.integrationReleaseTestFilter}}"
443+
arguments: '--filter "$(testFilter)" --configuration $(buildConfiguration) --no-build ${{parameters.integrationReleaseTestFilter}}'
387444
${{ elseif eq(variables['Agent.OS'],'Windows_NT') }}:
388-
arguments: "--configuration $(buildConfiguration) --no-build ${{parameters.integrationNonReleaseTestFilter}}"
445+
arguments: '--filter "$(testFilter)" --configuration $(buildConfiguration) --no-build ${{parameters.integrationNonReleaseTestFilter}}'
389446
${{ elseif or(variables.releaseTestFilter, parameters.forceReleaseTestFilter) }}:
390-
arguments: "--configuration $(buildConfiguration) --no-build ${{parameters.nonWindowsIntegrationReleaseTestFilter}}"
447+
arguments: '--filter "$(testFilter)" --configuration $(buildConfiguration) --no-build ${{parameters.nonWindowsIntegrationReleaseTestFilter}}'
391448
${{ else }}:
392-
arguments: "--configuration $(buildConfiguration) --no-build ${{parameters.nonWindowsIntegrationNonReleaseTestFilter}}"
449+
arguments: '--filter "$(testFilter)" --configuration $(buildConfiguration) --no-build ${{parameters.nonWindowsIntegrationNonReleaseTestFilter}}'
393450

394451
# Stop SQL Server
395452
- pwsh: docker stop mssql
@@ -434,10 +491,24 @@ stages:
434491
CONNECTIONSTRINGS__UMBRACODBDSN_PROVIDERNAME: Microsoft.Data.Sqlite
435492
strategy:
436493
matrix:
437-
Linux:
494+
LinuxPart1Of3:
438495
vmImage: "ubuntu-latest"
439-
Windows:
496+
testCommand: 'npx playwright test DefaultConfig --grep "@smoke" --shard=1/3'
497+
LinuxPart2Of3:
498+
vmImage: "ubuntu-latest"
499+
testCommand: 'npx playwright test DefaultConfig --grep "@smoke" --shard=2/3'
500+
LinuxPart3Of3:
501+
vmImage: "ubuntu-latest"
502+
testCommand: 'npx playwright test DefaultConfig --grep "@smoke" --shard=3/3'
503+
WindowsPart1Of3:
440504
vmImage: "windows-latest"
505+
testCommand: 'npx playwright test DefaultConfig --grep "@smoke" --shard=1/3'
506+
WindowsPart2Of3:
507+
vmImage: "windows-latest"
508+
testCommand: 'npx playwright test DefaultConfig --grep "@smoke" --shard=2/3'
509+
WindowsPart3Of3:
510+
vmImage: "windows-latest"
511+
testCommand: 'npx playwright test DefaultConfig --grep "@smoke" --shard=3/3'
441512
pool:
442513
vmImage: $(vmImage)
443514
steps:
@@ -521,7 +592,7 @@ stages:
521592
workingDirectory: tests/Umbraco.Tests.AcceptanceTest
522593

523594
# Test
524-
- pwsh: npm run smokeTestSqlite --ignore-certificate-errors
595+
- pwsh: $(testCommand)
525596
displayName: Run Playwright tests
526597
continueOnError: true
527598
workingDirectory: tests/Umbraco.Tests.AcceptanceTest
@@ -563,13 +634,31 @@ stages:
563634
CONNECTIONSTRINGS__UMBRACODBDSN_PROVIDERNAME: Microsoft.Data.SqlClient
564635
strategy:
565636
matrix:
566-
${{ if eq(parameters.sqlServerLinuxAcceptanceTests, True) }} :
567-
Linux:
637+
${{ if eq(parameters.sqlServerLinuxAcceptanceTests, True) }}:
638+
LinuxPart1Of3:
639+
testCommand: 'npx playwright test DefaultConfig --grep "@smoke" --grep-invert "Users" --shard=1/3'
568640
vmImage: "ubuntu-latest"
569641
SA_PASSWORD: $(UMBRACO__CMS__UNATTENDED__UNATTENDEDUSERPASSWORD)
570642
CONNECTIONSTRINGS__UMBRACODBDSN: "Server=(local);Database=Umbraco;User Id=sa;Password=$(SA_PASSWORD);TrustServerCertificate=True"
571-
Windows:
643+
LinuxPart2Of3:
644+
testCommand: 'npx playwright test DefaultConfig --grep "@smoke" --grep-invert "Users" --shard=2/3'
645+
vmImage: "ubuntu-latest"
646+
SA_PASSWORD: $(UMBRACO__CMS__UNATTENDED__UNATTENDEDUSERPASSWORD)
647+
CONNECTIONSTRINGS__UMBRACODBDSN: "Server=(local);Database=Umbraco;User Id=sa;Password=$(SA_PASSWORD);TrustServerCertificate=True"
648+
LinuxPart3Of3:
649+
testCommand: 'npx playwright test DefaultConfig --grep "@smoke" --grep-invert "Users" --shard=3/3'
650+
vmImage: "ubuntu-latest"
651+
SA_PASSWORD: $(UMBRACO__CMS__UNATTENDED__UNATTENDEDUSERPASSWORD)
652+
CONNECTIONSTRINGS__UMBRACODBDSN: "Server=(local);Database=Umbraco;User Id=sa;Password=$(SA_PASSWORD);TrustServerCertificate=True"
653+
WindowsPart1Of3:
654+
vmImage: "windows-latest"
655+
testCommand: 'npx playwright test DefaultConfig --grep "@smoke" --grep-invert "Users" --shard=1/3'
656+
WindowsPart2Of3:
657+
vmImage: "windows-latest"
658+
testCommand: 'npx playwright test DefaultConfig --grep "@smoke" --grep-invert "Users" --shard=2/3'
659+
WindowsPart3Of3:
572660
vmImage: "windows-latest"
661+
testCommand: 'npx playwright test DefaultConfig --grep "@smoke" --grep-invert "Users" --shard=3/3'
573662
pool:
574663
vmImage: $(vmImage)
575664
steps:
@@ -661,7 +750,7 @@ stages:
661750
workingDirectory: tests/Umbraco.Tests.AcceptanceTest
662751

663752
# Test
664-
- pwsh: npm run smokeTest --ignore-certificate-errors
753+
- pwsh: $(testCommand)
665754
displayName: Run Playwright tests
666755
continueOnError: true
667756
workingDirectory: tests/Umbraco.Tests.AcceptanceTest

0 commit comments

Comments
 (0)