5

Our current testing framework is running with junit + spring + selenium. Our tests use both junit's org.junit.runner.notification.RunListeners and spring org.springframework.test.context.TestExecutionListeners.

This is how the test definition looks like:

@RunWith(SpringJUnit4ClassRunner.class)
@TestExecutionListeners(listeners = {MyTestExecutionListener.class})
@ContextConfiguration(locations = {"classpath:/META-INF/spring/my-context.xml"})
public abstract class BaseAutomationTest extends AbstractJUnit4SpringContextTests {
}

My question is where should I write the code that resides in the listeners when using Cucumber?

Please note that this code needs access to the spring's ApplicationContext.

Dana Shalev
  • 1,894
  • 1
  • 13
  • 13

0 Answers0