Skip to content
Ameen Abozaid
In reviewJNR-002-L05

Plugins and the build lifecycle revisited

  • Lesson 5 of 8
  • 11 min read
  • Junior
On This Lesson 4 topics

The content for this lesson is written and waiting for review. The outline below shows what it covers. It will be published once it is approved.

In this lesson

configure the common plugins.

Planned topics

  • Lifecycle phases: validate, compile, test, package, verify, install, deploy.
  • Plugins do the work in each phase.
  • Compiler plugin: sets the Java release, for example <release>.
  • Surefire runs unit tests (*Test) in the test phase.
  • Failsafe runs integration tests (*IT) in integration-test and checks them in verify.
Draft outline details

Demonstration

xml
<plugin>
  <artifactId>maven-compiler-plugin</artifactId>
  <configuration><release>${java.version}</release></configuration>
</plugin>

Check your understanding

Which plugin runs integration tests?

Show answer

Failsafe.

Practice

Apply this lesson with the module's lab, exercises and quiz.

Lab and exercises Quiz

Marking a lesson complete is optional and you can undo it any time. Your progress stays in this browser.

Continue to next lesson

Type to search levels, phases, modules and lessons.