public abstract class ReportPortalFormat
extends org.jbehave.core.reporters.Format
| Modifier and Type | Field and Description |
|---|---|
protected com.epam.reportportal.service.tree.TestItemTree |
itemTree |
protected com.epam.reportportal.utils.MemoizingSupplier<com.epam.reportportal.service.Launch> |
launch |
protected com.epam.reportportal.service.ReportPortal |
rp |
| Constructor and Description |
|---|
ReportPortalFormat(com.epam.reportportal.service.ReportPortal reportPortal)
Creates an instance of the formatter class using specific
ReportPortal reporter. |
| Modifier and Type | Method and Description |
|---|---|
protected com.epam.ta.reportportal.ws.model.launch.StartLaunchRQ |
buildStartLaunchRQ(java.util.Date startTime,
com.epam.reportportal.listeners.ListenerParameters parameters)
A method for creation a Start Launch request which will be sent to Report Portal.
|
protected com.epam.reportportal.utils.MemoizingSupplier<com.epam.reportportal.service.Launch> |
createLaunch(com.epam.reportportal.service.ReportPortal rp)
Returns a supplier which initialize a launch on the first 'get'.
|
protected abstract ReportPortalStoryReporter |
createReportPortalReporter(org.jbehave.core.reporters.FilePrintStreamFactory factory,
org.jbehave.core.reporters.StoryReporterBuilder storyReporterBuilder) |
org.jbehave.core.reporters.StoryReporter |
createStoryReporter(org.jbehave.core.reporters.FilePrintStreamFactory factory,
org.jbehave.core.reporters.StoryReporterBuilder storyReporterBuilder)
Creates a
StoryReporter which will be used to report a Story. |
protected void |
finishLaunch()
Finishes a
Launch passed in the method parameters |
static ReportPortalFormat |
getCurrent()
Returns a formatter instance for the current thread.
|
static java.util.Optional<ReportPortalStoryReporter> |
getCurrentStoryReporter()
Returns a story reporter for the current thread if any.
|
com.epam.reportportal.service.tree.TestItemTree |
getItemTree() |
com.epam.reportportal.service.ReportPortal |
getReportPortal() |
protected java.lang.Thread |
getShutdownHook()
Returns a
Thread which is supposed to run on test execution shutdown. |
protected final com.epam.reportportal.utils.MemoizingSupplier<com.epam.reportportal.service.Launch> launch
protected final com.epam.reportportal.service.tree.TestItemTree itemTree
protected final com.epam.reportportal.service.ReportPortal rp
public ReportPortalFormat(com.epam.reportportal.service.ReportPortal reportPortal)
ReportPortal reporter.reportPortal - an instance of Report Portal reporterprotected void finishLaunch()
Launch passed in the method parametersprotected java.lang.Thread getShutdownHook()
Thread which is supposed to run on test execution shutdown. By default it finishes the current test execution on
Report Portal.protected com.epam.ta.reportportal.ws.model.launch.StartLaunchRQ buildStartLaunchRQ(java.util.Date startTime,
com.epam.reportportal.listeners.ListenerParameters parameters)
startTime - launch start time, which will be set into the result requestparameters - Report Portal client parametersprotected com.epam.reportportal.utils.MemoizingSupplier<com.epam.reportportal.service.Launch> createLaunch(com.epam.reportportal.service.ReportPortal rp)
rp - a ReportPortal class instance which will be used to communicate with the portalLaunch instancepublic org.jbehave.core.reporters.StoryReporter createStoryReporter(org.jbehave.core.reporters.FilePrintStreamFactory factory,
org.jbehave.core.reporters.StoryReporterBuilder storyReporterBuilder)
StoryReporter which will be used to report a Story.createStoryReporter in class org.jbehave.core.reporters.Formatfactory - JBehave's file print stream factorystoryReporterBuilder - JBehave's StoryReporter builderprotected abstract ReportPortalStoryReporter createReportPortalReporter(org.jbehave.core.reporters.FilePrintStreamFactory factory, org.jbehave.core.reporters.StoryReporterBuilder storyReporterBuilder)
@Nonnull public com.epam.reportportal.service.ReportPortal getReportPortal()
@Nonnull public com.epam.reportportal.service.tree.TestItemTree getItemTree()
@Nonnull public static ReportPortalFormat getCurrent()
@Nonnull public static java.util.Optional<ReportPortalStoryReporter> getCurrentStoryReporter()