![Maven Tutorial](/maven/images/maven-mini-logo.jpg)
- Maven Tutorial
- Maven - Home
- Maven - Overview
- Maven - Environment Setup
- Maven - POM
- Maven - Build Life Cycle
- Maven - Build Profiles
- Maven - Repositories
- Maven - Plug-ins
- Maven - Creating Project
- Maven - Build & Test Project
- Maven - External Dependencies
- Maven - Project Documents
- Maven - Project Templates
- Maven - Snapshots
- Maven - Build Automation
- Maven - Manage Dependencies
- Maven - Deployment Automation
- Maven - Web Application
- Maven - Eclipse IDE
- Maven - NetBeans
- Maven - IntelliJ IDEA
- Maven Useful Resources
- Maven - Questions and Answers
- Maven - Quick Guide
- Maven - Useful Resources
- Maven - Discussion
Maven - Online Quiz
Following quiz provides Multiple Choice Questions (MCQs) related to Maven. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.
![Questions and Answers](/images/questions_and_answers.png)
Q 1 - What POM stands for?
Answer : B
Explanation
POM stands for Project Object Model.
Q 2 - Which of the following configuration element is present in POM.xml?
Answer : C
Explanation
Both of the above configuration elements are present in POM.xml.
Q 3 - Which of the following phase in maven life cycle installs the package into the local repository, for use as a dependency in other projects locally?
Answer : C
Explanation
install phase installs the package into the local repository, for use as a dependency in other projects locally.
Q 4 - Which of the following is true about Maven repository?
Answer : C
Explanation
A repository is a place i.e. directory where all the project jars, library jar, plugins or any other project specific artifacts are stored and can be used by Maven easily.
Q 5 - Which of the following is true about Maven central repository?
A - It is repository provided by Maven community.
Answer : D
Explanation
It is repository provided by Maven community. It contains a large number of commonly used libraries. When Maven does not find any dependency in local repository, it starts searching in central repository using following URL: http://repo1.maven.org/maven2/.
Q 6 - Which of the following scope indicates that you have to provide the system path?
Answer : A
Explanation
system − This scope indicates that you have to provide the system path.
Q 7 - What MOJO stands for?
A - Main plain Old Java Object
B - Maven plain Old Java Object
Answer : B
Explanation
A mojo is a Maven plain Old Java Object.
Q 8 - Which of the following is correct about Goal in Maven?
A - A goal represents a specific task which contributes to the building and managing of a project.
Answer : D
Explanation
A goal represents a specific task which contributes to the building and managing of a project. It may be bound to zero or more build phases. A goal not bound to any build phase could be executed outside of the build lifecycle by direct invocation.
Q 9 - Which of the following phase in maven life cycle generates resources to be included in the package?
Answer : A
Explanation
generate-resources generates resources to be included in the package.
Q 10 - Which of the following plugin run the JUnit unit tests and creates test reports?
Answer : A
Explanation
surefire plugin run the JUnit unit tests and creates test reports.