invictum / serenity-reportportal-integration Goto Github PK
View Code? Open in Web Editor NEWSerenity TAF integration with Report Portal
License: Apache License 2.0
Serenity TAF integration with Report Portal
License: Apache License 2.0
Hi Iaroslav,
I've tried to use your plugin but got exception.
RP 4.1.0
Serenity BDD 1.9.4.
serenity-reportportal-integration 1.1.0
maven-failsafe-plugin 2.19.1
if time will try to reproduce within non prod project.
Could you please help me with it?
io.reactivex.exceptions.OnErrorNotImplementedException: Report Portal returned error
Status code: 406
Status message: Not Acceptable
Error Message: Finish launch is not allowed. Launch '5ac52005b9d8210001d82a5f' has items '[5ac52005b9d8210001d82a61,5ac52005b9d8210001d82a62,5ac52005b9d8210001d82a63,5ac52005b9d8210001d82a64,5ac52005b9d8210001d82a65,5ac52005b9d8210001d82a66,5ac52005b9d8210001d82a68,5ac52005b9d8210001d82a69,5ac52005b9d8210001d82a67,5ac52005b9d8210001d82a6a,5ac52005b9d8210001d82a6b,5ac52005b9d8210001d82a6d,5ac52005b9d8210001d82a6e,5ac52005b9d8210001d82a6f,5ac52005b9d8210001d82a6c,5ac52005b9d8210001d82a70,5ac52005b9d8210001d82a71,5ac52005b9d8210001d82a72,5ac52005b9d8210001d82a73,5ac52005b9d8210001d82a74,5ac52005b9d8210001d82a75,5ac52005b9d8210001d82a76,5ac52005b9d8210001d82a77,5ac52005b9d8210001d82a78,5ac52005b9d8210001d82a79,5ac52005b9d8210001d82a7a,5ac52006b9d8210001d82a7b,5ac52006b9d8210001d82a7c,5ac52006b9d8210001d82a7e,5ac52006b9d8210001d82a7f,5ac52006b9d8210001d82a80,5ac52006b9d8210001d82a82,5ac52006b9d8210001d82a81,5ac52006b9d8210001d82a83,5ac52006b9d8210001d82a84,5ac52006b9d8210001d82a85,5ac52006b9d8210001d82a86,5ac52006b9d8210001d82a87,5ac52006b9d8210001d82a88,5ac52023b9d8210001d82aae,5ac52023b9d8210001d82aaf,5ac52023b9d8210001d82ab0,5ac52023b9d8210001d82ab1,5ac52023b9d8210001d82ab2,5ac52023b9d8210001d82ab4,5ac52023b9d8210001d82ab3,5ac52023b9d8210001d82ab5,5ac52023b9d8210001d82ab6,5ac52023b9d8210001d82ab7,5ac52023b9d8210001d82ab8,5ac52023b9d8210001d82ab9,5ac52023b9d8210001d82aba]' with 'IN_PROGRESS' status
Error Type: FINISH_LAUNCH_NOT_ALLOWED
at io.reactivex.internal.functions.Functions$OnErrorMissingConsumer.accept(Functions.java:704)
at io.reactivex.internal.functions.Functions$OnErrorMissingConsumer.accept(Functions.java:701)
at io.reactivex.internal.operators.maybe.MaybeCallbackObserver.onError(MaybeCallbackObserver.java:83)
at io.reactivex.internal.operators.maybe.MaybeSubscribeOn$SubscribeOnMaybeObserver.onError(MaybeSubscribeOn.java:96)
at io.reactivex.internal.operators.maybe.MaybeCache.onError(MaybeCache.java:103)
at io.reactivex.internal.operators.maybe.MaybeFromCallable.subscribeActual(MaybeFromCallable.java:50)
at io.reactivex.Maybe.subscribe(Maybe.java:3727)
at io.reactivex.internal.operators.maybe.MaybeCache.subscribeActual(MaybeCache.java:77)
at io.reactivex.Maybe.subscribe(Maybe.java:3727)
at io.reactivex.internal.operators.maybe.MaybeSubscribeOn$SubscribeTask.run(MaybeSubscribeOn.java:54)
at io.reactivex.Scheduler$DisposeTask.run(Scheduler.java:452)
at io.reactivex.internal.schedulers.ScheduledRunnable.run(ScheduledRunnable.java:61)
at io.reactivex.internal.schedulers.ScheduledRunnable.call(ScheduledRunnable.java:52)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Caused by: com.epam.reportportal.exception.ReportPortalException: Report Portal returned error
Status code: 406
Status message: Not Acceptable
Error Message: Finish launch is not allowed. Launch '5ac52005b9d8210001d82a5f' has items '[5ac52005b9d8210001d82a61,5ac52005b9d8210001d82a62,5ac52005b9d8210001d82a63,5ac52005b9d8210001d82a64,5ac52005b9d8210001d82a65,5ac52005b9d8210001d82a66,5ac52005b9d8210001d82a68,5ac52005b9d8210001d82a69,5ac52005b9d8210001d82a67,5ac52005b9d8210001d82a6a,5ac52005b9d8210001d82a6b,5ac52005b9d8210001d82a6d,5ac52005b9d8210001d82a6e,5ac52005b9d8210001d82a6f,5ac52005b9d8210001d82a6c,5ac52005b9d8210001d82a70,5ac52005b9d8210001d82a71,5ac52005b9d8210001d82a72,5ac52005b9d8210001d82a73,5ac52005b9d8210001d82a74,5ac52005b9d8210001d82a75,5ac52005b9d8210001d82a76,5ac52005b9d8210001d82a77,5ac52005b9d8210001d82a78,5ac52005b9d8210001d82a79,5ac52005b9d8210001d82a7a,5ac52006b9d8210001d82a7b,5ac52006b9d8210001d82a7c,5ac52006b9d8210001d82a7e,5ac52006b9d8210001d82a7f,5ac52006b9d8210001d82a80,5ac52006b9d8210001d82a82,5ac52006b9d8210001d82a81,5ac52006b9d8210001d82a83,5ac52006b9d8210001d82a84,5ac52006b9d8210001d82a85,5ac52006b9d8210001d82a86,5ac52006b9d8210001d82a87,5ac52006b9d8210001d82a88,5ac52023b9d8210001d82aae,5ac52023b9d8210001d82aaf,5ac52023b9d8210001d82ab0,5ac52023b9d8210001d82ab1,5ac52023b9d8210001d82ab2,5ac52023b9d8210001d82ab4,5ac52023b9d8210001d82ab3,5ac52023b9d8210001d82ab5,5ac52023b9d8210001d82ab6,5ac52023b9d8210001d82ab7,5ac52023b9d8210001d82ab8,5ac52023b9d8210001d82ab9,5ac52023b9d8210001d82aba]' with 'IN_PROGRESS' status
Error Type: FINISH_LAUNCH_NOT_ALLOWED
at com.epam.reportportal.service.ReportPortalErrorHandler.handleError(ReportPortalErrorHandler.java:57)
at com.epam.reportportal.restendpoint.http.DefaultErrorHandler.handle(DefaultErrorHandler.java:56)
at com.epam.reportportal.restendpoint.http.HttpClientRestEndpoint$1.call(HttpClientRestEndpoint.java:487)
at com.epam.reportportal.restendpoint.http.HttpClientRestEndpoint$1.call(HttpClientRestEndpoint.java:456)
at io.reactivex.internal.operators.maybe.MaybeFromCallable.subscribeActual(MaybeFromCallable.java:46)
... 13 more
Exception in thread "RxCachedThreadScheduler-25" io.reactivex.exceptions.OnErrorNotImplementedException: Report Portal returned error
Status code: 406
Status message: Not Acceptable
Error Message: Finish launch is not allowed. Launch '5ac52005b9d8210001d82a5f' has items '[5ac52005b9d8210001d82a61,5ac52005b9d8210001d82a62,5ac52005b9d8210001d82a63,5ac52005b9d8210001d82a64,5ac52005b9d8210001d82a65,5ac52005b9d8210001d82a66,5ac52005b9d8210001d82a68,5ac52005b9d8210001d82a69,5ac52005b9d8210001d82a67,5ac52005b9d8210001d82a6a,5ac52005b9d8210001d82a6b,5ac52005b9d8210001d82a6d,5ac52005b9d8210001d82a6e,5ac52005b9d8210001d82a6f,5ac52005b9d8210001d82a6c,5ac52005b9d8210001d82a70,5ac52005b9d8210001d82a71,5ac52005b9d8210001d82a72,5ac52005b9d8210001d82a73,5ac52005b9d8210001d82a74,5ac52005b9d8210001d82a75,5ac52005b9d8210001d82a76,5ac52005b9d8210001d82a77,5ac52005b9d8210001d82a78,5ac52005b9d8210001d82a79,5ac52005b9d8210001d82a7a,5ac52006b9d8210001d82a7b,5ac52006b9d8210001d82a7c,5ac52006b9d8210001d82a7e,5ac52006b9d8210001d82a7f,5ac52006b9d8210001d82a80,5ac52006b9d8210001d82a82,5ac52006b9d8210001d82a81,5ac52006b9d8210001d82a83,5ac52006b9d8210001d82a84,5ac52006b9d8210001d82a85,5ac52006b9d8210001d82a86,5ac52006b9d8210001d82a87,5ac52006b9d8210001d82a88,5ac52023b9d8210001d82aae,5ac52023b9d8210001d82aaf,5ac52023b9d8210001d82ab0,5ac52023b9d8210001d82ab1,5ac52023b9d8210001d82ab2,5ac52023b9d8210001d82ab4,5ac52023b9d8210001d82ab3,5ac52023b9d8210001d82ab5,5ac52023b9d8210001d82ab6,5ac52023b9d8210001d82ab7,5ac52023b9d8210001d82ab8,5ac52023b9d8210001d82ab9,5ac52023b9d8210001d82aba]' with 'IN_PROGRESS' status
Error Type: FINISH_LAUNCH_NOT_ALLOWED
at io.reactivex.internal.functions.Functions$OnErrorMissingConsumer.accept(Functions.java:704)
at io.reactivex.internal.functions.Functions$OnErrorMissingConsumer.accept(Functions.java:701)
at io.reactivex.internal.operators.maybe.MaybeCallbackObserver.onError(MaybeCallbackObserver.java:83)
at io.reactivex.internal.operators.maybe.MaybeSubscribeOn$SubscribeOnMaybeObserver.onError(MaybeSubscribeOn.java:96)
at io.reactivex.internal.operators.maybe.MaybeCache.onError(MaybeCache.java:103)
at io.reactivex.internal.operators.maybe.MaybeFromCallable.subscribeActual(MaybeFromCallable.java:50)
at io.reactivex.Maybe.subscribe(Maybe.java:3727)
at io.reactivex.internal.operators.maybe.MaybeCache.subscribeActual(MaybeCache.java:77)
at io.reactivex.Maybe.subscribe(Maybe.java:3727)
at io.reactivex.internal.operators.maybe.MaybeSubscribeOn$SubscribeTask.run(MaybeSubscribeOn.java:54)
at io.reactivex.Scheduler$DisposeTask.run(Scheduler.java:452)
at io.reactivex.internal.schedulers.ScheduledRunnable.run(ScheduledRunnable.java:61)
at io.reactivex.internal.schedulers.ScheduledRunnable.call(ScheduledRunnable.java:52)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Caused by: com.epam.reportportal.exception.ReportPortalException: Report Portal returned error
Status code: 406
Status message: Not Acceptable
Error Message: Finish launch is not allowed. Launch '5ac52005b9d8210001d82a5f' has items '[5ac52005b9d8210001d82a61,5ac52005b9d8210001d82a62,5ac52005b9d8210001d82a63,5ac52005b9d8210001d82a64,5ac52005b9d8210001d82a65,5ac52005b9d8210001d82a66,5ac52005b9d8210001d82a68,5ac52005b9d8210001d82a69,5ac52005b9d8210001d82a67,5ac52005b9d8210001d82a6a,5ac52005b9d8210001d82a6b,5ac52005b9d8210001d82a6d,5ac52005b9d8210001d82a6e,5ac52005b9d8210001d82a6f,5ac52005b9d8210001d82a6c,5ac52005b9d8210001d82a70,5ac52005b9d8210001d82a71,5ac52005b9d8210001d82a72,5ac52005b9d8210001d82a73,5ac52005b9d8210001d82a74,5ac52005b9d8210001d82a75,5ac52005b9d8210001d82a76,5ac52005b9d8210001d82a77,5ac52005b9d8210001d82a78,5ac52005b9d8210001d82a79,5ac52005b9d8210001d82a7a,5ac52006b9d8210001d82a7b,5ac52006b9d8210001d82a7c,5ac52006b9d8210001d82a7e,5ac52006b9d8210001d82a7f,5ac52006b9d8210001d82a80,5ac52006b9d8210001d82a82,5ac52006b9d8210001d82a81,5ac52006b9d8210001d82a83,5ac52006b9d8210001d82a84,5ac52006b9d8210001d82a85,5ac52006b9d8210001d82a86,5ac52006b9d8210001d82a87,5ac52006b9d8210001d82a88,5ac52023b9d8210001d82aae,5ac52023b9d8210001d82aaf,5ac52023b9d8210001d82ab0,5ac52023b9d8210001d82ab1,5ac52023b9d8210001d82ab2,5ac52023b9d8210001d82ab4,5ac52023b9d8210001d82ab3,5ac52023b9d8210001d82ab5,5ac52023b9d8210001d82ab6,5ac52023b9d8210001d82ab7,5ac52023b9d8210001d82ab8,5ac52023b9d8210001d82ab9,5ac52023b9d8210001d82aba]' with 'IN_PROGRESS' status
Error Type: FINISH_LAUNCH_NOT_ALLOWED
at com.epam.reportportal.service.ReportPortalErrorHandler.handleError(ReportPortalErrorHandler.java:57)
at com.epam.reportportal.restendpoint.http.DefaultErrorHandler.handle(DefaultErrorHandler.java:56)
at com.epam.reportportal.restendpoint.http.HttpClientRestEndpoint$1.call(HttpClientRestEndpoint.java:487)
at com.epam.reportportal.restendpoint.http.HttpClientRestEndpoint$1.call(HttpClientRestEndpoint.java:456)
at io.reactivex.internal.operators.maybe.MaybeFromCallable.subscribeActual(MaybeFromCallable.java:46)
... 13 more
2018-04-04 21:57:46:074 +0300 [RxCachedThreadScheduler-25] ERROR com.epam.reportportal.service.Launch - [39] ReportPortal execution error
com.epam.reportportal.exception.ReportPortalException: Report Portal returned error
Status code: 406
Status message: Not Acceptable
Error Message: Finish launch is not allowed. Launch '5ac52005b9d8210001d82a5f' has items '[5ac52005b9d8210001d82a61,5ac52005b9d8210001d82a62,5ac52005b9d8210001d82a63,5ac52005b9d8210001d82a64,5ac52005b9d8210001d82a65,5ac52005b9d8210001d82a66,5ac52005b9d8210001d82a68,5ac52005b9d8210001d82a69,5ac52005b9d8210001d82a67,5ac52005b9d8210001d82a6a,5ac52005b9d8210001d82a6b,5ac52005b9d8210001d82a6d,5ac52005b9d8210001d82a6e,5ac52005b9d8210001d82a6f,5ac52005b9d8210001d82a6c,5ac52005b9d8210001d82a70,5ac52005b9d8210001d82a71,5ac52005b9d8210001d82a72,5ac52005b9d8210001d82a73,5ac52005b9d8210001d82a74,5ac52005b9d8210001d82a75,5ac52005b9d8210001d82a76,5ac52005b9d8210001d82a77,5ac52005b9d8210001d82a78,5ac52005b9d8210001d82a79,5ac52005b9d8210001d82a7a,5ac52006b9d8210001d82a7b,5ac52006b9d8210001d82a7c,5ac52006b9d8210001d82a7e,5ac52006b9d8210001d82a7f,5ac52006b9d8210001d82a80,5ac52006b9d8210001d82a82,5ac52006b9d8210001d82a81,5ac52006b9d8210001d82a83,5ac52006b9d8210001d82a84,5ac52006b9d8210001d82a85,5ac52006b9d8210001d82a86,5ac52006b9d8210001d82a87,5ac52006b9d8210001d82a88,5ac52023b9d8210001d82aae,5ac52023b9d8210001d82aaf,5ac52023b9d8210001d82ab0,5ac52023b9d8210001d82ab1,5ac52023b9d8210001d82ab2,5ac52023b9d8210001d82ab4,5ac52023b9d8210001d82ab3,5ac52023b9d8210001d82ab5,5ac52023b9d8210001d82ab6,5ac52023b9d8210001d82ab7,5ac52023b9d8210001d82ab8,5ac52023b9d8210001d82ab9,5ac52023b9d8210001d82aba]' with 'IN_PROGRESS' status
Error Type: FINISH_LAUNCH_NOT_ALLOWED
at com.epam.reportportal.service.ReportPortalErrorHandler.handleError(ReportPortalErrorHandler.java:57)
at com.epam.reportportal.restendpoint.http.DefaultErrorHandler.handle(DefaultErrorHandler.java:56)
at com.epam.reportportal.restendpoint.http.HttpClientRestEndpoint$1.call(HttpClientRestEndpoint.java:487)
at com.epam.reportportal.restendpoint.http.HttpClientRestEndpoint$1.call(HttpClientRestEndpoint.java:456)
at io.reactivex.internal.operators.maybe.MaybeFromCallable.subscribeActual(MaybeFromCallable.java:46)
at io.reactivex.Maybe.subscribe(Maybe.java:3727)
at io.reactivex.internal.operators.maybe.MaybeCache.subscribeActual(MaybeCache.java:77)
at io.reactivex.Maybe.subscribe(Maybe.java:3727)
at io.reactivex.internal.operators.maybe.MaybeSubscribeOn$SubscribeTask.run(MaybeSubscribeOn.java:54)
at io.reactivex.Scheduler$DisposeTask.run(Scheduler.java:452)
at io.reactivex.internal.schedulers.ScheduledRunnable.run(ScheduledRunnable.java:61)
at io.reactivex.internal.schedulers.ScheduledRunnable.call(ScheduledRunnable.java:52)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Results :
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0
For now ReportIntegrationConfig
uses static approach, but it does not suitable especially with google Guice available.
Changes in configuration will eliminate backward compatibility for versions under 1.1.3, so changes will be available in 1.2.0
I am trying to integrate serenity with report portal with below combination. My project is configured as Serenity-Junit
In every execution my browser get launched and reach up to navigating to logging page and then it is getting closed by throwing below exception on console.
[rp-io-10] ERROR com.epam.reportportal.service.Launch - [57] ReportPortal execution error
com.epam.reportportal.exception.ReportPortalException: Report Portal returned error
Status code: 406
Status message: Not Acceptable
Error Message: Finish launch is not allowed. Launch '5be4330e42eba40001f5189a' has items '[5be4331a42eba40001f5189e]' with 'IN_PROGRESS' status
Error Type: FINISH_LAUNCH_NOT_ALLOWED
at com.epam.reportportal.service.ReportPortalErrorHandler.handleError(ReportPortalErrorHandler.java:83)
at com.epam.reportportal.service.ReportPortalErrorHandler.handle(ReportPortalErrorHandler.java:59)
at com.epam.reportportal.restendpoint.http.HttpClientRestEndpoint$1.subscribe(HttpClientRestEndpoint.java:517)
at io.reactivex.internal.operators.maybe.MaybeCreate.subscribeActual(MaybeCreate.java:45)
at io.reactivex.Maybe.subscribe(Maybe.java:3727)
at io.reactivex.internal.operators.maybe.MaybeCache.subscribeActual(MaybeCache.java:77)
at io.reactivex.Maybe.subscribe(Maybe.java:3727)
at io.reactivex.internal.operators.maybe.MaybeSubscribeOn$SubscribeTask.run(MaybeSubscribeOn.java:54)
at io.reactivex.internal.schedulers.ScheduledDirectTask.call(ScheduledDirectTask.java:38)
at io.reactivex.internal.schedulers.ScheduledDirectTask.call(ScheduledDirectTask.java:26)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
the test run get updated in report portal with status as in-progress invalid run.
Please advise, I also tried different version of serenity along with commenting Junit dependency but got same exception.
While publishing results of CucumberWithSerenity tests to Report Portal we observed the issue with Scenario Outlines. It seems Report Portal fetches results only of the first example from a Scenario Outline.
As a result, it doesn't fail the launch even the actual build is failed by unsuccessful examples.
Dependencies:
The project to reproduce the issue:
serenity-with-cucumber-scenario-outlines.zip
I have detected following issue with serenity-reportportal-integration plugin
I've added version 1.05 as dependency to sample project provide by Serenity Team (integration with cucumber https://github.com/serenity-bdd/serenity-demos/tree/master/cucumber-webtests )
Whenever I run test with valid report portal credentials (username, uuid and etc.) my result's are uploaded to report portal UI (hosted at rp.epam.com)
However I can see following error and stacktrace
`Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 5.013 sec - in net.thucydides.showcase.cucumber.Petstore
6036 [Thread-2] INFO com.epam.reportportal.utils.LaunchFile - ReportPortal's temp file 'C:\Users\RUSTAM~1\AppData\Local\Temp\reportportal\rplaunch-5a564aa0b3cb1f0001fd42e3.tmp' has been removed
6179 [I/O dispatcher 2] ERROR com.epam.reportportal.service.ReportPortal - ReportPortal execution error
com.epam.reportportal.exception.ReportPortalException: Report Portal returned error
Status code: 406
Status message: Not Acceptable
Error Message: Finish launch is not allowed. Launch '5a564aa0b3cb1f0001fd42e3' has items '[5a564aa0b3cb1f0001fd42f2]' with 'IN_PROGRESS' status
Error Type: FINISH_LAUNCH_NOT_ALLOWED
at com.epam.reportportal.service.ReportPortalErrorHandler.handleError(ReportPortalErrorHandler.java:62)
at com.epam.restendpoint.http.DefaultErrorHandler.handle(DefaultErrorHandler.java:56)
at com.epam.restendpoint.http.HttpClientRestEndpoint$1$1.completed(HttpClientRestEndpoint.java:547)
at com.epam.restendpoint.http.HttpClientRestEndpoint$1$1.completed(HttpClientRestEndpoint.java:518)
at rp.org.apache.http.concurrent.BasicFuture.completed(BasicFuture.java:119)
at rp.org.apache.http.impl.nio.client.DefaultClientExchangeHandlerImpl.responseCompleted(DefaultClientExchangeHandlerImpl.java:177)
at rp.org.apache.http.nio.protocol.HttpAsyncRequestExecutor.processResponse(HttpAsyncRequestExecutor.java:436)
at rp.org.apache.http.nio.protocol.HttpAsyncRequestExecutor.inputReady(HttpAsyncRequestExecutor.java:326)
at rp.org.apache.http.impl.nio.DefaultNHttpClientConnection.consumeInput(DefaultNHttpClientConnection.java:265)
at rp.org.apache.http.impl.nio.client.InternalIODispatch.onInputReady(InternalIODispatch.java:81)
at rp.org.apache.http.impl.nio.client.InternalIODispatch.onInputReady(InternalIODispatch.java:39)
at rp.org.apache.http.impl.nio.reactor.AbstractIODispatch.inputReady(AbstractIODispatch.java:121)
at rp.org.apache.http.impl.nio.reactor.BaseIOReactor.readable(BaseIOReactor.java:162)
at rp.org.apache.http.impl.nio.reactor.AbstractIOReactor.processEvent(AbstractIOReactor.java:337)
at rp.org.apache.http.impl.nio.reactor.AbstractIOReactor.processEvents(AbstractIOReactor.java:315)
at rp.org.apache.http.impl.nio.reactor.AbstractIOReactor.execute(AbstractIOReactor.java:276)
at rp.org.apache.http.impl.nio.reactor.BaseIOReactor.execute(BaseIOReactor.java:104)
at rp.org.apache.http.impl.nio.reactor.AbstractMultiworkerIOReactor$Worker.run(AbstractMultiworkerIOReactor.java:588)
at java.lang.Thread.run(Thread.java:748)
6179 [Thread-1] ERROR com.epam.reportportal.service.ReportPortal - Unable to finish launch in ReportPortal
com.epam.reportportal.exception.ReportPortalException: Report Portal returned error
Status code: 406
Status message: Not Acceptable
Error Message: Finish launch is not allowed. Launch '5a564aa0b3cb1f0001fd42e3' has items '[5a564aa0b3cb1f0001fd42f2]' with 'IN_PROGRESS' status
Error Type: FINISH_LAUNCH_NOT_ALLOWED
at com.epam.reportportal.service.ReportPortalErrorHandler.handleError(ReportPortalErrorHandler.java:62)
at com.epam.restendpoint.http.DefaultErrorHandler.handle(DefaultErrorHandler.java:56)
at com.epam.restendpoint.http.HttpClientRestEndpoint$1$1.completed(HttpClientRestEndpoint.java:547)
at com.epam.restendpoint.http.HttpClientRestEndpoint$1$1.completed(HttpClientRestEndpoint.java:518)
at rp.org.apache.http.concurrent.BasicFuture.completed(BasicFuture.java:119)
at rp.org.apache.http.impl.nio.client.DefaultClientExchangeHandlerImpl.responseCompleted(DefaultClientExchangeHandlerImpl.java:177)
at rp.org.apache.http.nio.protocol.HttpAsyncRequestExecutor.processResponse(HttpAsyncRequestExecutor.java:436)
at rp.org.apache.http.nio.protocol.HttpAsyncRequestExecutor.inputReady(HttpAsyncRequestExecutor.java:326)
at rp.org.apache.http.impl.nio.DefaultNHttpClientConnection.consumeInput(DefaultNHttpClientConnection.java:265)
at rp.org.apache.http.impl.nio.client.InternalIODispatch.onInputReady(InternalIODispatch.java:81)
at rp.org.apache.http.impl.nio.client.InternalIODispatch.onInputReady(InternalIODispatch.java:39)
at rp.org.apache.http.impl.nio.reactor.AbstractIODispatch.inputReady(AbstractIODispatch.java:121)
at rp.org.apache.http.impl.nio.reactor.BaseIOReactor.readable(BaseIOReactor.java:162)
at rp.org.apache.http.impl.nio.reactor.AbstractIOReactor.processEvent(AbstractIOReactor.java:337)
at rp.org.apache.http.impl.nio.reactor.AbstractIOReactor.processEvents(AbstractIOReactor.java:315)
at rp.org.apache.http.impl.nio.reactor.AbstractIOReactor.execute(AbstractIOReactor.java:276)
at rp.org.apache.http.impl.nio.reactor.BaseIOReactor.execute(BaseIOReactor.java:104)
at rp.org.apache.http.impl.nio.reactor.AbstractMultiworkerIOReactor$Worker.run(AbstractMultiworkerIOReactor.java:588)
at java.lang.Thread.run(Thread.java:748)
Results :
`
For now only two profiles are present - default and custom.
From functional perspective default profile contains all available step processors, as a result RP log is to verbosed.
The idea is to add another one profile with minimal configuration that will produce a nice RP log.
An addition profiles will be renamed:
For now narrative text format logic is hardcoded.
Let's move it to separate class with ability to customize from end user perspective.
PR v4 has been released. Integration should support specified RP version.
Following points should be provided here:
Is there a way to turn off reportportal for a test launch without removing it from my project completely? I'd like to have two tasks in my build.gradle, one that logs to reportportal, and one that doesn't. Is this possible?
profile.registerProcessors(logs);
Hi @Invictum ,
We are trying to integrate our serenity cucumber framework, versions are below
<serenity.version>2.0.70</serenity.version>
<serenity.cucumber.version>1.9.45</serenity.cucumber.version>
During execution, it fails with below error. Could you please help.
[ERROR] 2019-11-18 14:27:07.105 :: Could not instantiate listener
java.util.ServiceConfigurationError: net.thucydides.core.steps.StepListener: Provider com.github.invictum.reportportal.ReportPortalListener could not be instantiated
at java.util.ServiceLoader.fail(ServiceLoader.java:232) ~[?:1.8.0_181]
at java.util.ServiceLoader.access$100(ServiceLoader.java:185) ~[?:1.8.0_181]
at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:384) ~[?:1.8.0_181]
at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:404) ~[?:1.8.0_181]
at java.util.ServiceLoader$1.next(ServiceLoader.java:480) ~[?:1.8.0_181]
at net.thucydides.core.steps.StepEventBus.getCustomListeners(StepEventBus.java:207) ~[serenity-core-2.0.70.jar:2.0.70]
at net.thucydides.core.steps.StepEventBus.getAllListeners(StepEventBus.java:192) ~[serenity-core-2.0.70.jar:2.0.70]
at net.thucydides.core.steps.StepEventBus.testSuiteStarted(StepEventBus.java:247) ~[serenity-core-2.0.70.jar:2.0.70]
at cucumber.runtime.formatter.SerenityReporter.lambda$handleTestSourceRead$8(SerenityReporter.java:174) ~[serenity-cucumber-1.9.45.jar:?]
at java.util.Optional.ifPresent(Optional.java:159) ~[?:1.8.0_181]
at cucumber.runtime.formatter.SerenityReporter.handleTestSourceRead(SerenityReporter.java:166) ~[serenity-cucumber-1.9.45.jar:?]
at cucumber.runtime.formatter.SerenityReporter.lambda$new$0(SerenityReporter.java:125) ~[serenity-cucumber-1.9.45.jar:?]
at cucumber.runner.EventBus.send(EventBus.java:28) [cucumber-core-2.4.0.jar:?]
at cucumber.runtime.model.CucumberFeature.sendTestSourceRead(CucumberFeature.java:132) [cucumber-core-2.4.0.jar:?]
at cucumber.runtime.RuntimeOptions.cucumberFeatures(RuntimeOptions.java:315) [cucumber-core-2.4.0.jar:?]
at cucumber.api.junit.Cucumber.(Cucumber.java:81) [cucumber-junit-2.4.0.jar:?]
at net.serenitybdd.cucumber.CucumberWithSerenity.(CucumberWithSerenity.java:54) [serenity-cucumber-1.9.45.jar:1.9.45]
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) [?:1.8.0_181]
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) [?:1.8.0_181]
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) [?:1.8.0_181]
at java.lang.reflect.Constructor.newInstance(Constructor.java:423) [?:1.8.0_181]
at org.junit.internal.builders.AnnotatedBuilder.buildRunner(AnnotatedBuilder.java:104) [junit-4.12.jar:4.12]
at org.junit.internal.builders.AnnotatedBuilder.runnerForClass(AnnotatedBuilder.java:86) [junit-4.12.jar:4.12]
at org.junit.runners.model.RunnerBuilder.safeRunnerForClass(RunnerBuilder.java:59) [junit-4.12.jar:4.12]
at org.junit.internal.builders.AllDefaultPossibilitiesBuilder.runnerForClass(AllDefaultPossibilitiesBuilder.java:26) [junit-4.12.jar:4.12]
at org.junit.runners.model.RunnerBuilder.safeRunnerForClass(RunnerBuilder.java:59) [junit-4.12.jar:4.12]
at org.junit.internal.requests.ClassRequest.getRunner(ClassRequest.java:33) [junit-4.12.jar:4.12]
at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:49) [junit-rt.jar:?]
at com.intellij.rt.execution.junit.IdeaTestRunner$Repeater.startRunnerWithArgs(IdeaTestRunner.java:47) [junit-rt.jar:?]
at com.intellij.rt.execution.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:242) [junit-rt.jar:?]
at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:70) [junit-rt.jar:?]
Caused by: java.lang.NoClassDefFoundError: com/epam/reportportal/service/Launch
at com.github.invictum.reportportal.injector.SerenityPortalModule.configure(SerenityPortalModule.java:14) ~[serenity-reportportal-integration-1.4.2.jar:?]
at com.google.inject.AbstractModule.configure(AbstractModule.java:61) ~[guice-4.2.2.jar:?]
at com.google.inject.spi.Elements$RecordingBinder.install(Elements.java:344) ~[guice-4.2.2.jar:?]
at com.google.inject.spi.Elements.getElements(Elements.java:103) ~[guice-4.2.2.jar:?]
at com.google.inject.internal.InjectorShell$Builder.build(InjectorShell.java:137) ~[guice-4.2.2.jar:?]
at com.google.inject.internal.InternalInjectorCreator.build(InternalInjectorCreator.java:103) ~[guice-4.2.2.jar:?]
at com.google.inject.Guice.createInjector(Guice.java:87) ~[guice-4.2.2.jar:?]
at com.google.inject.Guice.createInjector(Guice.java:69) ~[guice-4.2.2.jar:?]
at com.google.inject.Guice.createInjector(Guice.java:59) ~[guice-4.2.2.jar:?]
at com.github.invictum.reportportal.injector.IntegrationInjector.getInjector(IntegrationInjector.java:17) ~[serenity-reportportal-integration-1.4.2.jar:?]
at com.github.invictum.reportportal.ReportPortalListener.(ReportPortalListener.java:26) ~[serenity-reportportal-integration-1.4.2.jar:?]
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) ~[?:1.8.0_181]
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) ~[?:1.8.0_181]
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) ~[?:1.8.0_181]
at java.lang.reflect.Constructor.newInstance(Constructor.java:423) ~[?:1.8.0_181]
at java.lang.Class.newInstance(Class.java:442) ~[?:1.8.0_181]
at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:380) ~[?:1.8.0_181]
... 28 more
Caused by: java.lang.ClassNotFoundException: com.epam.reportportal.service.Launch
at java.net.URLClassLoader.findClass(URLClassLoader.java:381) ~[?:1.8.0_181]
at java.lang.ClassLoader.loadClass(ClassLoader.java:424) ~[?:1.8.0_181]
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349) ~[?:1.8.0_181]
at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ~[?:1.8.0_181]
at com.github.invictum.reportportal.injector.SerenityPortalModule.configure(SerenityPortalModule.java:14) ~[serenity-reportportal-integration-1.4.2.jar:?]
at com.google.inject.AbstractModule.configure(AbstractModule.java:61) ~[guice-4.2.2.jar:?]
at com.google.inject.spi.Elements$RecordingBinder.install(Elements.java:344) ~[guice-4.2.2.jar:?]
at com.google.inject.spi.Elements.getElements(Elements.java:103) ~[guice-4.2.2.jar:?]
at com.google.inject.internal.InjectorShell$Builder.build(InjectorShell.java:137) ~[guice-4.2.2.jar:?]
at com.google.inject.internal.InternalInjectorCreator.build(InternalInjectorCreator.java:103) ~[guice-4.2.2.jar:?]
at com.google.inject.Guice.createInjector(Guice.java:87) ~[guice-4.2.2.jar:?]
at com.google.inject.Guice.createInjector(Guice.java:69) ~[guice-4.2.2.jar:?]
at com.google.inject.Guice.createInjector(Guice.java:59) ~[guice-4.2.2.jar:?]
at com.github.invictum.reportportal.injector.IntegrationInjector.getInjector(IntegrationInjector.java:17) ~[serenity-reportportal-integration-1.4.2.jar:?]
at com.github.invictum.reportportal.ReportPortalListener.(ReportPortalListener.java:26) ~[serenity-reportportal-integration-1.4.2.jar:?]
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) ~[?:1.8.0_181]
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) ~[?:1.8.0_181]
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) ~[?:1.8.0_181]
at java.lang.reflect.Constructor.newInstance(Constructor.java:423) ~[?:1.8.0_181]
at java.lang.Class.newInstance(Class.java:442) ~[?:1.8.0_181]
at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:380) ~[?:1.8.0_181]
... 28 more
I have created a dummy test project that contains Serenity and CucumberWithSerenity tests in order to verify their integration with Report Portal.
This project configured with:
The project contains cucumber tests that have a common step.
When I'm trying to execute only one of these tests with its specific tag, I am getting the following error:
[rp-io-7] ERROR com.epam.reportportal.service.Launch - [38] ReportPortal execution error
com.epam.reportportal.exception.ReportPortalException: Report Portal returned error
Status code: 406
Status message: Not Acceptable
Error Message: Finish launch is not allowed. Launch '5bf2acdd756b5f0001dfd448' has items '[5bf2acdf756b5f0001dfd44e]' with 'IN_PROGRESS' status
Error Type: FINISH_LAUNCH_NOT_ALLOWEDat com.epam.reportportal.service.ReportPortalErrorHandler.handleError(ReportPortalErrorHandler.java:83) at com.epam.reportportal.service.ReportPortalErrorHandler.handle(ReportPortalErrorHandler.java:59) at com.epam.reportportal.restendpoint.http.HttpClientRestEndpoint$1.subscribe(HttpClientRestEndpoint.java:517) at io.reactivex.internal.operators.maybe.MaybeCreate.subscribeActual(MaybeCreate.java:45) at io.reactivex.Maybe.subscribe(Maybe.java:4096) at io.reactivex.internal.operators.maybe.MaybeCache.subscribeActual(MaybeCache.java:77) at io.reactivex.Maybe.subscribe(Maybe.java:4096) at io.reactivex.internal.operators.maybe.MaybeSubscribeOn$SubscribeTask.run(MaybeSubscribeOn.java:54) at io.reactivex.internal.schedulers.ScheduledDirectTask.call(ScheduledDirectTask.java:38) at io.reactivex.internal.schedulers.ScheduledDirectTask.call(ScheduledDirectTask.java:26) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748)
It happens only when I run a specific test that uses steps utilized by other scenarios. It seems that Report Portal is trying to fetch the results of tests that should be skipped and getting stuck.
I've attached a simple project that reproduces the issue:
simple-test-framework-with-serenity-and-cucumber_2.zip
The command that executes only one of this tests:
mvn clean verify -fae -Dcucumber.options="--tags @VerifyCucumber2"
Opened files attached with HtmlSourceAttacher
looks ugly.
Looks like an issue with MIME type detection.
Hi,
Sorry me again.
Everything works except for each Launch the last test always get stuck in an "In Progress" .
The test eventually times out with the status of "interrupted".
Not sure if the issue is in my ReportPortal dashboard(build 4.3.0) setup of in the Serenity plugin (version 1.1.3)
Any ideas what I'm doing wrong?
Thanks again!
TREE style reporting looks bad with default StepsSetProfile
. Let's implement separate profile optimized for it.
Add details to created entities in Report Portal
There is an old geckodriver issue that prevents determinate available log types mozilla/geckodriver#284
This prevents integration to work correctly with Firefox browser. The idea is to proceed its from integration code side.
1.4.0 version introduced a lot of changes. All classes should be revised and updated in accordance to it. The same should be provided for unit tests.
Memo:
I have created a dummy test project that contains Serenity and CucumberWithSerenity tests in order to verify their integration with Report Portal.
This project configured with:
[main] ERROR com.epam.reportportal.service.ReportPortal - Cannot send file to ReportPortal
java.lang.NullPointerException
, even though I am not sending any files.
The full stack trace is:
[main] ERROR com.epam.reportportal.service.ReportPortal - Cannot send file to ReportPortal
java.lang.NullPointerException
at com.epam.reportportal.service.ReportPortal$3.apply(ReportPortal.java:210)
at com.epam.reportportal.service.ReportPortal$3.apply(ReportPortal.java:199)
at com.epam.reportportal.service.LoggingContext$4.apply(LoggingContext.java:163)
at com.epam.reportportal.service.LoggingContext$4.apply(LoggingContext.java:160)
at io.reactivex.internal.operators.maybe.MaybeMap$MapMaybeObserver.onSuccess(MaybeMap.java:82)
at io.reactivex.internal.operators.maybe.MaybeCache.subscribeActual(MaybeCache.java:66)
at io.reactivex.Maybe.subscribe(Maybe.java:4096)
at io.reactivex.internal.operators.maybe.MaybeMap.subscribeActual(MaybeMap.java:40)
at io.reactivex.Maybe.subscribe(Maybe.java:4096)
at io.reactivex.internal.operators.maybe.MaybeToFlowable.subscribeActual(MaybeToFlowable.java:45)
at io.reactivex.Flowable.subscribe(Flowable.java:14419)
at io.reactivex.Flowable.subscribe(Flowable.java:14365)
at io.reactivex.internal.operators.flowable.FlowableFlatMap$MergeSubscriber.onNext(FlowableFlatMap.java:163)
at io.reactivex.internal.operators.flowable.FlowableOnBackpressureBuffer$BackpressureBufferSubscriber.drain(FlowableOnBackpressureBuffer.java:187)
at io.reactivex.internal.operators.flowable.FlowableOnBackpressureBuffer$BackpressureBufferSubscriber.onNext(FlowableOnBackpressureBuffer.java:112)
at io.reactivex.internal.operators.flowable.FlowableFromObservable$SubscriberObserver.onNext(FlowableFromObservable.java:52)
at io.reactivex.subjects.PublishSubject$PublishDisposable.onNext(PublishSubject.java:309)
at io.reactivex.subjects.PublishSubject.onNext(PublishSubject.java:229)
at com.epam.reportportal.service.LoggingContext.emit(LoggingContext.java:160)
at com.epam.reportportal.service.ReportPortal.emitLog(ReportPortal.java:147)
at com.epam.reportportal.service.ReportPortal.emitLog(ReportPortal.java:199)
at com.github.invictum.reportportal.StepDataExtractorsHolder.lambda$null$0(StepDataExtractorsHolder.java:27)
at java.util.Collections$SingletonSet.forEach(Collections.java:4767)
at com.github.invictum.reportportal.StepDataExtractorsHolder.lambda$proceed$1(StepDataExtractorsHolder.java:27)
at java.lang.Iterable.forEach(Iterable.java:75)
at com.github.invictum.reportportal.StepDataExtractorsHolder.proceed(StepDataExtractorsHolder.java:25)
at com.github.invictum.reportportal.handler.FlatHandler.lambda$finishTest$1(FlatHandler.java:92)
at java.util.ArrayList.forEach(ArrayList.java:1249)
at com.github.invictum.reportportal.handler.FlatHandler.finishTest(FlatHandler.java:92)
at com.github.invictum.reportportal.ReportPortalListener.testFinished(ReportPortalListener.java:51)
at net.thucydides.core.steps.StepEventBus.testFinished(StepEventBus.java:297)
at cucumber.runtime.formatter.SerenityReporter.handleTestCaseFinished(SerenityReporter.java:268)
at cucumber.runtime.formatter.SerenityReporter.lambda$new$2(SerenityReporter.java:118)
at cucumber.runner.EventBus.send(EventBus.java:28)
at cucumber.api.TestCase.run(TestCase.java:65)
at cucumber.runner.Runner.runPickle(Runner.java:80)
at cucumber.runtime.junit.PickleRunners$NoStepDescriptions.run(PickleRunners.java:140)
at cucumber.runtime.junit.FeatureRunner.runChild(FeatureRunner.java:68)
at cucumber.runtime.junit.FeatureRunner.runChild(FeatureRunner.java:23)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at cucumber.runtime.junit.FeatureRunner.run(FeatureRunner.java:73)
at cucumber.api.junit.Cucumber.runChild(Cucumber.java:117)
at cucumber.api.junit.Cucumber.runChild(Cucumber.java:55)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at cucumber.api.junit.Cucumber$1.evaluate(Cucumber.java:126)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:252)
at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:141)
at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:112)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189)
at org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:165)
at org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85)
at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:115)
at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:75)
[main] ERROR com.epam.reportportal.service.ReportPortal - Cannot send file to ReportPortal
java.lang.NullPointerException
at com.epam.reportportal.service.ReportPortal$3.apply(ReportPortal.java:210)
at com.epam.reportportal.service.ReportPortal$3.apply(ReportPortal.java:199)
at com.epam.reportportal.service.LoggingContext$4.apply(LoggingContext.java:163)
at com.epam.reportportal.service.LoggingContext$4.apply(LoggingContext.java:160)
at io.reactivex.internal.operators.maybe.MaybeMap$MapMaybeObserver.onSuccess(MaybeMap.java:82)
at io.reactivex.internal.operators.maybe.MaybeCache.subscribeActual(MaybeCache.java:66)
at io.reactivex.Maybe.subscribe(Maybe.java:4096)
at io.reactivex.internal.operators.maybe.MaybeMap.subscribeActual(MaybeMap.java:40)
at io.reactivex.Maybe.subscribe(Maybe.java:4096)
at io.reactivex.internal.operators.maybe.MaybeToFlowable.subscribeActual(MaybeToFlowable.java:45)
at io.reactivex.Flowable.subscribe(Flowable.java:14419)
at io.reactivex.Flowable.subscribe(Flowable.java:14365)
at io.reactivex.internal.operators.flowable.FlowableFlatMap$MergeSubscriber.onNext(FlowableFlatMap.java:163)
at io.reactivex.internal.operators.flowable.FlowableOnBackpressureBuffer$BackpressureBufferSubscriber.drain(FlowableOnBackpressureBuffer.java:187)
at io.reactivex.internal.operators.flowable.FlowableOnBackpressureBuffer$BackpressureBufferSubscriber.onNext(FlowableOnBackpressureBuffer.java:112)
at io.reactivex.internal.operators.flowable.FlowableFromObservable$SubscriberObserver.onNext(FlowableFromObservable.java:52)
at io.reactivex.subjects.PublishSubject$PublishDisposable.onNext(PublishSubject.java:309)
at io.reactivex.subjects.PublishSubject.onNext(PublishSubject.java:229)
at com.epam.reportportal.service.LoggingContext.emit(LoggingContext.java:160)
at com.epam.reportportal.service.ReportPortal.emitLog(ReportPortal.java:147)
at com.epam.reportportal.service.ReportPortal.emitLog(ReportPortal.java:199)
at com.github.invictum.reportportal.StepDataExtractorsHolder.lambda$null$0(StepDataExtractorsHolder.java:27)
at java.util.Collections$SingletonSet.forEach(Collections.java:4767)
at com.github.invictum.reportportal.StepDataExtractorsHolder.lambda$proceed$1(StepDataExtractorsHolder.java:27)
at java.lang.Iterable.forEach(Iterable.java:75)
at com.github.invictum.reportportal.StepDataExtractorsHolder.proceed(StepDataExtractorsHolder.java:25)
at com.github.invictum.reportportal.handler.FlatHandler.lambda$finishTest$1(FlatHandler.java:92)
at java.util.ArrayList.forEach(ArrayList.java:1249)
at com.github.invictum.reportportal.handler.FlatHandler.finishTest(FlatHandler.java:92)
at com.github.invictum.reportportal.ReportPortalListener.testFinished(ReportPortalListener.java:51)
at net.thucydides.core.steps.StepEventBus.testFinished(StepEventBus.java:297)
at cucumber.runtime.formatter.SerenityReporter.handleTestCaseFinished(SerenityReporter.java:268)
at cucumber.runtime.formatter.SerenityReporter.lambda$new$2(SerenityReporter.java:118)
at cucumber.runner.EventBus.send(EventBus.java:28)
at cucumber.api.TestCase.run(TestCase.java:65)
at cucumber.runner.Runner.runPickle(Runner.java:80)
at cucumber.runtime.junit.PickleRunners$NoStepDescriptions.run(PickleRunners.java:140)
at cucumber.runtime.junit.FeatureRunner.runChild(FeatureRunner.java:68)
at cucumber.runtime.junit.FeatureRunner.runChild(FeatureRunner.java:23)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at cucumber.runtime.junit.FeatureRunner.run(FeatureRunner.java:73)
at cucumber.api.junit.Cucumber.runChild(Cucumber.java:117)
at cucumber.api.junit.Cucumber.runChild(Cucumber.java:55)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at cucumber.api.junit.Cucumber$1.evaluate(Cucumber.java:126)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:252)
at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:141)
at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:112)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:189)
at org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:165)
at org.apache.maven.surefire.booter.ProviderFactory.invokeProvider(ProviderFactory.java:85)
at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:115)
at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:75)
I have attached the project to the issue.
simple-test-framework-with-serenity-and-cucumber.zip
The command for the Cucumber test execution is
mvn clean verify -Dcucumber.options="--tags @VerifyCucumber"
Web driver allows to collect its logs with driver.manage().logs()
.
Potentially this logs could be useful. Let's add ability to push them to Report Portal.
Issue is spotted with serenity-cucumber.
Looks ThucydidesWebDriverSupport.isInitialised()
doesn't work correct in context of Cucumber tests.
If Rest Assured is used to send empty request body is shown in report.
Let's make report more accurate - only non-empty bodies should be shown.
Will be good to have an ability to add custom tags (e.g. build ID) into RP programmatically. As far as I see there is no ability to do it right now.
Thank you.
For now integration proceed parametrized BDD tests in a wrong way.
Steps:
exampleStarted
and exampleFinished
methodsIdeas:
Relates to #60
ReportPortal returned a lot of following errors during parallel testrun:
com.epam.reportportal.exception.ReportPortalException: Report Portal returned error
Status code: 406
Status message: Not Acceptable
Error Message: Start time of child ['Fri Jun 14 09:13:18 UTC 2019'] item should be same or later than start time ['Fri Jun 14 09:13:18 UTC 2019'] of the parent item/launch '5d036530ee1f100001534724'
Error Type: CHILD_START_TIME_EARLIER_THAN_PARENT
at com.epam.reportportal.service.ReportPortalErrorHandler.handleError(ReportPortalErrorHandler.java:83)
at com.epam.reportportal.service.ReportPortalErrorHandler.handle(ReportPortalErrorHandler.java:59)
at com.epam.reportportal.restendpoint.http.HttpClientRestEndpoint$1.subscribe(HttpClientRestEndpoint.java:517)
at io.reactivex.internal.operators.maybe.MaybeCreate.subscribeActual(MaybeCreate.java:45)
at io.reactivex.Maybe.subscribe(Maybe.java:4096)
at io.reactivex.internal.operators.maybe.MaybeCache.subscribeActual(MaybeCache.java:77)
at io.reactivex.Maybe.subscribe(Maybe.java:4096)
at io.reactivex.internal.operators.maybe.MaybeSubscribeOn$SubscribeTask.run(MaybeSubscribeOn.java:54)
at io.reactivex.internal.schedulers.ScheduledDirectTask.call(ScheduledDirectTask.java:38)
at io.reactivex.internal.schedulers.ScheduledDirectTask.call(ScheduledDirectTask.java:26)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
116381 [RxComputationThreadPool-15] ERROR [SubscriptionUtils.java:75] - Logging context completed with error
com.epam.reportportal.exception.ReportPortalException: Report Portal returned error
Status code: 406
Status message: Not Acceptable
Error Message: Start time of child ['Fri Jun 14 09:13:18 UTC 2019'] item should be same or later than start time ['Fri Jun 14 09:13:18 UTC 2019'] of the parent item/launch '5d036530ee1f100001534724'
Error Type: CHILD_START_TIME_EARLIER_THAN_PARENT
at com.epam.reportportal.service.ReportPortalErrorHandler.handleError(ReportPortalErrorHandler.java:83) ~[client-java-4.0.13.jar:na]
at com.epam.reportportal.service.ReportPortalErrorHandler.handle(ReportPortalErrorHandler.java:59) ~[client-java-4.0.13.jar:na]
at com.epam.reportportal.restendpoint.http.HttpClientRestEndpoint$1.subscribe(HttpClientRestEndpoint.java:517) ~[client-java-4.0.13.jar:na]
at io.reactivex.internal.operators.maybe.MaybeCreate.subscribeActual(MaybeCreate.java:45) ~[rxjava-2.1.16.jar:na]
at io.reactivex.Maybe.subscribe(Maybe.java:4096) ~[rxjava-2.1.16.jar:na]
at io.reactivex.internal.operators.maybe.MaybeCache.subscribeActual(MaybeCache.java:77) ~[rxjava-2.1.16.jar:na]
at io.reactivex.Maybe.subscribe(Maybe.java:4096) ~[rxjava-2.1.16.jar:na]
at io.reactivex.internal.operators.maybe.MaybeSubscribeOn$SubscribeTask.run(MaybeSubscribeOn.java:54) ~[rxjava-2.1.16.jar:na]
at io.reactivex.internal.schedulers.ScheduledDirectTask.call(ScheduledDirectTask.java:38) ~[rxjava-2.1.16.jar:na]
at io.reactivex.internal.schedulers.ScheduledDirectTask.call(ScheduledDirectTask.java:26) ~[rxjava-2.1.16.jar:na]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[na:1.8.0_151]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [na:1.8.0_151]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [na:1.8.0_151]
at java.lang.Thread.run(Thread.java:748) [na:1.8.0_151]
Also I want to mention that number of tests in ReportPortal every time different during parallel launch.
Here is some pox.xml details:
<properties>
<nonfunctionalTestsSkip>true</nonfunctionalTestsSkip>
<nonfunctionalParallelExecution>methods</nonfunctionalParallelExecution>
<nonfunctionalParallelThreads>15</nonfunctionalParallelThreads>
<performance.test.configuration>false</performance.test.configuration>
<!-- Versions -->
<serenity.version>2.0.52</serenity.version>
<serenity.maven.version>2.0.50</serenity.maven.version>
<serenity.reportportal.integration.version>1.4.1</serenity.reportportal.integration.version>
<maven.surefire.plugin.version>2.22.2</maven.surefire.plugin.version>
<maven.failsafe.plugin.version>2.22.2</maven.failsafe.plugin.version>
</properties>
<build>
<plugins>
<plugin>
<artifactId>maven-failsafe-plugin</artifactId>
<version>${maven.failsafe.plugin.version}</version>
<dependencies>
<dependency>
<groupId>org.apache.maven.surefire</groupId>
<artifactId>surefire-junit47</artifactId>
<version>${maven.surefire.plugin.version}</version>
</dependency>
</dependencies>
<configuration>
<includes>
<include>**/*Tests.*</include>
</includes>
<parallel>classes</parallel>
<threadCount>${nonfunctionalParallelThreads}</threadCount>
<perCoreThreadCount>false</perCoreThreadCount>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>${maven.surefire.plugin.version}</version>
<configuration>
<parallel>${nonfunctionalParallelExecution}</parallel>
<threadCount>${nonfunctionalParallelThreads}</threadCount>
<skipTests>${nonfunctionalTestsSkip}</skipTests>
</configuration>
</plugin>
<plugin>
<groupId>net.serenity-bdd.maven.plugins</groupId>
<artifactId>serenity-maven-plugin</artifactId>
<version>${serenity.maven.version}</version>
<dependencies>
<dependency>
<groupId>net.serenity-bdd</groupId>
<artifactId>serenity-core</artifactId>
<version>${serenity.version}</version>
</dependency>
</dependencies>
<executions>
<execution>
<id>serenity-reports</id>
<phase>post-integration-test</phase>
<goals>
<goal>aggregate</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>net.serenity-bdd</groupId>
<artifactId>serenity-core</artifactId>
<version>${serenity.version}</version>
</dependency>
<dependency>
<groupId>net.serenity-bdd</groupId>
<artifactId>serenity-junit</artifactId>
<version>${serenity.version}</version>
</dependency>
<dependency>
<groupId>net.serenity-bdd</groupId>
<artifactId>serenity-rest-assured</artifactId>
<version>${serenity.version}</version>
</dependency>
<dependency>
<groupId>com.github.invictum</groupId>
<artifactId>serenity-reportportal-integration</artifactId>
<version>${serenity.reportportal.integration.version}</version>
<exclusions>
<exclusion>
<groupId>net.serenity-bdd</groupId>
<artifactId>serenity-core</artifactId>
</exclusion>
</exclusions>
</dependency>
</dependencies>
</project>
So the actual behaviour during parallel launch:
And expected behaviour during parallel launch:
Do you need any additional information?
Hi ..
I am using serenity runner with Jbehave BDD . when i try to integrate report portal serenity ,I am getting the below error.Please help me .
On running tests in multimodule test-automation-framework, Report Portal creates a separate launch for each module. It generates redundant launches for modules which don't have any tests with the specified tag.
Would it be possible to keep all tests results in one launch even though tests are defined in different maven modules?
The project simple-multimodule-project.zip:
Execute the following command to reproduce the issue:
mvn clean verify -Dcucumber.options="--tags '@API'"
For now ErrorLogger
constructor allows to pass boolean flag for full or short reporting variant. Let's remove this limitation and allow to pass Function<TestStep, String>
.
Solution will allow to define any customers logic easily without extra efforts.
I'm trying to setup Report Portal integration on my project that uses Serenity and Cucumber (@RunWith(CucumberWithSerenity.class)).
However, when launching tests, the first test itself passes, but I get NPE in the Runner class right after it:
java.lang.NullPointerException at com.github.invictum.reportportal.handler.FlatHandler.finishTest(FlatHandler.java:91) at com.github.invictum.reportportal.ReportPortalListener.testFinished(ReportPortalListener.java:50) at net.thucydides.core.steps.StepEventBus.testFinished(StepEventBus.java:300) at cucumber.runtime.formatter.SerenityReporter.handleTestCaseFinished(SerenityReporter.java:267) at cucumber.runtime.formatter.SerenityReporter.lambda$new$2(SerenityReporter.java:117) at cucumber.runner.EventBus.send(EventBus.java:28) at cucumber.api.TestCase.run(TestCase.java:65) at cucumber.runner.Runner.runPickle(Runner.java:80) at cucumber.runtime.junit.PickleRunners$NoStepDescriptions.run(PickleRunners.java:140) at cucumber.runtime.junit.FeatureRunner.runChild(FeatureRunner.java:68) at cucumber.runtime.junit.FeatureRunner.runChild(FeatureRunner.java:23) at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290) at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71) at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288) at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58) at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268) at org.junit.runners.ParentRunner.run(ParentRunner.java:363) at cucumber.runtime.junit.FeatureRunner.run(FeatureRunner.java:73) at cucumber.api.junit.Cucumber.runChild(Cucumber.java:118) at cucumber.api.junit.Cucumber.runChild(Cucumber.java:56) at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290) at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71) at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288) at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58) at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268) at cucumber.api.junit.Cucumber$1.evaluate(Cucumber.java:127) at org.junit.runners.ParentRunner.run(ParentRunner.java:363) at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:367) at org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:274) at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:238) at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:161) at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:290) at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:242) at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:121)
And when launching a test suite with multiple tests, only the first test is finished, others don't launch due to NPE in Runner.
I've tried multiple versions, but current ones are:
serenity 2.0.20
serenity-cucumber 1.9.21
serenity-reportportal-integration 1.3.0
Please see the sample project (attached) where I was able to reproduce the issue on minimal configuration for further info. Launch it with "mvn clean verify"
serenitycucumberreportportalsample.zip
The runs appear in my local Report Portal, but again, they contain only the first test
Looking forward to hearing back from you.
Hi,
I use serenity integration with cucumber. I found that the official cucumber plugin doesn't work for me as it works with old version cucumber while all latest serenity integrations are based on latest cucumber (> 2.x).
Is this plugin to support @RunWith(CucumberWithSerenity.class) in addition to just @RunWith(Serenity.class) ?
As now there are official cucumber plugin and this one for serenity but seems there is now plugin which can handle integration of those two. If I try to use this one with @RunWith(CucumberWithSerenity.class) then for some reason, it tried to initialize webdriver while there is no use of webdriver in the whole project.
If I don't use the plugin in pom then the test works fine. Otherwise, it gives:
'''
TEST STARTED: Basic scenario
-------------------------------------------------------------------(basic-feature-file-that-used-in-order-to-test-an-integration-with-report-portal;basic-scenario)
Feature: Basic feature file that used in order to test an integration with Report Portal
@VerifyCucumber @API
Scenario: Basic scenario # src/test/resources/basic_cucumber_test.feature:4
Nov 13, 2018 11:16:23 PM org.openqa.selenium.remote.DesiredCapabilities firefox
INFO: Using new FirefoxOptions()
is preferred to DesiredCapabilities.firefox()
Nov 13, 2018 11:16:23 PM org.openqa.selenium.remote.DesiredCapabilities firefox
INFO: Using new FirefoxOptions()
is preferred to DesiredCapabilities.firefox()
'''
No special description provided.
Hello,
I was trying to use the report portal and it worked quite well with JUnit integration. However, once I try to use it with serenity integration, I have some troubles in making an auto-analysis. It just doesn't work without any errors in logs.
This is my report portal configuration:
If I manually analysis the same error, again and again, it is not analysed automation into next launches:
I tried to cut everything from my framework and left only one extremely basic example:
https://drive.google.com/file/d/1bSAounA48-wtR53QvpnRwq-vJE6UfhGw/view?usp=sharing
To run related tests:
cd /tests/backend-tests
mvn clean verify -Dtags='type:HealthCheck'
I would very much appreciate if you can point out if it is serenity integration plugin problem. Once I refactored it for using just JUnit, it was working fine.
Worth to mention, that I use Kotlin. However, not sure if it plays any role here...
Hi,
Not sure if this is a user error or not but any idea what would cause a "ERROR com.epam.reportportal.service.ReportPortal - Cannot build ReportPortal client
java.net.MalformedURLException" ? The URL is taking direclty from the ReportPortal SuperAdmins User profile java configuration section. All the info like rp.endpoint, rp.uuid, rp.launc, and rp.project in my reportportal.properties looks correct as well. This is the verson of Serenity being used:
<serenity.version>1.9.7</serenity.version>
<serenity.jbehave.version>1.38.0</serenity.jbehave.version>
Any ideas whay I'm doing wrong?
Cheers,
Joe
Here is full error:
[main] ERROR com.epam.reportportal.service.ReportPortal - Cannot build ReportPortal client
java.net.MalformedURLException
at java.net.URL.(URL.java:627)
at java.net.URL.(URL.java:490)
at java.net.URL.(URL.java:439)
at com.epam.reportportal.service.ReportPortal$Builder.defaultClient(ReportPortal.java:301)
at com.epam.reportportal.service.ReportPortal$Builder.buildClient(ReportPortal.java:263)
at com.epam.reportportal.service.ReportPortal$Builder.build(ReportPortal.java:251)
at com.github.invictum.reportportal.injector.ReportLaunchProvider.get(ReportLaunchProvider.java:20)
at com.github.invictum.reportportal.injector.ReportLaunchProvider.get(ReportLaunchProvider.java:14)
at com.google.inject.internal.ProviderInternalFactory.provision(ProviderInternalFactory.java:81)
at com.google.inject.internal.BoundProviderFactory.provision(BoundProviderFactory.java:72)
at com.google.inject.internal.ProviderInternalFactory.circularGet(ProviderInternalFactory.java:61)
at com.google.inject.internal.BoundProviderFactory.get(BoundProviderFactory.java:62)
at com.google.inject.internal.ProviderToInternalFactoryAdapter$1.call(ProviderToInternalFactoryAdapter.java:46)
at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1092)
at com.google.inject.internal.ProviderToInternalFactoryAdapter.get(ProviderToInternalFactoryAdapter.java:40)
at com.google.inject.internal.SingletonScope$1.get(SingletonScope.java:194)
at com.google.inject.internal.InternalFactoryToProviderAdapter.get(InternalFactoryToProviderAdapter.java:41)
at com.google.inject.internal.SingleFieldInjector.inject(SingleFieldInjector.java:54)
at com.google.inject.internal.MembersInjectorImpl.injectMembers(MembersInjectorImpl.java:132)
at com.google.inject.internal.MembersInjectorImpl$1.call(MembersInjectorImpl.java:93)
at com.google.inject.internal.MembersInjectorImpl$1.call(MembersInjectorImpl.java:80)
at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1085)
at com.google.inject.internal.MembersInjectorImpl.injectAndNotify(MembersInjectorImpl.java:80)
at com.google.inject.internal.MembersInjectorImpl.injectMembers(MembersInjectorImpl.java:62)
at com.google.inject.internal.InjectorImpl.injectMembers(InjectorImpl.java:987)
at com.github.invictum.reportportal.handler.FlatHandler.(FlatHandler.java:36)
at com.github.invictum.reportportal.ReportPortalListener.(ReportPortalListener.java:25)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at java.lang.Class.newInstance(Class.java:442)
at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:380)
at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:404)
at java.util.ServiceLoader$1.next(ServiceLoader.java:480)
at net.thucydides.core.steps.StepEventBus.getCustomListeners(StepEventBus.java:200)
at net.thucydides.core.steps.StepEventBus.getAllListeners(StepEventBus.java:185)
at net.thucydides.core.steps.StepEventBus.testSuiteFinished(StepEventBus.java:562)
at net.serenitybdd.jbehave.runners.SerenityReportingRunner.shutdownTestSuite(SerenityReportingRunner.java:225)
at net.serenitybdd.jbehave.runners.SerenityReportingRunner.run(SerenityReportingRunner.java:209)
at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:283)
at org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:173)
at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:153)
at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:128)
at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:203)
at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:155)
at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:103)
Caused by: java.lang.NullPointerException
at java.net.URL.(URL.java:532)
... 46 more
[main] ERROR com.epam.reportportal.service.ReportPortal - Cannot build ReportPortal client
com.epam.reportportal.exception.InternalReportPortalClientException: Cannot build ReportPortal client
at com.epam.reportportal.service.ReportPortal$Builder.buildClient(ReportPortal.java:270)
at com.epam.reportportal.service.ReportPortal$Builder.build(ReportPortal.java:251)
at com.github.invictum.reportportal.injector.ReportLaunchProvider.get(ReportLaunchProvider.java:20)
at com.github.invictum.reportportal.injector.ReportLaunchProvider.get(ReportLaunchProvider.java:14)
at com.google.inject.internal.ProviderInternalFactory.provision(ProviderInternalFactory.java:81)
at com.google.inject.internal.BoundProviderFactory.provision(BoundProviderFactory.java:72)
at com.google.inject.internal.ProviderInternalFactory.circularGet(ProviderInternalFactory.java:61)
at com.google.inject.internal.BoundProviderFactory.get(BoundProviderFactory.java:62)
at com.google.inject.internal.ProviderToInternalFactoryAdapter$1.call(ProviderToInternalFactoryAdapter.java:46)
at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1092)
at com.google.inject.internal.ProviderToInternalFactoryAdapter.get(ProviderToInternalFactoryAdapter.java:40)
at com.google.inject.internal.SingletonScope$1.get(SingletonScope.java:194)
at com.google.inject.internal.InternalFactoryToProviderAdapter.get(InternalFactoryToProviderAdapter.java:41)
at com.google.inject.internal.SingleFieldInjector.inject(SingleFieldInjector.java:54)
at com.google.inject.internal.MembersInjectorImpl.injectMembers(MembersInjectorImpl.java:132)
at com.google.inject.internal.MembersInjectorImpl$1.call(MembersInjectorImpl.java:93)
at com.google.inject.internal.MembersInjectorImpl$1.call(MembersInjectorImpl.java:80)
at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1085)
at com.google.inject.internal.MembersInjectorImpl.injectAndNotify(MembersInjectorImpl.java:80)
at com.google.inject.internal.MembersInjectorImpl.injectMembers(MembersInjectorImpl.java:62)
at com.google.inject.internal.InjectorImpl.injectMembers(InjectorImpl.java:987)
at com.github.invictum.reportportal.handler.FlatHandler.(FlatHandler.java:36)
at com.github.invictum.reportportal.ReportPortalListener.(ReportPortalListener.java:25)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at java.lang.Class.newInstance(Class.java:442)
at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:380)
at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:404)
at java.util.ServiceLoader$1.next(ServiceLoader.java:480)
at net.thucydides.core.steps.StepEventBus.getCustomListeners(StepEventBus.java:200)
at net.thucydides.core.steps.StepEventBus.getAllListeners(StepEventBus.java:185)
at net.thucydides.core.steps.StepEventBus.testSuiteFinished(StepEventBus.java:562)
at net.serenitybdd.jbehave.runners.SerenityReportingRunner.shutdownTestSuite(SerenityReportingRunner.java:225)
at net.serenitybdd.jbehave.runners.SerenityReportingRunner.run(SerenityReportingRunner.java:209)
at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:283)
at org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:173)
at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:153)
at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:128)
at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:203)
at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:155)
at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:103)
Caused by: java.net.MalformedURLException
at java.net.URL.(URL.java:627)
at java.net.URL.(URL.java:490)
at java.net.URL.(URL.java:439)
at com.epam.reportportal.service.ReportPortal$Builder.defaultClient(ReportPortal.java:301)
at com.epam.reportportal.service.ReportPortal$Builder.buildClient(ReportPortal.java:263)
... 42 more
Caused by: java.lang.NullPointerException
at java.net.URL.(URL.java:532)
... 46 more
[main] ERROR net.thucydides.core.steps.StepEventBus - Could not instantiate listener
java.util.ServiceConfigurationError: net.thucydides.core.steps.StepListener: Provider com.github.invictum.reportportal.ReportPortalListener could not be instantiated
at java.util.ServiceLoader.fail(ServiceLoader.java:232)
at java.util.ServiceLoader.access$100(ServiceLoader.java:185)
at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:384)
at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:404)
at java.util.ServiceLoader$1.next(ServiceLoader.java:480)
at net.thucydides.core.steps.StepEventBus.getCustomListeners(StepEventBus.java:200)
at net.thucydides.core.steps.StepEventBus.getAllListeners(StepEventBus.java:185)
at net.thucydides.core.steps.StepEventBus.testSuiteFinished(StepEventBus.java:562)
at net.serenitybdd.jbehave.runners.SerenityReportingRunner.shutdownTestSuite(SerenityReportingRunner.java:225)
at net.serenitybdd.jbehave.runners.SerenityReportingRunner.run(SerenityReportingRunner.java:209)
at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:283)
at org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:173)
at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:153)
at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:128)
at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:203)
at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:155)
at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:103)
Caused by: com.google.inject.ProvisionException: Unable to provision, see the following errors:
1 error
at com.google.inject.internal.Errors.throwProvisionExceptionIfErrorsExist(Errors.java:486)
at com.google.inject.internal.MembersInjectorImpl.injectMembers(MembersInjectorImpl.java:67)
at com.google.inject.internal.InjectorImpl.injectMembers(InjectorImpl.java:987)
at com.github.invictum.reportportal.handler.FlatHandler.(FlatHandler.java:36)
at com.github.invictum.reportportal.ReportPortalListener.(ReportPortalListener.java:25)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at java.lang.Class.newInstance(Class.java:442)
at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:380)
... 14 more
Caused by: com.epam.reportportal.exception.InternalReportPortalClientException: Cannot build ReportPortal client
at com.epam.reportportal.service.ReportPortal$Builder.build(ReportPortal.java:255)
at com.github.invictum.reportportal.injector.ReportLaunchProvider.get(ReportLaunchProvider.java:20)
at com.github.invictum.reportportal.injector.ReportLaunchProvider.get(ReportLaunchProvider.java:14)
at com.google.inject.internal.ProviderInternalFactory.provision(ProviderInternalFactory.java:81)
at com.google.inject.internal.BoundProviderFactory.provision(BoundProviderFactory.java:72)
at com.google.inject.internal.ProviderInternalFactory.circularGet(ProviderInternalFactory.java:61)
at com.google.inject.internal.BoundProviderFactory.get(BoundProviderFactory.java:62)
at com.google.inject.internal.ProviderToInternalFactoryAdapter$1.call(ProviderToInternalFactoryAdapter.java:46)
at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1092)
at com.google.inject.internal.ProviderToInternalFactoryAdapter.get(ProviderToInternalFactoryAdapter.java:40)
at com.google.inject.internal.SingletonScope$1.get(SingletonScope.java:194)
at com.google.inject.internal.InternalFactoryToProviderAdapter.get(InternalFactoryToProviderAdapter.java:41)
at com.google.inject.internal.SingleFieldInjector.inject(SingleFieldInjector.java:54)
at com.google.inject.internal.MembersInjectorImpl.injectMembers(MembersInjectorImpl.java:132)
at com.google.inject.internal.MembersInjectorImpl$1.call(MembersInjectorImpl.java:93)
at com.google.inject.internal.MembersInjectorImpl$1.call(MembersInjectorImpl.java:80)
at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1085)
at com.google.inject.internal.MembersInjectorImpl.injectAndNotify(MembersInjectorImpl.java:80)
at com.google.inject.internal.MembersInjectorImpl.injectMembers(MembersInjectorImpl.java:62)
... 23 more
Caused by: com.epam.reportportal.exception.InternalReportPortalClientException: Cannot build ReportPortal client
at com.epam.reportportal.service.ReportPortal$Builder.buildClient(ReportPortal.java:270)
at com.epam.reportportal.service.ReportPortal$Builder.build(ReportPortal.java:251)
... 41 more
Caused by: java.net.MalformedURLException
at java.net.URL.(URL.java:627)
at java.net.URL.(URL.java:490)
at java.net.URL.(URL.java:439)
at com.epam.reportportal.service.ReportPortal$Builder.defaultClient(ReportPortal.java:301)
at com.epam.reportportal.service.ReportPortal$Builder.buildClient(ReportPortal.java:263)
... 42 more
Caused by: java.lang.NullPointerException
at java.net.URL.(URL.java:532)
... 46 more
Technically NarativeFormatter
is a convertor function, so it is possible to use Java 8 features to represent it.
For now following extractors are available
-> log units
Update all libs to latest versions
In some cases, our test automation framework requires the sequential execution of cucumber features. In order to achieve this, we explicitly define these features under the same runner class:
@RunWith(CucumberWithSerenity.class)
@CucumberOptions(
plugin = {"pretty"},
features = {"src/test/resources/basic_cucumber_test.feature",
"src/test/resources/basic_cucumber_test2.feature"})
When the Report Portal represents all features on the Suite view, it shows only one of the specified files, e.g. "The 2nd dummy scenario" [src/test/resources/basic_cucumber_test2.feature], which has all tests from both files [basic_cucumber_test and basic_cucumber_test2] behind.
Our project has configured as Serenity-Cucumber-jvm:
Here is a sample project to reproduce the issue: simple-test-framework-with-serenity-and-cucumber.zip
Would it be possible for you to fix this data representation issue?
Please let me know if you need further information. Thank you!
Basically, the same issue happens when we execute several feature files under different runner classes but in parallel.
Actually steps processors are not invoked at all for TREE style reporting
Is there a way to configure the integration to add separate features as items under a launch? Right now the default behavior is that the all scenarios are added as tests under one feature that is seemingly selected at random. I believe it might be due to how we are setting up our test runner, which is in a separate TestSupport class.
@RunWith(CucumberWithSerenity.class)
@CucumberOptions(
features = "src/test/resources/features",
glue = "com.serenity.autotest.project")
public class TestSupport {}
Please let me know if this is possible with the existing module. Thanks.
To keep integration works normally serenity-core
and *.report.portal
modules should use latest versions.
Need to investigate multiple runners execution sequence.
Add support for Serenity's @pending annotation for tests and steps.
Hi @Invictum, I'd like to thank you for all the efforts you have put in the serenity-reportportal-integration project.
You have made our life much easier by providing such listener, as now we can represent all our test results in the Report Portal on a daily basis.
I created this issue just to suggest a minor thing for the further improvement of the serenity-reportportal-integration project.
Serenity + Rest Assured is a widely used combination for API verification which provides outstanding test reports out-of-the-box.
Currently, RP doesn't have a feature to reflect request/response data in the test results:
Would it be feasible to add the additional information for rest-assured-based tests to Report Portal along with interactive dashboard capabilities? I hope, it will be a piece of cake for you to make it real.
It would be really beneficial for users of the serenity-reportportal integrator. Thank you!
In order to check the current reporting, please execute API tests from simple-multimodule-project.zip
mvn clean verify -Dcucumber.options="--tags '@API'"
There is a minor 1.2.0 release ahead. So it is possible to provide backward incompatible refactor:
StepProcessor
approach. Processor should return a list of massages for RP rather than emit logs itself.A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.