Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
62 changes: 62 additions & 0 deletions .azure/pipelines/components-e2e-tests-internal.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
#
# See https://learn.microsoft.com/azure/devops/pipelines/yaml-schema for details on this file.
#

# Configure which branches trigger builds
trigger: none

pr:
autoCancel: true
branches:
include:
- '*'
paths:
include:
- eng/*
- src/Components/*
- src/Extensions/*
- src/Framework/*
- src/Hosting/*
- src/Http/*
- src/Middleware/HttpLogging/*
- src/Middleware/HttpOverrides/*
- src/Middleware/HttpsPolicy/*
- src/Middleware/Localization/*
- src/Middleware/Session/*
- src/Middleware/StaticFiles/*
- src/Middleware/WebSockets/*
- src/Servers/*
- src/SignalR/*
exclude:
- '**/*.md'

variables:
- name: DOTNET_SKIP_FIRST_TIME_EXPERIENCE
value: true
- name: EXECUTE_COMPONENTS_E2E_TESTS
value: true
- name: _TeamName
value: AspNetCore
- template: /eng/common/templates-official/variables/pool-providers.yml@self

resources:
repositories:
# Repo: 1ESPipelineTemplates/1ESPipelineTemplates
- repository: 1esPipelines
type: git
name: 1ESPipelineTemplates/1ESPipelineTemplates
ref: refs/tags/release

extends:
template: v1/1ES.Unofficial.PipelineTemplate.yml@1esPipelines
parameters:
sdl:
sourceAnalysisPool:
name: NetCore1ESPool-Svc-Internal
image: windows.vs2022.amd64
os: windows
stages:
- stage: test
displayName: Test
jobs:
- template: .azure/pipelines/jobs/components-e2e-test-job.yml@self
56 changes: 1 addition & 55 deletions .azure/pipelines/components-e2e-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,58 +28,4 @@ variables:
- template: /eng/common/templates/variables/pool-providers.yml

jobs:
- template: jobs/default-build.yml
parameters:
jobName: Components_E2E_Test
jobDisplayName: "Test: Blazor E2E tests on Linux"
agentOs: Linux
isAzDOTestingJob: true
enablePublishTestResults: false
timeoutInMinutes: 120
steps:
- script: git submodule update --init
displayName: Update submodules
- script: ./restore.sh
displayName: Run restore.sh
- script: yarn install --frozen-lockfile --cwd ./src/Components/test/E2ETest || yarn install --frozen-lockfile --cwd ./src/Components/test/E2ETest
displayName: NPM install
- script: .dotnet/dotnet build ./src/Components/test/E2ETest -c $(BuildConfiguration) --no-restore
displayName: Build
- script: .dotnet/dotnet test ./src/Components/test/E2ETest -c $(BuildConfiguration) --no-build --filter 'Quarantined!=true|Quarantined=false'
--logger:"trx%3BLogFileName=Microsoft.AspNetCore.Components.E2ETests.trx"
--logger:"html%3BLogFileName=Microsoft.AspNetCore.Components.E2ETests.html"
--results-directory $(Build.SourcesDirectory)/artifacts/TestResults/$(BuildConfiguration)/Unquarantined
displayName: Run E2E tests
- script: .dotnet/dotnet test ./src/Components/test/E2ETest -c $(BuildConfiguration) --no-build --filter 'Quarantined=true' -p:RunQuarantinedTests=true
--logger:"trx%3BLogFileName=Microsoft.AspNetCore.Components.E2ETests.trx"
--logger:"html%3BLogFileName=Microsoft.AspNetCore.Components.E2ETests.html"
--results-directory $(Build.SourcesDirectory)/artifacts/TestResults/$(BuildConfiguration)/Quarantined
displayName: Run Quarantined E2E tests
continueOnError: true
- task: PublishTestResults@2
displayName: Publish E2E Test Results
inputs:
testResultsFormat: 'VSTest'
testResultsFiles: '*.trx'
searchFolder: '$(Build.SourcesDirectory)/artifacts/TestResults/$(BuildConfiguration)/Unquarantined'
testRunTitle: ComponentsE2E-$(AgentOsName)-$(BuildConfiguration)-xunit
condition: always()
- task: PublishTestResults@2
displayName: Publish Quarantined E2E Test Results
inputs:
testResultsFormat: 'VSTest'
testResultsFiles: '*.trx'
searchFolder: '$(Build.SourcesDirectory)/artifacts/TestResults/$(BuildConfiguration)/Quarantined'
testRunTitle: Quarantine-$(AgentOsName)-$(BuildConfiguration)-xunit
mergeTestResults: true
condition: always()

artifacts:
- name: Components_E2E_Logs
path: artifacts/log/
publishOnError: true
includeForks: true
- name: Components_E2E_Test_Logs
path: '$(Build.SourcesDirectory)/artifacts/TestResults/$(BuildConfiguration)'
includeForks: true
publishOnError: true
- template: jobs/components-e2e-test-job.yml
60 changes: 60 additions & 0 deletions .azure/pipelines/jobs/components-e2e-test-job.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# components-e2e-test-job.yml
# Shared job definition for Components E2E tests.
# Used by both components-e2e-tests.yml and components-e2e-tests-internal.yml.

jobs:
- template: default-build.yml
Comment on lines +5 to +6
parameters:
jobName: Components_E2E_Test
jobDisplayName: "Test: Blazor E2E tests on Linux"
agentOs: Linux
isAzDOTestingJob: true
enablePublishTestResults: false
timeoutInMinutes: 120
steps:
- script: git submodule update --init
displayName: Update submodules
- script: ./restore.sh
displayName: Run restore.sh
- script: yarn install --frozen-lockfile --cwd ./src/Components/test/E2ETest || yarn install --frozen-lockfile --cwd ./src/Components/test/E2ETest
displayName: NPM install
Comment on lines +19 to +20
- script: .dotnet/dotnet build ./src/Components/test/E2ETest -c $(BuildConfiguration) --no-restore
displayName: Build
- script: .dotnet/dotnet test ./src/Components/test/E2ETest -c $(BuildConfiguration) --no-build --filter 'Quarantined!=true|Quarantined=false'
--logger:"trx%3BLogFileName=Microsoft.AspNetCore.Components.E2ETests.trx"
--logger:"html%3BLogFileName=Microsoft.AspNetCore.Components.E2ETests.html"
--results-directory $(Build.SourcesDirectory)/artifacts/TestResults/$(BuildConfiguration)/Unquarantined
displayName: Run E2E tests
- script: .dotnet/dotnet test ./src/Components/test/E2ETest -c $(BuildConfiguration) --no-build --filter 'Quarantined=true' -p:RunQuarantinedTests=true
--logger:"trx%3BLogFileName=Microsoft.AspNetCore.Components.E2ETests.trx"
--logger:"html%3BLogFileName=Microsoft.AspNetCore.Components.E2ETests.html"
--results-directory $(Build.SourcesDirectory)/artifacts/TestResults/$(BuildConfiguration)/Quarantined
displayName: Run Quarantined E2E tests
continueOnError: true
- task: PublishTestResults@2
displayName: Publish E2E Test Results
inputs:
testResultsFormat: 'VSTest'
testResultsFiles: '*.trx'
searchFolder: '$(Build.SourcesDirectory)/artifacts/TestResults/$(BuildConfiguration)/Unquarantined'
testRunTitle: ComponentsE2E-$(AgentOsName)-$(BuildConfiguration)-xunit
condition: always()
- task: PublishTestResults@2
displayName: Publish Quarantined E2E Test Results
inputs:
testResultsFormat: 'VSTest'
testResultsFiles: '*.trx'
searchFolder: '$(Build.SourcesDirectory)/artifacts/TestResults/$(BuildConfiguration)/Quarantined'
testRunTitle: Quarantine-$(AgentOsName)-$(BuildConfiguration)-xunit
mergeTestResults: true
condition: always()

artifacts:
- name: Components_E2E_Logs
path: artifacts/log/
publishOnError: true
includeForks: true
- name: Components_E2E_Test_Logs
path: '$(Build.SourcesDirectory)/artifacts/TestResults/$(BuildConfiguration)'
includeForks: true
publishOnError: true
Loading