org.junit.experimental.categories.Categories Java Examples
The following examples show how to use
org.junit.experimental.categories.Categories.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: LdapConditionallyFilteredTestRunner.java From spring-ldap with Apache License 2.0 | 5 votes |
/** * Constructs a new {@code SpringJUnit4ClassRunner} and initializes a * {@link org.springframework.test.context.TestContextManager} to provide Spring testing functionality to * standard JUnit tests. * * @param clazz the test class to be run * @see #createTestContextManager(Class) */ public LdapConditionallyFilteredTestRunner(Class<?> clazz) throws InitializationError { super(clazz); String noadtest = System.getProperty("adtest"); if (noadtest != null) { try { filter(Categories.CategoryFilter.exclude(NoAdTest.class)); } catch (NoTestsRemainException e) { // Nothing to do here. } } }