Site icon TestingDocs.com

Adding JUnit5 library to a Project

Overview

In this post, we will learn how to add the JUnit5 library to a standalone java project using Eclipse IDE.

Environment used:

JDK 12

Eclipse 2019.xx

Windows 10 operating system

Steps:

Launch Eclipse IDE.

Click on Create a Java Project link in the Package Explorer.

Enter the Project name.

Click on the Next> button.

Click on the Finish button.

 

Optionally, you can create a module name, by creating module-info.java

To add JUnit5 library

Right Click on the Project >> Build Path >> Java Build Path.

Choose Libraries tab >> Add Library…

Select JUnit.

Click on the Next> button.

Choose Library version: JUnit 5

Click on Finish button >> Apply and Close button.

You can verify that the JUnit 5 library got added to your project.

 

Exit mobile version