serenity-bdd / serenity-cucumber4-starter

48 stars 73 forks source link

Cucumber Serenity tests do not start with maven #38

Open ashasingh85 opened 3 years ago

ashasingh85 commented 3 years ago

When I run my test through Maven it gives me the below output in console. Not sure why this is happening. My test only include one scenario in a feature file and it runs while executing through the test runner but not with Maven. I have attached my pom.xml as well. Please look into the issue as it does not allow me to proceed further.

SLF4J: Class path contains multiple SLF4J bindings. SLF4J: Found binding in [jar:file:/C:/Users/yhassan/.p2/pool/plugins/org.eclipse.m2e.maven.runtime.slf4j.simple_1.16.0.20200610-1735/jars/slf4j-simple-1.7.5.jar!/org/slf4j/impl/StaticLoggerBinder.class] SLF4J: Found binding in [file:/C:/Users/asingh/eclipse/configuration/org.eclipse.osgi/5/0/.cp/org/slf4j/impl/StaticLoggerBinder.class] SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation. SLF4J: Actual binding is of type [org.slf4j.impl.SimpleLoggerFactory] SLF4J: Class path contains multiple SLF4J bindings. SLF4J: Found binding in [jar:file:/C:/Users/yhassan/.p2/pool/plugins/org.eclipse.m2e.maven.runtime.slf4j.simple_1.16.0.20200610-1735/jars/slf4j-simple-1.7.5.jar!/org/slf4j/impl/StaticLoggerBinder.class] SLF4J: Found binding in [file:/C:/Users/asingh/eclipse/configuration/org.eclipse.osgi/5/0/.cp/org/slf4j/impl/StaticLoggerBinder.class] SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation. SLF4J: Actual binding is of type [org.slf4j.impl.SimpleLoggerFactory] [INFO] Scanning for projects... [INFO] [INFO] -----------------< Automation:BANCS_Serenity_version1 >----------------- [INFO] Building BANCS_Serenity_version1 0.0.1-SNAPSHOT [INFO] --------------------------------[ jar ]--------------------------------- [INFO] [INFO] --- maven-resources-plugin:3.2.0:copy-resources (copy-resources) @ BANCS_Serenity_version1 --- [INFO] Using 'UTF-8' encoding to copy filtered resources. [INFO] Using 'UTF-8' encoding to copy filtered properties files. [INFO] skip non existing resourceDirectory C:\Users\asingh\eclipse-workspace\BANCS_Serenity_version1\src\non-packaged-resources [INFO] [INFO] --- maven-resources-plugin:3.2.0:resources (default-resources) @ BANCS_Serenity_version1 --- [INFO] Using 'UTF-8' encoding to copy filtered resources. [INFO] Using 'UTF-8' encoding to copy filtered properties files. [INFO] Copying 0 resource [INFO] [INFO] --- maven-compiler-plugin:3.8.1:compile (default-compile) @ BANCS_Serenity_version1 --- [INFO] Nothing to compile - all classes are up to date [INFO] [INFO] --- maven-resources-plugin:3.2.0:testResources (default-testResources) @ BANCS_Serenity_version1 --- [INFO] Using 'UTF-8' encoding to copy filtered resources. [INFO] Using 'UTF-8' encoding to copy filtered properties files. [INFO] Copying 3 resources [INFO] [INFO] --- maven-compiler-plugin:3.8.1:testCompile (default-testCompile) @ BANCS_Serenity_version1 --- [INFO] Changes detected - recompiling the module! [INFO] Compiling 22 source files to C:\Users\asingh\eclipse-workspace\BANCS_Serenity_version1\target\test-classes [INFO] [INFO] --- maven-surefire-plugin:3.0.0-M4:test (default-test) @ BANCS_Serenity_version1 --- [INFO] Tests are skipped. [INFO] [INFO] --- maven-jar-plugin:2.4:jar (default-jar) @ BANCS_Serenity_version1 --- [INFO] Building jar: C:\Users\asingh\eclipse-workspace\BANCS_Serenity_version1\target\BANCS_Serenity_version1-0.0.1-SNAPSHOT.jar [INFO] [INFO] --- maven-failsafe-plugin:3.0.0-M5:integration-test (default) @ BANCS_Serenity_version1 --- [INFO] [INFO] ------------------------------------------------------- [INFO] T E S T S [INFO] ------------------------------------------------------- [INFO] [INFO] Results: [INFO] [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0 [INFO] [INFO] [INFO] --- serenity-maven-plugin:2.3.4:aggregate (serenity-reports) @ BANCS_Serenity_version1 --- WARNING: An illegal reflective access operation has occurred WARNING: Illegal reflective access by com.google.inject.internal.cglib.core.$ReflectUtils$1 (file:/C:/Users/asingh/.m2/repository/com/google/inject/guice/4.2.2/guice-4.2.2.jar) to method java.lang.ClassLoader.defineClass(java.lang.String,byte[],int,int,java.security.ProtectionDomain) WARNING: Please consider reporting this to the maintainers of com.google.inject.internal.cglib.core.$ReflectUtils$1 WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations WARNING: All illegal access operations will be denied in a future release [INFO] Test results for 0 tests generated in 4.8 secs in directory: file:/C:/Users/asingh/eclipse-workspace/BANCS_Serenity_version1/target/site/serenity/ [INFO] ----------------------------------------- [INFO] SERENITY TESTS : SUCCESS [INFO] ----------------------------------------- [INFO] | Tests executed | 0 [INFO] | Tests passed | 0 [INFO] | Tests failed | 0 [INFO] | Tests with errors | 0 [INFO] | Tests compromised | 0 [INFO] | Tests pending | 0 [INFO] | Tests ignored/skipped | 0 [INFO] ------------------------ | -------------- [INFO] | Total Duration | 000ms [INFO] | Fastest test took | 000ms [INFO] | Slowest test took | 000ms [INFO] ----------------------------------------- [INFO] [INFO] SERENITY REPORTS [INFO] - Full Report: file:///C:/Users/asingh/eclipse-workspace/BANCS_Serenity_version1/target/site/serenity/index.html [INFO] [INFO] --- maven-failsafe-plugin:3.0.0-M5:verify (default) @ BANCS_Serenity_version1 --- [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESS [INFO] ------------------------------------------------------------------------ [INFO] Total time: 52.263 s [INFO] Finished at: 2020-12-13T20:59:35+11:00 [INFO] ------------------------------------------------------------------------

wakaleo commented 3 years ago

This looks like a maven configuration issue. Unless you have reason to think this is an actual defect in the Serenity code base, you can ask for help on the Gitter channel (https://gitter.im/serenity-bdd/serenity-core) for this sort of question.