Update Internal CI to Run for Internal PRs
@@ -27,7 +27,12 @@ stages:
- stage: build_windows
displayName: Build Windows
dependsOn: []
- condition: startsWith(variables['Build.SourceBranch'], 'refs/heads/integration/')
+ condition: |
+ or
+ (
+ startsWith(variables['Build.SourceBranch'], 'refs/pull'),
+ startsWith(variables['Build.SourceBranch'], 'refs/heads/integration/')
+ )
jobs:
- template: ./templates/build-config-user.yml
parameters:
@@ -57,7 +62,12 @@ stages:
- stage: build_winkernel
displayName: Build Windows Drivers
dependsOn: []
- condition: startsWith(variables['Build.SourceBranch'], 'refs/heads/integration/')
+ condition: |
+ or
+ (
+ startsWith(variables['Build.SourceBranch'], 'refs/pull'),
+ startsWith(variables['Build.SourceBranch'], 'refs/heads/integration/')
+ )
jobs:
- template: ./templates/build-config-winkernel.yml
parameters:
@@ -80,7 +90,16 @@ stages:
displayName: Build Verification Tests
dependsOn:
- build_windows
- condition: and(succeeded(), startsWith(variables['Build.SourceBranch'], 'refs/heads/integration/'))
+ condition: |
+ and
+ (
+ or
+ (
+ startsWith(variables['Build.SourceBranch'], 'refs/pull'),
+ startsWith(variables['Build.SourceBranch'], 'refs/heads/integration/')
+ ),
+ succeeded()
+ )
jobs:
- template: ./templates/run-bvt-int.yml
parameters:
@@ -95,7 +114,7 @@ stages:
dependsOn:
- build_windows
- build_winkernel
- condition: and(succeeded(), startsWith(variables['Build.SourceBranch'], 'refs/heads/integration/'))
+ condition: and(startsWith(variables['Build.SourceBranch'], 'refs/heads/integration/'), succeeded())
jobs:
- template: ./templates/create-package.yml
@@ -106,7 +125,12 @@ stages:
- stage: integrate
displayName: Integrate Branch
dependsOn: []
- condition: not(startsWith(variables['Build.SourceBranch'], 'refs/heads/integration/'))
+ condition: |
+ and
+ (
+ not(startsWith(variables['Build.SourceBranch'], 'refs/pull')),
+ not(startsWith(variables['Build.SourceBranch'], 'refs/heads/integration/'))
+ )
jobs:
- job: integrate
displayName: Integrate Branch
