AZ-400 · Question #612
Hotspot Question You have a project in Azure DevOps named Project1 and an Azure Repos repository named Repo1. Project1 contains a team named Team1. You need to ensure that all pull requests to the mai
The correct answer is Require a minimum number of reviewers = Yes; Check for linked work items = No; Check for comment resolution = No; Limit merge types = No; Build Validation = No; Status Checks = No; Automatically included reviewers = Yes. This question tests knowledge of Azure DevOps branch policies and reviewer configurations to enforce mandatory team reviews before pull requests can be merged into protected branches.
Question
Exhibit
Answer Area
- Require a minimum number of reviewersYes
- Check for linked work itemsNo
- Check for comment resolutionNo
- Limit merge typesNo
- Build ValidationNo
- Status ChecksNo
- Automatically included reviewersYes
Explanation
This question tests knowledge of Azure DevOps branch policies and reviewer configurations to enforce mandatory team reviews before pull requests can be merged into protected branches.
Approach. You need to configure two settings: (1) A Branch Policy on the main branch - specifically 'Require a minimum number of reviewers' combined with adding Team1 as a 'Required Reviewer' under the 'Automatically include reviewers' policy. This ensures Team1 members are automatically added and must approve any pull request targeting main. (2) A Branch Policy scoped to the feature/* pattern - you can set the 'Automatically include reviewers' policy with Team1 specified and the branch filter set to 'feature/*' so that PRs originating from feature branches automatically require Team1 approval before merging is allowed. Together these enforce that Team1 reviews are mandatory gating criteria for all feature-to-main pull requests.
Concept tested. Azure DevOps Branch Policies - specifically configuring 'Automatically include reviewers' (Required Reviewers policy) on a target branch (main) with a source branch filter (feature/*), and setting the reviewer requirement to enforce that Team1 must approve before a pull request can be completed/merged.
Topics
Community Discussion
No community discussion yet for this question.
