0

I'm trying to write integration test for DAO using cucumber. When I try to add the following dependency

<dependency>
    <groupId>info.cukes</groupId>
    <artifactId>cucumber-spring</artifactId>
    <version>1.1.5</version>
</dependency>

I'm getting following error.

Error message

When I take out the dependency for spring, feature file is running and generating step definitions but I'm unable inject spring beans into step definitions.

Any suggestions. Thanks

technophile
  • 37
  • 2
  • 8

1 Answers1

0

Do your dependencies look something like this (sorry, gradle not Maven):

compile 'info.cukes:cucumber-java8:1.2.3'
compile 'info.cukes:cucumber-junit:1.2.3'
compile 'info.cukes:cucumber-spring:1.2.3'
compile 'info.cukes:cucumber-java:1.2.3'
compile 'junit:junit:4.12'
compile 'org.springframework:spring-beans:4.1.1.RELEASE'
compile 'org.springframework:spring-context:4.1.1.RELEASE'
compile 'org.springframework:spring-test:4.1.1.RELEASE'
compile 'org.springframework:spring-jdbc:4.1.1.RELEASE'
compile 'org.springframework:spring-web:4.1.1.RELEASE'
compile 'org.jasypt:jasypt-spring31:1.9.2'
compile 'com.fasterxml.jackson.core:jackson-core:2.6.3'
compile 'com.fasterxml.jackson.core:jackson-databind:2.6.3'

/* Selenium */
compile 'org.seleniumhq.selenium:selenium-java:2.50.1'
compile 'org.seleniumhq.selenium:selenium-chrome-driver:2.50.1'
compile 'org.seleniumhq.selenium:selenium-support:2.50.1'


/* MDSC */
compile 'log4j:log4j:1.2.17'
compile 'org.codehaus.jackson:jackson-mapper-lgpl:1.9.13'

/* Apache Commons DBCP software implements Database Connection Pooling */
compile 'org.apache.commons:commons-dbcp2:2.0'
MikeJRamsey56
  • 2,779
  • 1
  • 20
  • 34