Skip to content

Commit 41ed13c

Browse files
authored
Merge pull request #602 from microsoftgraph/bugfix/compliance
bugfix/compliance
2 parents 7107766 + 1dd4b63 commit 41ed13c

File tree

3 files changed

+17
-3
lines changed

3 files changed

+17
-3
lines changed

.github/CODEOWNERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
@microsoftgraph/msgraph-devx-python-write
1+
* @microsoftgraph/msgraph-devx-python-write

.github/policies/msgraph-sdk-python-core.yml renamed to .github/policies/msgraph-sdk-python-core-branch-protection.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
# Copyright (c) Microsoft Corporation.
22
# Licensed under the MIT License.
33

4-
# File initially created using https://github.com/MIchaelMainer/policyservicetoolkit/blob/main/branch_protection_export.ps1.
5-
64
name: msgraph-sdk-python-core-branch-protection
75
description: Branch protection policy for the msgraph-sdk-python-core repository
86
resource: repository
@@ -37,6 +35,7 @@ configuration:
3735
# existing status check, the status check will be stuck on pending for status since nothing exists to push an actual status
3836
requiredStatusChecks:
3937
- CodeQL
38+
- check-build-matrix
4039
# Require branches to be up to date before merging. Requires requiredStatusChecks. boolean
4140
requiresStrictStatusChecks: true
4241
# Indicates whether there are restrictions on who can push. boolean. Should be set with whoCanPush.
@@ -72,6 +71,7 @@ configuration:
7271
# existing status check, the status check will be stuck on pending for status since nothing exists to push an actual status
7372
requiredStatusChecks:
7473
- CodeQL
74+
- check-build-matrix
7575
# Require branches to be up to date before merging. Requires requiredStatusChecks. boolean
7676
requiresStrictStatusChecks: true
7777
# Indicates whether there are restrictions on who can push. boolean. Should be set with whoCanPush.

.github/workflows/build.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,3 +48,17 @@ jobs:
4848
AZURE_CLIENT_ID: ${{ secrets.AZURE_CLIENT_ID }}
4949
AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }}
5050
AZURE_CLIENT_SECRET: ${{ secrets.AZURE_CLIENT_SECRET }}
51+
52+
# The check-build-matrix returns success if all matrix jobs in build are successful; otherwise, it returns a failure.
53+
# Use this as a PR status check for GitHub Policy Service instead of individual matrix entry checks.
54+
check-build-matrix:
55+
runs-on: ubuntu-latest
56+
needs: build
57+
if: always()
58+
steps:
59+
- name: All build matrix options are successful
60+
if: ${{ !(contains(needs.*.result, 'failure')) }}
61+
run: exit 0
62+
- name: One or more build matrix options failed
63+
if: ${{ contains(needs.*.result, 'failure') }}
64+
run: exit 1

0 commit comments

Comments
 (0)