You can separate your unit and integration tests into separate packages (or perhaps even separate source folders, but then you'd have to updated your Maven configuration to recognize that you have two separate source folders for tests).
To take advantage of this, in Eclipse's Run Configurations (Run
> Run Configurations
), create a new JUnit run configuration that "Run all tests in the selected project, package or source folder:", select the the package/source folder containing only the tests you want to run.
When I first read your question, I got it backwards. I thought you wanted to run the full suite in Eclipse, and only a subset in Jenkins. I'm going to just leave my old answer up in case you find this useful some how:
The way I've done this before is through naming convention of the JUnit Test Cases.
I would name all the unit test test cases ...UnitTest
(e.g., RegistrationManagerUnitTest
) and integration test test cases, I'd name ...IntegrationTest
(e.g., RegistrationDaoIntegrationTest
).
Then in Maven, you can configure it to run all the test cases whose classes end with ...UnitTest
(by default it's looking for classes whose name end with ...Test
. Something along the lines of:
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<!-- Run only tests whose name end with "UnitTest" -->
<includes>
<include>**/*UnitTest.java</include>
</includes>
</configuration>
</plugin>