org.springframework.test.context.TestExecutionListeners类的使用及代码示例

x33g5p2x  于2022-01-29 转载在 其他  
字(5.0k)|赞(0)|评价(0)|浏览(147)

本文整理了Java中org.springframework.test.context.TestExecutionListeners类的一些代码示例,展示了TestExecutionListeners类的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。TestExecutionListeners类的具体详情如下:
包路径:org.springframework.test.context.TestExecutionListeners
类名称:TestExecutionListeners

TestExecutionListeners介绍

暂无

代码示例

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners({ FirstTel.class, SecondTel.class, ThirdTel.class })
private static class ExampleTestCase {
  @SuppressWarnings("unused")
  public void exampleTestMethod() {
  }
}

代码示例来源:origin: spring-projects/spring-framework

boolean inheritListeners = testExecutionListeners.inheritListeners();
AnnotationDescriptor<TestExecutionListeners> superDescriptor =
    MetaAnnotationUtils.findAnnotationDescriptor(
    testExecutionListeners.mergeMode() == MergeMode.MERGE_WITH_DEFAULTS) {
  if (logger.isDebugEnabled()) {
    logger.debug(String.format("Merging default listeners with listeners configured via " +
classesList.addAll(0, Arrays.asList(testExecutionListeners.listeners()));

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.spring-test

boolean inheritListeners = testExecutionListeners.inheritListeners();
AnnotationDescriptor<TestExecutionListeners> superDescriptor =
    MetaAnnotationUtils.findAnnotationDescriptor(
    testExecutionListeners.mergeMode() == MergeMode.MERGE_WITH_DEFAULTS) {
  if (logger.isDebugEnabled()) {
    logger.debug(String.format("Merging default listeners with listeners configured via " +
classesList.addAll(0, Arrays.asList(testExecutionListeners.listeners()));

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners(inheritListeners = false)
public static abstract class BaseTestCase extends AbstractTestNGSpringContextTests {
  @org.testng.annotations.Test
  public void testNothing() {
  }
}

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners(
    listeners = {QuuxTestExecutionListener.class, DependencyInjectionTestExecutionListener.class},
    mergeMode = MERGE_WITH_DEFAULTS)
static class MergedDefaultListenersWithCustomListenerPrependedTestCase {
}

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners({})
public abstract static class AbstractRepeatedTestCase {
  protected void incrementInvocationCount() throws IOException {
    invocationCount.incrementAndGet();
  }
}

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners(
    {FooTestExecutionListener.class, BarTestExecutionListener.class, BazTestExecutionListener.class})
static class ExplicitListenersTestCase {
}

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners(AlwaysFailingAfterTestExecutionTestExecutionListener.class)
public static class AlwaysFailingAfterTestExecutionTestCase extends BaseTestCase {
}

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners(QuuxTestExecutionListener.class)
static class InheritedListenersTestCase extends ExplicitListenersTestCase {
}

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners(listeners = QuuxTestExecutionListener.class, inheritListeners = false)
static class NonInheritedListenersTestCase extends InheritedListenersTestCase {
}

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners({ FailingAfterTestClassListener1.class, FailingAfterTestClassListener2.class })
private static class FailingAfterTestClassTestCase {
}

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners(AlwaysFailingBeforeTestClassTestExecutionListener.class)
static class AlwaysFailingBeforeTestClassTestCase extends BaseTestCase {
}

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners(AlwaysFailingAfterTestClassTestExecutionListener.class)
public static class AlwaysFailingAfterTestClassTestCase extends BaseTestCase {
}

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners(AlwaysFailingBeforeTestMethodTestExecutionListener.class)
public static class AlwaysFailingBeforeTestMethodTestCase extends BaseTestCase {
}

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners(AlwaysFailingBeforeTestExecutionTestExecutionListener.class)
static class AlwaysFailingBeforeTestExecutionTestCase extends BaseTestCase {
}

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners(AlwaysFailingBeforeTestExecutionTestExecutionListener.class)
public static class AlwaysFailingBeforeTestExecutionTestCase extends BaseTestCase {
}

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners({ FooTestExecutionListener.class, BarTestExecutionListener.class })
interface ExplicitListenersTestInterface {
}

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners(AlwaysFailingPrepareTestInstanceTestExecutionListener.class)
static class AlwaysFailingPrepareTestInstanceTestCase extends BaseTestCase {
}

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners(AlwaysFailingBeforeTestMethodTestExecutionListener.class)
static class AlwaysFailingBeforeTestMethodTestCase extends BaseTestCase {
}

代码示例来源:origin: spring-projects/spring-framework

@TestExecutionListeners(AlwaysFailingAfterTestMethodTestExecutionListener.class)
public static class AlwaysFailingAfterTestMethodTestCase extends BaseTestCase {
}

相关文章