0
JUnit Tests are executed via IDE but can't execute via maven job on Jenkins

Open 1 Answers 32 Views
0 1

I have created a Maven project and set it up on Jenkins as a maven build. When I execute mvn clean test, it does not recognize my tests.

Here is test file name:

validateDB.java

It has one @Test annotation.

1 Answer

0
0
Maven surefire plugin will recognize a test class that has name starting with

Test or TestCase

or ending with

Test

So, rename your class and it will work.
answered by

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
Anti-spam verification:
To avoid this verification in future, please log in or register.



Top Contributors

...