Jump into concepts and practice - no test required
or
Recommended
Test this pattern10 questions across easy, medium, and hard to know if this pattern is strong
Recall & Review
beginner
What is Azure Repos?
Azure Repos is a set of version control tools that you can use to manage your code. It helps teams track changes and collaborate on software development.
Click to reveal answer
beginner
Name the two types of version control systems supported by Azure Repos.
Azure Repos supports Git (distributed version control) and Team Foundation Version Control (TFVC, centralized version control).
Click to reveal answer
beginner
How does Azure Repos help when multiple people work on the same code?
Azure Repos tracks changes from each person, helps merge their work, and keeps a history of all changes so conflicts can be resolved easily.
Click to reveal answer
intermediate
What is a pull request in Azure Repos?
A pull request is a way to ask team members to review and approve code changes before merging them into the main codebase.
Click to reveal answer
beginner
Why is it important to commit code changes frequently in Azure Repos?
Frequent commits make it easier to track progress, find bugs, and merge changes without conflicts. It keeps the project organized and safe.
Click to reveal answer
Which version control system is NOT supported by Azure Repos?
ASubversion (SVN)
BTeam Foundation Version Control (TFVC)
CGit
DBoth Git and TFVC
✗ Incorrect
Azure Repos supports Git and TFVC but does not support Subversion (SVN).
What is the main purpose of a pull request in Azure Repos?
ATo delete code from the repository
BTo clone the repository locally
CTo create a backup of the repository
DTo request code review and merge changes
✗ Incorrect
Pull requests are used to review and approve code changes before merging them into the main branch.
Which of the following best describes Git in Azure Repos?
ADistributed version control system
BContinuous integration tool
CCloud storage service
DCentralized version control system
✗ Incorrect
Git is a distributed version control system supported by Azure Repos.
What happens when two people edit the same file in Azure Repos using Git?
AAzure Repos automatically deletes one person's changes
BGit merges changes and may ask to resolve conflicts
CThe repository locks the file to one user only
DBoth changes are ignored
✗ Incorrect
Git tries to merge changes and if conflicts occur, it asks users to resolve them.
Why should you write clear commit messages in Azure Repos?
ATo increase repository size
BTo confuse other team members
CTo help track what changes were made and why
DTo prevent code from being merged
✗ Incorrect
Clear commit messages help everyone understand the purpose of changes and make collaboration easier.
Explain how Azure Repos supports team collaboration on code projects.
Think about how changes from different people are managed and reviewed.
You got /4 concepts.
Describe the difference between Git and TFVC in Azure Repos.
Consider how and where changes are saved and shared.
You got /4 concepts.
Practice
(1/5)
1. What is the main purpose of Azure Repos in software development?
easy
A. To design user interfaces
B. To store code safely and track changes over time
C. To run applications in the cloud
D. To manage virtual machines
Solution
Step 1: Understand Azure Repos role
Azure Repos is a service that stores source code and tracks changes made by developers.
Step 2: Compare options with Azure Repos function
Options A, B, and D describe other Azure services or tasks unrelated to source control.
Final Answer:
To store code safely and track changes over time -> Option B
Quick Check:
Azure Repos = Code storage and version tracking [OK]
Hint: Azure Repos is about code storage and history [OK]
Common Mistakes:
Confusing Azure Repos with Azure App Services
Thinking Azure Repos manages cloud infrastructure
Mixing source control with deployment services
2. Which Git command is used to send your local code changes to Azure Repos?
easy
A. git pull
B. git clone
C. git push
D. git branch
Solution
Step 1: Identify command to send changes
The git push command uploads local commits to the remote repository like Azure Repos.
Step 2: Understand other commands
git clone copies a repo, git pull fetches and merges changes, git branch manages branches.
Final Answer:
git push -> Option C
Quick Check:
Send changes = git push [OK]
Hint: Push means send your changes to the server [OK]
Common Mistakes:
Using git clone to send changes
Confusing git pull with git push
Thinking git branch sends code
3. Given this Git command sequence in Azure Repos:
A. A new branch 'feature1' is created locally and pushed to Azure Repos
B. The main branch is overwritten with feature1 changes
C. The repository is deleted from Azure Repos
D. The commit message is ignored
Solution
Step 1: Analyze branch creation and commit
git checkout -b feature1 creates and switches to a new branch named 'feature1'. The commit adds changes to this branch.
Step 2: Understand push command effect
git push -u origin feature1 uploads the new branch and sets it to track the remote branch in Azure Repos.
Final Answer:
A new branch 'feature1' is created locally and pushed to Azure Repos -> Option A
Quick Check:
Branch created and pushed = A new branch 'feature1' is created locally and pushed to Azure Repos [OK]
Hint: Checkout -b creates branch; push uploads it [OK]
Common Mistakes:
Assuming main branch is overwritten
Thinking repository is deleted
Ignoring the commit message effect
4. You try to push changes to Azure Repos but get an error about non-fast-forward updates. What should you do to fix this?
medium
A. Run git pull to update your local branch before pushing
B. Delete the remote repository and push again
C. Use git clone again to overwrite your local repo
D. Ignore the error and push with --force immediately
Solution
Step 1: Understand non-fast-forward error
This error means the remote branch has changes your local branch lacks, so push is rejected to avoid overwriting.
Step 2: Fix by syncing local branch
Running git pull fetches and merges remote changes into your local branch, resolving conflicts before push.
Final Answer:
Run git pull to update your local branch before pushing -> Option A
Quick Check:
Sync local branch first = git pull [OK]
Hint: Pull first to sync before pushing [OK]
Common Mistakes:
Forcing push without syncing
Deleting remote repo unnecessarily
Cloning again instead of pulling
5. Your team uses Azure Repos and wants to protect the main branch from direct changes. Which feature should you enable to require pull requests for all changes?
hard
A. Create a new repository for each developer
B. Enable Git Large File Storage (LFS)
C. Set up Azure Pipelines for continuous deployment
D. Branch policies with pull request requirements
Solution
Step 1: Identify feature to protect main branch
Branch policies in Azure Repos allow setting rules like requiring pull requests before merging to main.
Step 2: Evaluate other options
Git LFS manages large files, pipelines automate deployment, and creating repos per developer doesn't protect main branch.
Final Answer:
Branch policies with pull request requirements -> Option D
Quick Check:
Protect main branch = branch policies [OK]
Hint: Use branch policies to require pull requests [OK]
Common Mistakes:
Confusing deployment pipelines with branch protection