Running the unit test in Maven is just specifying the phase test. To execute the unit test we wrote in the preceding section, right-click on the MyDistance
project, select Run As, and click on Maven Test. It will run the unit tests against the class and generate the report in the /target/surefire-reports/
folder, as shown in the following screenshot:
You can see the results of unit test execution in the txt
and xml
format.
18.220.152.139