Skip to content

How to run certain phases and validations

Roman Ivanov edited this page Dec 5, 2023 · 18 revisions

English locale for build

If your locale if not English, before any phase that executes checkstyle junit test, run in terminal: export LC_ALL=en_US.utf8

How to run all validations:

mvn clean verify

How to run all validations for not EN locale:

use existing/installed on your local "en" locale, to get all installed locales use locale -a

export LC_ALL=en_US.utf8
mvn clean verify

How to generate all binaries (and ".......-all.jar" too):

mvn clean package -Passembly

How to generate website only:

mvn clean site -Pno-validations

Report location will be target/site/index.html

How to generate pmd report:

mvn clean test-compile pmd:check

Report will printed in terminal output

How to generate spotbugs report:

mvn clean test-compile spotbugs:check

Report will printed in terminal output

How to generate checkstyle report:

mvn clean compile antrun:run@ant-phase-verify

How to generate forbiddenapis report:

mvn clean compile test-compile forbiddenapis:testCheck@forbiddenapis-test

How to run one or few tests:

mvn clean test -Dtest=XdocsPagesTest,XdocsJavaDocsTest
mvn clean test -Dtest=CheckerTest#testDestroy

How to generate UT coverage report

Generate HTML report (ATTENTION: "clean" is required to avoid strange reports !!! always do it!):

mvn -e clean test jacoco:restore-instrumented-classes jacoco:report@default-report

Report location will be target/site/jacoco/index.html

How to run Sevntu checks

mvn clean compile checkstyle:check@sevntu-checkstyle-check

Setup IDEA for execution of test in English locale

Set LC_ALL=en_US.utf8 in "Environment variables" of test execution config. image

Clone this wiki locally