I have created Unit Tests for a project of mine and when I click “run test” on my test file, the system return this:
C:UsersJustin FussellAppDataLocalNetBeansCache20executor-snippetsjunit.xml:184: The following error occurred while executing this line:
C:UsersJustin FussellAppDataLocalNetBeansCache20executor-snippetsjunit.xml:128: The or for must include junit.jar if not in Ant’s own classpath
BUILD FAILED (total time: 0 seconds).
I cannot figure it out and I am not sure what I need to do in order to eliminate the problem and have successful unit tests.
I tried installing JUnit through “Properties”, and “Add Library”, which is where I added JUnit 5 as well as searching for , and in the build.xml file which is where I noticed that there was no reference to a junit.jar file.
Justin Fussell is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.